Failed to retrieve search context: EvalError: symf failed: Error: spawn ENAMETOOLONG

Hello,
Probably after extension update I got this error for all prompts.

Failed to retrieve search context: EvalError: symf failed: Error: spawn ENAMETOOLONG

I’m not able to use cody anymore in my vs code. Can you propose fix please?

I tried reboot, also switch to pre-release version. But it didn’t help.

Hey @deeppresentation

Please completely de-install and re-install Cody. The issue seems related to the ‘symf’ binary for indexing the local repository.

If you’ll run into any issue, I appreciate feedback.

Thank you.

Hey @PriNova,
Thank you. I found that that is only happening when there is a all project placeholder in prompt. Don’t I loose some cody knowledge about a project by uninstalling it?

You will may loose the chat history. The last time I uninstalled and re-installed it, the chat history remained.

1 Like

The same thing is happening to me too. I have uninstalled python, cody and vscode. I have cleaned all the user directories of these programs and reinstalled from scratch and I still have the same problem. It’s independent of the project I’m in.

El log es:
█ telemetry-v2 recordEvent: cody.extension/savedLogin: {
“parameters”: {
“version”: 0,
“metadata”:
},
“timestamp”: “2025-04-10T11:10:49.960Z”
}
█ auth Authenticating to https://sourcegraph.com/
█ ModelsService User model preferences changed: {“defaults”:{“chat”:“anthropic::2023-06-01::claude-3.5-sonnet”,“edit”:“anthropic::2023-06-01::claude-3.5-sonnet”,“autocomplete”:“fireworks::v1::deepseek-coder-v2-lite-base”},“selected”:{}}
█ ChatsController:constructor init
█ auth Authentication succeed to endpoint https://sourcegraph.com/
█ telemetry-v2 recordEvent: cody.auth/connected: {
“parameters”: {
“version”: 0,
“metadata”: [
{
“key”: “tier”,
“value”: 0
}
]
},
“timestamp”: “2025-04-10T11:10:51.322Z”
}
█ SymfRunner unsafeEnsureIndex: file:///k%3A/PyComicRack {
“options”: {
“retryIfLastAttemptFailed”: false,
“ignoreExisting”: false
}
}
█ ClientConfigSingleton refreshing configuration
█ ClientConfigSingleton refreshed: {“codyEnabled”:true,“chatEnabled”:true,“autoCompleteEnabled”:true,“customCommandsEnabled”:true,“attributionEnabled”:false,“attribution”:“none”,“smartContextWindowEnabled”:true,“modelsAPIEnabled”:false,“latestSupportedCompletionsStreamAPIVersion”:9}
█ Autocomplete:initialized using “dotcom-feature-flags”: “fireworks::deepseek-coder-v2-lite-base”
█ ModelsService new models API enabled
█ auth Authenticating to https://sourcegraph.com/
█ auth Authentication succeed to endpoint https://sourcegraph.com/
█ ModelsService ModelsData changed: 21 primary models
█ UpstreamHealth Ping took 174ms (Gateway: 263ms): “url=https://sourcegraph.com/healthz status=200 cf-ray=92e1cc741c272f9f-MAD”
█ ClientConfigSingleton refreshing configuration
█ ClientConfigSingleton refreshed: {“codyEnabled”:true,“chatEnabled”:true,“autoCompleteEnabled”:true,“customCommandsEnabled”:true,“attributionEnabled”:false,“attribution”:“none”,“smartContextWindowEnabled”:true,“modelsAPIEnabled”:false,“latestSupportedCompletionsStreamAPIVersion”:9}
█ ClientConfigSingleton refreshing configuration
█ ClientConfigSingleton refreshed: {“codyEnabled”:true,“chatEnabled”:true,“autoCompleteEnabled”:true,“customCommandsEnabled”:true,“attributionEnabled”:false,“attribution”:“none”,“smartContextWindowEnabled”:true,“modelsAPIEnabled”:false,“latestSupportedCompletionsStreamAPIVersion”:9}
█ ChatController updateViewConfig: {
“uiKindIsWeb”: false,
“serverEndpoint”: “https://sourcegraph.com/”,
“endpointHistory”: [
https://sourcegraph.com/
],
“experimentalNoodle”: false,
“smartApply”: true,
“hasEditCapability”: false,
“webviewType”: “sidebar”,
“multipleWebviewsEnabled”: true,
“internalDebugContext”: false,
“allowEndpointChange”: true,
“experimentalPromptEditorEnabled”: false,
“experimentalAgenticChatEnabled”: false,
“attribution”: “none”
}
█ ChatController updateClientConfig: {
“codyEnabled”: true,
“chatEnabled”: true,
“autoCompleteEnabled”: true,
“customCommandsEnabled”: true,
“attributionEnabled”: false,
“attribution”: “none”,
“smartContextWindowEnabled”: true,
“modelsAPIEnabled”: false,
“latestSupportedCompletionsStreamAPIVersion”: 9,
“notices”: ,
“omniBoxEnabled”: true,
“codeSearchEnabled”: true
}
█ ChatController updateViewConfig: {
“uiKindIsWeb”: false,
“serverEndpoint”: “https://sourcegraph.com/”,
“endpointHistory”: [
https://sourcegraph.com/
],
“experimentalNoodle”: false,
“smartApply”: true,
“hasEditCapability”: false,
“webviewType”: “sidebar”,
“multipleWebviewsEnabled”: true,
“internalDebugContext”: false,
“allowEndpointChange”: true,
“experimentalPromptEditorEnabled”: false,
“experimentalAgenticChatEnabled”: false,
“attribution”: “none”
}
█ ChatController handleUserMessageSubmission: traceId: 6d6af1b3060ce994382a33a9a2aa7618
█ telemetry-v2 recordEvent: cody.humanMessageEditor/submit: {
“parameters”: {
“version”: 0,
“metadata”: [
{
“key”: “isFirstMessage”,
“value”: 1
},
{
“key”: “isEdit”,
“value”: 0
},
{
“key”: “messageLength”,
“value”: 35
},
{
“key”: “contextItems”,
“value”: 2
},
{
“key”: “intent”,
“value”: 0
},
{
“key”: “tier”,
“value”: 1
}
],
“billingMetadata”: {
“product”: “cody”,
“category”: “billable”
}
},
“timestamp”: “2025-04-10T11:15:33.497Z”
}
█ telemetry-v2 recordEvent: cody.chat-question/submitted: {
“parameters”: {
“version”: 0,
“metadata”: [
{
“key”: “recordsPrivateMetadataTranscript”,
“value”: 1
},
{
“key”: “isPublicRepo”,
“value”: 0
},
{
“key”: “isCommand”,
“value”: 0
},
{
“key”: “sessionIdEpoch”,
“value”: 1744283450000
},
{
“key”: “tier”,
“value”: 1
}
],
“privateMetadata”: {
“chatModel”: “anthropic::2024-10-22::claude-3-7-sonnet-latest”,
“requestID”: “06c9748d-b495-4946-b156-485030d1ff2b”,
“sessionID”: “Thu, 10 Apr 2025 11:10:50 GMT”,
“traceId”: “6d6af1b3060ce994382a33a9a2aa7618”,
“promptText”: “src/PyComicRack.py PyComicRack hola”
},
“billingMetadata”: {
“product”: “cody”,
“category”: “billable”
}
},
“timestamp”: “2025-04-10T11:15:33.506Z”
}
█ Completions:onComplete duration:“926ms” stopReason:“undefined” outputChannelId:“03b889e8-bd78-4194-b882-434b66721e68”: {
“completion”: “PyComicRack: Python script for comic book management\n”
}
█ telemetry-v2 recordEvent: cody.chat.customTitle/generated: {
“parameters”: {
“version”: 0,
“metadata”: [
{
“key”: “titleLength”,
“value”: 53
},
{
“key”: “inputLength”,
“value”: 35
},
{
“key”: “tier”,
“value”: 1
}
],
“privateMetadata”: {
“requestID”: “06c9748d-b495-4946-b156-485030d1ff2b”,
“model”: “google::v1::gemini-2.0-flash-lite”,
“traceId”: “6d6af1b3060ce994382a33a9a2aa7618”
},
“billingMetadata”: {
“product”: “cody”,
“category”: “billable”
}
},
“timestamp”: “2025-04-10T11:15:34.421Z”
}
█ Completions:onComplete duration:“720ms” stopReason:“undefined” outputChannelId:“6a758fc6-1e57-4dfd-9447-46d2b9826dbb”: {
“completion”: “hola”
}
█ ChatController resolveContext > symf /k:/PyComicRack (start)
█ symf using downloaded symf “c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\symf-v0.0.16-x86_64-windows”
█ ChatController: postError Failed to retrieve search context: EvalError: symf failed: Error: spawn ENAMETOOLONG
█ SymfRunner reindexIfStale: k:\PyComicRack
█ SymfRunner unsafeEnsureIndex: file:///k%3A/PyComicRack {
“options”: {
“retryIfLastAttemptFailed”: true,
“ignoreExisting”: false
}
}
█ symf using downloaded symf “c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\symf-v0.0.16-x86_64-windows”
█ SymfRunner statIndex: c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\symf-v0.0.16-x86_64-windows --index-root c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\indexroot\k\PyComicRack status k:\PyComicRack
█ symf using downloaded symf “c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\symf-v0.0.16-x86_64-windows”
█ SymfRunner running symf: c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\symf-v0.0.16-x86_64-windows --index-root c:\Users\tomas\AppData\Roaming\Code\User\globalStorage\sourcegraph.cody-ai\symf\indexroot\k\PyComicRack query --scopes k:\PyComicRack --fmt json --boosted-keywords “hola” hola
█ ChatController resolveContext > symf /k:/PyComicRack (end)
█ telemetry-v2 recordEvent: cody.userMenu/open: {
“parameters”: {
“version”: 0,
“metadata”: [
{
“key”: “tier”,
“value”: 1
}
]
},
“timestamp”: “2025-04-10T11:17:48.639Z”
}
█ ClientConfigSingleton refreshing configuration
█ ClientConfigSingleton refreshed: {“codyEnabled”:true,“chatEnabled”:true,“autoCompleteEnabled”:true,“customCommandsEnabled”:true,“attributionEnabled”:false,“attribution”:“none”,“smartContextWindowEnabled”:true,“modelsAPIEnabled”:false,“latestSupportedCompletionsStreamAPIVersion”:9}