Fix AssertionError when inferring a property consisting of a partial function#2458
Merged
jacobtylerwalls merged 1 commit intomainfrom Jul 8, 2024
Merged
Fix AssertionError when inferring a property consisting of a partial function#2458jacobtylerwalls merged 1 commit intomainfrom
jacobtylerwalls merged 1 commit intomainfrom
Conversation
…function. Closes pylint-dev/pylint#9214 Thanks Martin Belanger for the report and Bryce Guinta for the test case.
jacobtylerwalls
commented
Jul 7, 2024
| elif isinstance(inferred, objects.Property): | ||
| function = inferred.function | ||
| if not class_context: | ||
| if not context.callcontext: |
Member
Author
There was a problem hiding this comment.
We may have the identical problem just below this, but I'm hesitant to just add it without a test case in hand. One thing at a time :-)
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2458 +/- ##
=======================================
Coverage 92.74% 92.74%
=======================================
Files 94 94
Lines 10993 10995 +2
=======================================
+ Hits 10195 10197 +2
Misses 798 798
Flags with carried forward coverage won't be shown. Click here to find out more.
|
DanielNoord
approved these changes
Jul 8, 2024
github-actions bot
pushed a commit
that referenced
this pull request
Jul 8, 2024
…function. (#2458) Closes pylint-dev/pylint#9214 Thanks Martin Belanger for the report and Bryce Guinta for the test case. (cherry picked from commit 0f9dfa6)
jacobtylerwalls
added a commit
that referenced
this pull request
Jul 9, 2024
…function. (#2458) Closes pylint-dev/pylint#9214 Thanks Martin Belanger for the report and Bryce Guinta for the test case. (cherry picked from commit 0f9dfa6)
jacobtylerwalls
added a commit
that referenced
this pull request
Jul 9, 2024
…function. (#2458) (#2460) Closes pylint-dev/pylint#9214 Thanks Martin Belanger for the report and Bryce Guinta for the test case. (cherry picked from commit 0f9dfa6) Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
Contributor
|
Nice! deceptively straightforward :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Type of Changes
Description
Closes pylint-dev/pylint#9214
Thanks Martin Belanger for the report and Bryce Guinta for the test case.
@brycepg would you like to review?