-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Radon crashes on unrelated config option in pyproject.toml #244
Comments
Happens to me with a Pytorch dependency. |
Very interesting issue @jannismain, thanks for raising! I have opened a PR to resolve the issue (#252), would be great if you could take a look - and maintainers such as @rubik - to review the changes and provide any feedback. In essence, the issue is a result of radon using a config parser that uses the '%' sign for inserting or substituting values from other keys and that radon passes the entire configuration file to the parser - as opposed to the radon section only. If you are not not dependent on radon versions later than 6.0.0 (including pyproject.toml support for radon configuration), rolling back to 5.1.0 should resolve the issue for you until the PR is merged. |
@kieran-ryan the solution you provided in #252 solved the issue I described above for my minimal example. Scoping the config parser to only the radon section is an elegant solution 👍🏻 |
When I have a string format in an unrelated section in pyproject.toml, radon crashes with the following message:
My minimal example config:
I have encountered this when upgrading to radon 6.0.1 while using a custom
log_format
option in a pytest configuration section.The text was updated successfully, but these errors were encountered: