Closed MichaReiser closed 3 weeks ago
With #14091 merged (which fixed the issue in src/blib2to3/pgen2/driver.py
), we can now run a release version of red-knot on the full black
codebase. (The other two issues likely have been fixed in the meantime?)
However, the debug version still fails due to some new debug assertions:
thread '<unnamed>' panicked at crates/red_knot_python_semantic/src/types/infer.rs:3752:17:
assertion `left == right` failed
left: Invalid
right: Load
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
thread '<unnamed>' panicked at crates/red_knot_python_semantic/src/types/infer.rs:3752:17:
assertion `left == right` failed
left: Invalid
right: Load
For context, the ExprContext::Invalid
is used where the expressions are invalid i.e., these files contains syntax errors (#13778).
The two remaining panics from the original description and the assertions mentioned in my previous comment are now resolved.
But there is a new panic, which I have opened a separate ticket for (#14307) and added to the list above.
Red knot can now run on the full black
repository without any panics, allowing us to use it as a benchmark.
Currently it takes 120 ms for a cold run (40 ms for the src/
folder).
[x]
tests/data/cases/pep_572_do_not_remove_parens.py
Backtrace
``` thread '[x]
src/blib2to3/pgen2/driver.py
Logs
``` 2024-09-23 09:41:28.949226820 DEBUG Checking file '/home/micha/astral/black/tests/data/cases/ pep_572_do_not_remove_parens.py' 2024-09-23 09:43:38.612866625 DEBUG Module 'blib2to3.pgen2.tokenize' not found in the search paths. thread '[x]
tests/data/miscellaneous/pattern_matching_invalid.py
Backtrace
``` thread '[x] #14307