Closed rchiodo closed 1 month ago
According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅
Oh I also tested this with Pylance. Having a pyrightconfig.json behaves as you'd expect. It trumps everything in the settings.json.
Next steps after this:
According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅
According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅
I presume that you've done some basic manual tests with the CLI? We don't have much test coverage for CLI options, so please do a few basic smoke tests before committing.
I only did a couple, but I'll make sure to do some more. I was assuming the existing config tests were testing it a bunch, well because they didn't work on my first implementation :).
According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅
This is the first stage in enforcing that a pyrightconfig.json is the one source of truth.
I updated the configuration docs a bit (although I don't think my update is entirely necessary) to mention the fact that a pyrightconfig.json trumps settings.
I then reworked the logic in the config setup to make sure that:
There was some circular problems where the initialize from json was always assuming the command line had already set things but then went and applied new settings from the command line. Hopefully this is more linear. Config always first. Command line always after.