Codebase indexing handshake failure

:white_check_mark: Check the forum to ensure the issue hasn’t been reported already
:lady_beetle: Provide a clear description of the bug

At some point today I keep getting the codebase not indexed notification while trying to chat with cursor about my project. Then I notice the codebase indexing is looping between handshake failure → loading → setting up → handshake failure.

All the chats will start at first and then get stuck at generation and then stop showing Connection failed. If the problem persists, please check your internet connection or VPN

(Request ID: b6ae7a2d-facc-4ae6-94b7-ff754bdbe398)

Here is the error log from Cursor indexing and retrieval:

2025-04-23 19:41:52.480 [info] multiCodebaseIndexingJob dispose

2025-04-23 19:41:52.480 [info] Aborting indexing job.

2025-04-23 19:41:52.480 [info] Indexing job successfully done or aborted.

2025-04-23 19:41:52.581 [info] Using existing keys for an index

2025-04-23 19:41:52.582 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0

2025-04-23 19:41:54.178 [info] Using existing keys for an index

2025-04-23 19:41:54.178 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0

2025-04-23 19:41:54.178 [info] Setting indexing intent to should-index

2025-04-23 19:41:54.178 [info] Using existing keys for an index

2025-04-23 19:41:54.179 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0

2025-04-23 19:41:54.210 [info] Doing a startup handshake.

2025-04-23 19:41:54.351 [info] Finished computing merkle tree in 83.58702900027856 ms.

2025-04-23 19:41:54.352 [info] Doing the initial handshake with hash: 1a66074ddf54fe22d4d49968c6d3c0ded4f5cddf77906f88743b8bce7016af45

2025-04-23 19:41:54.356 [info] Computed simhash vector of length: 256

2025-04-23 19:41:54.356 [info] Path key hash: 5fb463aeef14637efb12e466a197ad6cd4b20efb06264f673389ff1c27a6f8c0

2025-04-23 19:41:54.356 [info] Handshake start

2025-04-23 19:41:56.444 [warning] Retrying handshake with timeout 4000. Error: [internal] self-signed certificate in certificate chain

2025-04-23 19:41:56.444 [info] Handshake start

2025-04-23 19:42:00.549 [warning] Retrying handshake with timeout 8000. Error: [internal] self-signed certificate in certificate chain

2025-04-23 19:42:00.549 [info] Handshake start

2025-04-23 19:42:08.625 [warning] Retrying handshake with timeout 16000. Error: [internal] self-signed certificate in certificate chain

2025-04-23 19:42:08.626 [info] Handshake start

2025-04-23 19:42:24.719 [warning] Retrying handshake with timeout 32000. Error: [internal] self-signed certificate in certificate chain

2025-04-23 19:42:24.719 [info] Handshake start

I saw some other post saying by disable http/2, indexing won’t work, but the same setting has been working for me until today.

:counterclockwise_arrows_button: Explain how to reproduce the bug (if known)

I am behind corporate network, and disabled http/2. It works fine until today.

UPDATE:

When I open the project on local machine, the indexing works. However, when I ssh into remote server (physical machine in the company instead of any cloud based service), I get the handshake error as shown above. And it only happens since this afternoon.

:camera: Attach screenshots or recordings (e.g., .jpg, .png, .mp4).


image

:laptop: Tell us your operating system and your Cursor version (e.g., Windows, 0.x.x).

Version: 0.49.4 (Universal)
VSCode Version: 1.96.2
Commit: ec408037b24566b11e6132c58bbe6ad27046eb90
Date: 2025-04-22T00:33:06.906Z
Electron: 34.3.4
Chromium: 132.0.6834.210
Node.js: 20.18.3
V8: 13.2.152.41-electron.0
OS: Darwin arm64 24.4.0

:prohibited: Tell us if the issue stops you from using Cursor.

Have you turned off the vpn proxy?

Hi, I don’t think so.

The http:proxy (The proxy setting to use. If not set, will be inherited from the http_proxy and https_proxy environment variables.) contains the proxy value,

    "http.proxy": "http://XXXXX",
    "cursor.general.disableHttp2": true,
    "cursor.general.gitGraphIndexing": "disabled",
    "http.proxyAuthorization": null
}

http: proxy strict SSL is checked,
http:proxy support : override,
disable http2 checked,
fetch additional support checked

I think you can try turning off the vpn

My company use zscaler, it’s slighly different from VPN. I also don’t have a way to turn it off

On second inspection, strangely the local codebase can be index, it’s the codebase in the remote server that has the handshake failure and certificate issue.

This is the log for the remote server

2025-04-23 22:03:33.815 [info] Creating Indexing Repo client:  https://repo42.cursor.sh
2025-04-23 22:03:33.815 [info] Creating repo client with backend url: https://api2.cursor.sh
2025-04-23 22:03:33.915 [info] Making keys for a new index
2025-04-23 22:03:33.935 [info] Making keys for a new index
2025-04-23 22:03:34.043 [info] Using the default key from the server for a new index
2025-04-23 22:03:34.044 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0
2025-04-23 22:03:34.056 [info] Using the default key from the server for a new index
2025-04-23 22:03:34.056 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0
2025-04-23 22:03:34.194 [info] Doing a startup handshake.
2025-04-23 22:03:34.286 [info] Finished computing merkle tree in 69.40637300000003 ms.
2025-04-23 22:03:34.287 [info] Doing the initial handshake with hash: 7930e55729b7363537cf70bb99c079cdf9c1b26111de3fc1314de58e0f5c47a0
2025-04-23 22:03:34.300 [info] Computed simhash vector of length: 256
2025-04-23 22:03:34.300 [info] Path key hash: 5fb463aeef14637efb12e466a197ad6cd4b20efb06264f673389ff1c27a6f8c0
2025-04-23 22:03:34.300 [info] Handshake start
2025-04-23 22:03:34.350 [warning] Error reading high level folder description. Ignoring. Error: ENOENT: no such file or directory, open '/home/zhoqiaoh/.cursor-server/data/User/workspaceStorage/e9e18cb4d67f80422ed25384cc1ac8c5/anysphere.cursor-retrieval/high_level_folder_description.txt'
2025-04-23 22:03:34.451 [error] Git command failed: git cat-file -e origin/main:.devcontainer/devcontainer.json Command failed: git cat-file -e origin/main:.devcontainer/devcontainer.json
fatal: Not a valid object name origin/main:.devcontainer/devcontainer.json

2025-04-23 22:03:34.521 [warning] Error computing full high level folder description. Ignoring. [internal] self-signed certificate in certificate chain
2025-04-23 22:03:36.366 [warning] Retrying handshake with timeout 4000. Error:  [internal] self-signed certificate in certificate chain
2025-04-23 22:03:36.366 [info] Handshake start
2025-04-23 22:03:40.430 [warning] Retrying handshake with timeout 8000. Error:  [internal] self-signed certificate in certificate chain
2025-04-23 22:03:40.430 [info] Handshake start
2025-04-23 22:03:48.531 [warning] Retrying handshake with timeout 16000. Error:  [internal] self-signed certificate in certificate chain
2025-04-23 22:03:48.531 [info] Handshake start
2025-04-23 22:04:04.640 [warning] Retrying handshake with timeout 32000. Error:  [internal] self-signed certificate in certificate chain
2025-04-23 22:04:04.640 [info] Handshake start
2025-04-23 22:04:36.736 [warning] Retrying handshake with timeout 64000. Error:  [internal] self-signed certificate in certificate chain
2025-04-23 22:04:36.736 [info] Handshake start
2025-04-23 22:05:40.834 [warning] Retrying handshake with timeout 128000. Error:  [internal] self-signed certificate in certificate chain
2025-04-23 22:05:40.834 [error] Handshake failed:
2025-04-23 22:05:40.834 [error] Error: timeout in handshake with retry
	at A.RepoClientMultiplexer.tryHandshake (/home/zhoqiaoh/.cursor-server/cli/servers/Stable-ec408037b24566b11e6132c58bbe6ad27046eb90/server/extensions/cursor-retrieval/dist/main.js:2:1377017)
	at async A.RepoClientMultiplexer.handshakeWithRetry (/home/zhoqiaoh/.cursor-server/cli/servers/Stable-ec408037b24566b11e6132c58bbe6ad27046eb90/server/extensions/cursor-retrieval/dist/main.js:2:1374638)
	at async T.getServerStatus (/home/zhoqiaoh/.cursor-server/cli/servers/Stable-ec408037b24566b11e6132c58bbe6ad27046eb90/server/extensions/cursor-retrieval/dist/main.js:2:1386938)
	at async T.startIndexingRepository (/home/zhoqiaoh/.cursor-server/cli/servers/Stable-ec408037b24566b11e6132c58bbe6ad27046eb90/server/extensions/cursor-retrieval/dist/main.js:2:1388545)
2025-04-23 22:05:40.835 [error] Handshake failed.

This is when trying on local machine (assuming this is success?)

2025-04-23 21:53:01.622 [info] Finished computing merkle tree in 431.6322500000001 ms.
2025-04-23 21:53:01.622 [info] Doing the initial handshake with hash: ae15552f31b1b8f16934d6ec1d4379aad9788ec6ba562edf2fea42021116778c
2025-04-23 21:53:01.624 [info] Computed simhash vector of length: 256
2025-04-23 21:53:01.624 [info] Path key hash: bde4db78b1926bf7f30c8518361e1f34145acc8d020592f0e70280df169e22d1
2025-04-23 21:53:01.624 [info] Handshake start
2025-04-23 21:53:01.849 [info] Handshake timing: 225.47237500000028, response: {"status":"STATUS_SUCCESS","codebases":[{"codebaseId":"17727473-1d3f-41b1-a794-451e0184299a","status":"STATUS_UP_TO_DATE"}]}
2025-04-23 21:53:01.849 [info] Handshake result: {"status":"STATUS_SUCCESS","codebases":[{"codebaseId":"17727473-1d3f-41b1-a794-451e0184299a","status":"STATUS_UP_TO_DATE"}]}
2025-04-23 21:53:01.849 [info] Starting fast remote sync.
2025-04-23 21:53:01.849 [info] Total num embeddable files: 352
2025-04-23 21:53:01.849 [info] Root hash: ae15552f31b1b8f16934d6ec1d4379aad9788ec6ba562edf2fea42021116778c
2025-04-23 21:53:01.850 [info] Finishing sync (hasUpdates: false, isErr: false)
2025-04-23 21:53:02.621 [info] Finished indexing repository.
2025-04-23 21:53:02.621 [info] Indexing job successfully done or aborted.
2025-04-23 21:53:42.358 [info] multiCodebaseIndexingJob dispose
2025-04-23 21:53:42.358 [info] Aborting indexing job.
2025-04-23 21:54:58.570 [info] Creating Indexing Repo client:  https://repo42.cursor.sh
2025-04-23 21:54:58.570 [info] Creating repo client with backend url: https://api2.cursor.sh
2025-04-23 21:54:58.570 [info] Using existing keys for an index
2025-04-23 21:54:58.570 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0
2025-04-23 21:54:58.798 [info] Using existing keys for an index
2025-04-23 21:54:58.799 [info] InternalRepoInfo constructor with preferredEmbeddingModel 0
2025-04-23 21:54:58.800 [info] Setting global status from status tracker: synced
2025-04-23 21:54:58.800 [info] Doing a startup handshake.
2025-04-23 21:54:58.928 [info] Finished computing merkle tree in 120.39395800000011 ms.
2025-04-23 21:54:58.928 [info] Doing the initial handshake with hash: ae15552f31b1b8f16934d6ec1d4379aad9788ec6ba562edf2fea42021116778c
2025-04-23 21:54:58.931 [info] Computed simhash vector of length: 256
2025-04-23 21:54:58.931 [info] Path key hash: bde4db78b1926bf7f30c8518361e1f34145acc8d020592f0e70280df169e22d1
2025-04-23 21:54:58.931 [info] Handshake start
2025-04-23 21:54:59.222 [error] Git command failed: git cat-file -e origin/main:.devcontainer/devcontainer.json Command failed: git cat-file -e origin/main:.devcontainer/devcontainer.json
fatal: path '.devcontainer/devcontainer.json' does not exist in 'origin/main'

2025-04-23 21:54:59.234 [info] Handshake timing: 304.8527079999999, response: {"status":"STATUS_SUCCESS","codebases":[{"codebaseId":"17727473-1d3f-41b1-a794-451e0184299a","status":"STATUS_UP_TO_DATE"}]}
2025-04-23 21:54:59.234 [info] Handshake result: {"status":"STATUS_SUCCESS","codebases":[{"codebaseId":"17727473-1d3f-41b1-a794-451e0184299a","status":"STATUS_UP_TO_DATE"}]}
2025-04-23 21:54:59.234 [info] Starting fast remote sync.
2025-04-23 21:54:59.235 [info] Total num embeddable files: 352
2025-04-23 21:54:59.235 [info] Root hash: ae15552f31b1b8f16934d6ec1d4379aad9788ec6ba562edf2fea42021116778c
2025-04-23 21:54:59.236 [info] Finishing sync (hasUpdates: false, isErr: false)
2025-04-23 21:54:59.396 [info] Finished indexing repository.
2025-04-23 21:54:59.396 [info] Indexing job successfully done or aborted.
2025-04-23 21:59:57.491 [error] Git command failed: git cat-file -e origin/main:.devcontainer/devcontainer.json Command failed: git cat-file -e origin/main:.devcontainer/devcontainer.json
fatal: path '.devcontainer/devcontainer.json' does not exist in 'origin/main'

2025-04-23 21:59:58.811 [info] multiCodebaseIndexingJob dispose
2025-04-23 21:59:58.811 [info] Aborting indexing job.
2025-04-23 21:59:58.812 [info] Setting global status from status tracker: synced
2025-04-23 21:59:58.812 [info] Doing a startup handshake.
2025-04-23 21:59:58.825 [info] Finished computing merkle tree in 1.7152079999796115 ms.
2025-04-23 21:59:58.826 [info] Doing the initial handshake with hash: ae15552f31b1b8f16934d6ec1d4379aad9788ec6ba562edf2fea42021116778c
2025-04-23 21:59:58.829 [info] Computed simhash vector of length: 256
2025-04-23 21:59:58.830 [info] Path key hash: bde4db78b1926bf7f30c8518361e1f34145acc8d020592f0e70280df169e22d1
2025-04-23 21:59:58.830 [info] Handshake start
2025-04-23 21:59:59.056 [info] Handshake timing: 228.9323330000043, response: {"status":"STATUS_SUCCESS","codebases":[{"codebaseId":"17727473-1d3f-41b1-a794-451e0184299a","status":"STATUS_UP_TO_DATE"}]}
2025-04-23 21:59:59.057 [info] Handshake result: {"status":"STATUS_SUCCESS","codebases":[{"codebaseId":"17727473-1d3f-41b1-a794-451e0184299a","status":"STATUS_UP_TO_DATE"}]}
2025-04-23 21:59:59.057 [info] Starting fast remote sync.
2025-04-23 21:59:59.059 [info] Total num embeddable files: 352
2025-04-23 21:59:59.059 [info] Root hash: ae15552f31b1b8f16934d6ec1d4379aad9788ec6ba562edf2fea42021116778c
2025-04-23 21:59:59.061 [info] Finishing sync (hasUpdates: false, isErr: false)
2025-04-23 22:00:02.364 [info] Finished indexing repository.
2025-04-23 22:00:02.364 [info] Indexing job successfully done or aborted.

I don’t know either. Let’s see if there are any official personnel to answer this question

Today it was giving me this message all day. Does anyone know where I need to go to check the internet or the VPN? Because everything else on the PC works fine with the internet—all the LLMs I use on different platforms work correctly

Are you behind the corporate wall? It can also just be the slowness.

:sweat_smile: Hopefully. I don’t think they reply to most of the messages tho.