ChainMap.fromkeys
is positional-only
#13239
Closed
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.
This one took me on a journey. I was looking at
tkinter.Text.count
originally, and realized it was a bug in stubtest Signatures.I fixed the bug with python/mypy#18287 which only converts parameter names to index-based names if they're positional-only across all overloads. That MR makes the
tkinter.Text.count
error go away without any typeshed changes.I realized it was the same bug that the
ChainMap.fromkeys
allowlist entry is commented with, and I removed the line to see what was going on with it with the bug fixed. Stubtest was complaining that it wasn't positional-only. So it doesn't need to wait for that bug to get fixed after all, unless there's a reason I'm missing to go against the implementation on this. [EDIT] The reason was that it's not positional-only before 3.13.