Basic syntax highlighting problem in the editor

Got tons of syntax highlighting problems. Feels like the syntax service didn’t update to change.
For example:

Before change:

Comment out a line:

The from and import didn’t reflect the change.

After reload:

This is what it suppose to be.

The problem happens to all themes, and everywhere, not just at the import. Doing countless reload nowadays to get the color right. It’s distracting and breaking the flow.
Any suggestion?

1 Like

Hmm, does the same thing happen in original VSCode with the same extensions installed?

Does not happen to vscode. The screenshots are taken from fresh install Cursor, with import setting and extensions from vscode.

v: 0.25.2
osx: 14.3

The problem is python language server.
Change it to pylance solves the problem.
Default, which is cursor pyright, simply won’t work.
I have fresh installation, no import from vscode, and only has 2 extensions installed: cursor pyright, cursor python.

The real problem is when I set it to pylance, the setting would automatically revert back to default for no reason. The syntax color won’t refresh again, linting is off, etc.
Have to manually set python language server to pylance every single restart and window reload.

This is a flow breaking bug, forcing me to unsubscribe and the only reason preventing me from making cursor the daily driver.

Version: 0.27.2
VSCode Version: 1.85.1
Commit: 56becd74fc3058ee97a0b2496d8ae7ad2c2fcb10
Date: 2024-02-16T04:22:48.557Z
Electron: 25.9.7
ElectronBuildId: undefined
Chromium: 114.0.5735.289
Node.js: 18.15.0
OS: Darwin arm64 23.3.0

1 Like

hmm, having to set it manually is really weird. im going to ask my friend aman to help here. @amanrs

Will look into this tomorrow, could you follow up at

New user here . . . any updates on this problem? I have the Cursor Pyright extension install. When I make an edit (such as commenting a line of code), I see this in the language server output:

2024-03-17 19:42:13.753 [info] [Error - 7:42:13 PM] Request textDocument/semanticTokens/full/delta failed.
2024-03-17 19:42:13.753 [info]   Message: No semantic tokens provided/needed for file:///path/to/my/python/filepy

Found this issue, too: Python syntax highlighting fails without window reload · Issue #1205 · getcursor/cursor · GitHub