KEMBAR78
Analyze descriptor methods as if they're methods, not functions by janverb · Pull Request #8365 · python/mypy · GitHub
Skip to content

Conversation

janverb
Copy link
Contributor

@janverb janverb commented Feb 4, 2020

When __get__ and __set__ were implicitly called they were analyzed without taking the type of the descriptor into account. That meant that they were only visible to plugins as function calls with unclear
names.

@msullivan
Copy link
Collaborator

This seems reasonable and I'm happy to merge it. Can a test be written, though?

@janverb
Copy link
Contributor Author

janverb commented Feb 10, 2020

Of course. Thank you for reminding me, I ended up finding an issue with how I did it.

When __get__ and __set__ were implicitly called they were analyzed
without taking the type of the descriptor into account. That meant
that they were only visible to plugins as function calls with unclear
names.
@janverb janverb force-pushed the fix-descriptor-methods branch from dd4bab4 to facfd9b Compare February 11, 2020 09:55
@msullivan msullivan merged commit 8b3b1d8 into python:master Feb 21, 2020
@janverb janverb deleted the fix-descriptor-methods branch February 24, 2020 08:33
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.

2 participants