Skip to content

Improve pylint compliance in formula parser#164

Draft
alexanderthclark wants to merge 1 commit into
mainfrom
codex/lint-formula-module
Draft

Improve pylint compliance in formula parser#164
alexanderthclark wants to merge 1 commit into
mainfrom
codex/lint-formula-module

Conversation

@alexanderthclark
Copy link
Copy Markdown
Owner

Summary

  • Focus pylint cleanup on one module: freeride/formula.py.
  • Replace the stale module docstring, remove trailing whitespace, and avoid implicit string concatenation in the quadratic term regex.
  • Refactor the restricted AST evaluator to use an explicit operator map and a single return path.
  • Rename internal parser temporaries so pylint no longer reports coefficient/point names in this module.

Impact

  • No public API changes: _formula(...) and _quadratic_formula(...) keep the same inputs and outputs.
  • This does not attempt to fix repo-wide pylint. It makes one module clean under the current local pylint version.

Testing

  • python -m pylint freeride/formula.py -> 10.00/10
  • pytest -q tests/test_formula.py -> 21 passed
  • pytest -q -> 136 passed

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.

1 participant