Several syntax errors not caught
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
Research direction
Review pull requests 20 and 8, then audit CPython's compile.c for compile-time syntax errors that Pyflakes does not report. Check the related issue about invalid global and nonlocal variables and the examples involving star expressions and async/await. Done means the missing compile-time errors are covered, either through targeted handling or the broader approach described in pull request 8.
Written by the indexing model from the issue text.
Description
I just realized that I never opened an issue about this. After https://github.com/PyCQA/pyflakes/pull/20, several compile-time syntax errors are warned about, but not all of them. The reason is that when I was going through the CPython source to find the compile-time errors, some of them seemed too esoteric or complicated, so I didn't implement them. A noncomprehensive list of example:
- Invalid use of global and nonlocal variables https://github.com/PyCQA/pyflakes/issues/249
- Some star expression things in Python 3.4. I don't know if pyflakes still supports 3.4, or if any of these are left in 3.5.
- Anything relating to async/await
These probably should be split out into separate issues, but it would also be a good idea to do an audit of compile.c (or just use my original idea, which will catch every compile-time syntax error automatically).
- Dominant language
- Python
- Stars
- 1.5k
- Forks
- 207
- Avg merge
- 4m
- Merged PRs (30d)
- 1
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from PyCQA/pyflakes
-
F542 is not a crimeOpen
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 52/100
-
Use of await in a function that is not async should be shown as a syntax error by flake8May be free again A pull request for this issue was closed without being merged. Open
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
Similar issues
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 85/100
NatLabRockies/openstudio-mcp#286 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
intersystems/ipm#1338 ·
Maintainers usually reply within 1 day
-
separate_packages splits imports from the same explicitly configured packagePossibly taken @rahul05ranjan claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 2 days
-
The v0-through-v1 path derives ShutdownDuration its own way, silently overriding a user's definitionOpenv1
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day