[python] On is-not-context error, show type #3583
Merged
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.
Issue and/or context: Found while working on #3581 / #3582.
In a debug script, due to a copy/paste error, I had
Note the trailing comma, which I did not see. (In the copy-from text, this had been in an argument list where comma is needed. In the paste-to text, I was assigning it to a variable, where comma is not needed.)
Then, running a repro, I got
This baffled me for a while since I was clearly setting
context
to be atiledbsoma.SOMATileDBContext
.Only on debugging and inserting a print of
type(context)
did I see my error.We need to automate that helpfulness here.
Changes:
Now it prints:
Notes for Reviewer: