asottile / pyupgrade

A tool (and pre-commit hook) to automatically upgrade syntax for newer versions of the language.
MIT License
3.62k stars 183 forks source link

Fix removal of comments after dropped version block #971

Open adamchainz opened 1 month ago

adamchainz commented 1 month ago

Attempt at fixing #970.

BonaFideIT commented 1 month ago

Looks good to me, seams to be the same solution as used in https://github.com/adamchainz/django-upgrade/pull/496/ for django-upgrade.