Skip to content
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

Prefer property decorator to explicit call #765

Open
jaraco opened this issue Dec 5, 2022 · 0 comments
Open

Prefer property decorator to explicit call #765

jaraco opened this issue Dec 5, 2022 · 0 comments

Comments

@jaraco
Copy link

jaraco commented Dec 5, 2022

This is a feature request for pyupgrade.

Prior to Python 2.4, it wasn't possible to use decorators, so properties were had to be implemented in a two-step process. I recently stumbled onto such code and had hopes pyupgrade would automatically fix that usage, but alas, it did not. It would be nice if pyupgrade could support upgrading that syntax.

Even better would be if it could also upgrade the setter syntax and maybe others (I don't think I've ever used a deleter).

Given the age of Python 2.3 compatible code, it may not be worthwhile implementing this upgrade, but I thought I'd register the concern.

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

No branches or pull requests

1 participant