#๐Ÿ”’ Pylance spamming errors without my changing any code

17 messages ยท Page 1 of 1 (latest)

supple cradle
#

Greetings there,

Hope all are well. So, I have been running pylance on strict for the past year, and until today I have had 0 errors.

I launched my vscode today, and it suddenly is showing me 1k errors. I have not changed ANY code, and I worked with this repo two weeks ago, so it's not like it's been ages.

I would really appreciate some help. It's going on my nerves beyond reason. Thank you.

For context, these are the majority of what it's screaming about

"reportUnnecessaryIsInstance": false,
"reportConstantRedefinition": false,
"reportUnknownLambdaType": false,
"reportUnknownVariableType": false,
"reportUnknownArgumentType": false,
"reportUnknownMemberType": false,
"reportUnknownParameterType": false,
"reportMissingParameterType": false,
"reportMissingTypeArgument": false,

which I turned false today after the fact, so it can't be that I missed them or had them accidentally turned off before.

For context, here's my repo (specifically this branch):
https://github.com/Qualition/quick/tree/circuit-improvements

GitHub

Quick is an agnostic gate-based circuit SDK, providing an integrated interface for using any supported quantum circuit framework seamlessly. - GitHub - Qualition/quick at circuit-improvements

mossy anvilBOT
#

@supple cradle

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

supple cradle
#

For full context, I usually run this repo via WSL2 in VScode.

heavy locust
#

looks like a dict, check the structure.. its missing a comma, bracket, quote or something somewhere

#

also dicts error in weird ways, its not always at the highlighted portion

supple cradle
#

Just out of curiosity, did you read what I said above?

heavy locust
#

copy, paste could lead to indentation errors such as the dif in tab/space..
try to zero out the lines and reform it

supple cradle
#

I don't think you understood what my issue is.

dire sorrel
fringe cloak
#

the errors are valid, i think your pylance hasn't actually been on strict mode before. you indeed have a bunch of functions without parameter types (reportMissingParameterType), so each usage of those parameters is giving an error (all the reportUnknown...Type)
you also have a bunch of places where you use a generic type without arguments, like just list (reportMissingTypeArgument)

supple cradle
#

If it's valid, then I guess I have a long PR to work on. FML.

#

Ignorance is (was) bliss, hehe.

#

Thank you very much Lambda for checking it out. Appreciate it.

mossy anvilBOT
#
Python help channel closed for inactivity

This help channel has been closed. Feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.