VS Code Not Recognizing += Operators

Hello, I'm on Windows 10 using VS Code, and I'm a bit confused about something that's happening.

I downloaded this template that's super helpful for getting started, and the first time I ran it it worked perfectly. However, after closing the project and reopening it later, my environment is no longer recognizing my "+=" operator.
image

I've double-checked my .vscode settings json over and over, which includes the following lines:

"Lua.diagnostics.disable": ["undefined-global", "lowercase-global", "undefined-doc-class"],
"Lua.runtime.nonstandardSymbol": ["+=", "-=", "*=", "/="],

I'm under the impression I shouldn't be seeing these errors anymore but I'm not sure what to do. It's incredibly frustrating - I also was having issues with it recognizing the playdate SDK but I think I got those ones figured out. Now it's just this.

Help is appreciated!

1 Like

This is what I have in my VSCode (for Mac) project's .vscode/settings.json file. I vaguely remember having to quit and reopen VSCode for some settings to take effect? Could be worth a try :grimacing:

I had this issue too even after a few restarts. Disabling and re-enabling the sumneko Lua extension fixed it for me.

1 Like

When I disable that plugin, it's all good. When I re-enable it it stops working again. Strange, not too big of a deal though. Thanks for the guidance! I'm a little closer to diagnosing I suppose, haha

I had to revert to an older version of the Lua extension by sumneko (v3.2.0) for this to keep on working. Updating to the latest (v3.2.5 at the time of writing this) caused the issue you described.