You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I created this discussion because I don't really understand how automatic tests work. I cloned the directory, launched a virtual machine with python3.11.4, downloaded requirements.txt, pre-commit, black, ruff and mypy.
After that, I ran "ruff ." which didn't report any errors, when I ran "pre-commit run --all-files --show-diff-on-failure" all the tests passed, but when I ran "mypy .", I got hundreds of errors even though I didn't change anything in the programs. I don't understand how this is possible, since before each merge the pull request should have passed the tests. What's more, when I look at the pull requests, I see that they have passed the tests, whereas the hundreds of programs on which I see mypy errors have not been modified.
I guess the errors you get when you do 'mypy ...', just ignore them. So can you tell me what tests I need to run on my PC before making a pull request so that I don't get any failed tests?
@yamawe When mypy is ran in isolation it seems to give different results than when ran with pre-commit (See #8070)
In order to make a successful pull request, you just need 1)pre-commit to pass and 2) pytest . to pass
Thank you. Following your message, I launched pytest and received an error concerning an API key: "ERROR web_programming/currency_converter.py - KeyError: "API key must be provided in the 'AMDOREN_API_KEY' environment variable." Did I do something wrong or is this a bug?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Hello, I created this discussion because I don't really understand how automatic tests work. I cloned the directory, launched a virtual machine with python3.11.4, downloaded requirements.txt, pre-commit, black, ruff and mypy.
After that, I ran "ruff ." which didn't report any errors, when I ran "pre-commit run --all-files --show-diff-on-failure" all the tests passed, but when I ran "mypy .", I got hundreds of errors even though I didn't change anything in the programs. I don't understand how this is possible, since before each merge the pull request should have passed the tests. What's more, when I look at the pull requests, I see that they have passed the tests, whereas the hundreds of programs on which I see mypy errors have not been modified.
I guess the errors you get when you do 'mypy ...', just ignore them. So can you tell me what tests I need to run on my PC before making a pull request so that I don't get any failed tests?
thank you for your attention
All reactions