Skip to content

Refactor/cleanup error handling code#20814

Open
ilevkivskyi wants to merge 3 commits intopython:masterfrom
ilevkivskyi:cleanup-errors
Open

Refactor/cleanup error handling code#20814
ilevkivskyi wants to merge 3 commits intopython:masterfrom
ilevkivskyi:cleanup-errors

Conversation

@ilevkivskyi
Copy link
Member

@ilevkivskyi ilevkivskyi commented Feb 14, 2026

Various things in this PR:

  • Minimized breakages of abstraction layers
  • Added/updated docstrings/comments
  • More consistent argument/attribute naming
  • Removed redundant attributes/arguments (most important part probably)
  • Fixed inconsistent order of arguments in helpers
  • Added few asserts
  • Removed some redundant normalizations w.r.t. defaults

This is 99% pure refactoring (that removes 100 lines of code), the only non-trivial (but still minor) things are:

  • Fix end line/column for f-strings
  • More consistent error formatting for some of the errors

@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

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