FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Fix crash with `--cache-fine-grained --cache-dir=/dev/null` by hauntsaninja · Pull Request #18457 · python/mypy · GitHub

Repository navigation

Fix crash with --cache-fine-grained --cache-dir=/dev/null - #18457

Merged
hauntsaninja merged 1 commit into
python:masterfrom
hauntsaninja:fix-crasher
Jan 13, 2025
Merged

hauntsaninja merged 1 commit into
python:masterfrom
hauntsaninja:fix-crasher

Conversation

hauntsaninja commented Jan 13, 2025 •
edited
Loading

Copy link
Copy Markdown
Collaborator

Fixes #18454

Couldn't easily repro in test suite. See #18454 (comment) for repro

Fixes python#18454

Couldn't easily repro in test suite
hauntsaninja changed the title Fix crash with --cache-dir=/dev/null Fix crash with --cache-fine-grained --cache-dir=/dev/null Jan 13, 2025

Copy link
Copy Markdown
Contributor

Diff from mypy_primer, showing the effect of this PR on open source code:

schemathesis (https://github.com/schemathesis/schemathesis)
- Traceback (most recent call last):
-   File "/tmp/mypy_primer/old_mypy/venv/bin/mypy", line 8, in <module>
-     sys.exit(console_entry())
-              ^^^^^^^^^^^^^^^
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/__main__.py", line 15, in console_entry
-     main()
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/main.py", line 119, in main
-     res, messages, blockers = run_build(sources, options, fscache, t0, stdout, stderr)
-                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/main.py", line 203, in run_build
-     res = build.build(sources, options, None, flush_errors, fscache, stdout, stderr)
-           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/build.py", line 191, in build
-     result = _build(
-              ^^^^^^^
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/build.py", line 267, in _build
-     graph = dispatch(sources, manager, stdout)
-             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/build.py", line 2947, in dispatch
-     write_deps_cache(rdeps, manager, graph)
-   File "/tmp/mypy_primer/old_mypy/venv/lib/python3.12/site-packages/mypy/build.py", line 976, in write_deps_cache
-     assert st.meta, "Module must be either parsed or cached"
-            ^^^^^^^
- AssertionError: Module must be either parsed or cached

Copy link
Copy Markdown
Collaborator Author

But can repro in primer! :-)

hauntsaninja merged commit d7ebe2e into python:master Jan 13, 2025
hauntsaninja deleted the fix-crasher branch January 13, 2025 23:25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Crash on schemathesis with --cache-dir=/dev/null

1 participant


Back | FazBrowse Home | New Git URL