Updated Stubs for jsonschema#6486
Conversation
srittau
left a comment
There was a problem hiding this comment.
Thank you for updating the stubs! A few remarks below.
srittau
left a comment
There was a problem hiding this comment.
Thank you for the fixes. Two minor issues below then this is good to go!
This PR updates stubs to recognize new attributes added since the original stubbing in python#5784.
Co-authored-by: Sebastian Rittau <srittau@rittau.biz>
a95597d to
4ad187c
Compare
|
Nit: Avoid |
4ad187c to
50b96cc
Compare
As recommended by @Akuli
Noted, I'll do that in the future. |
7236a0c to
0c7803c
Compare
|
Derp. I've updated my git local configuration to avoid needing to force push in this repo. Sorry for the error. |
| def is_ipv4(instance) -> bool: ... | ||
| def is_ipv6(instance) -> bool: ... | ||
|
|
||
| # is_host_name is only defined if fqdn is installed. |
There was a problem hiding this comment.
Nit: It would be better to put these comments to the allowlist. You can add comments to end of line, e.g.
jsonschema._format.is_host_name # defined only if fqdn is installed
There was a problem hiding this comment.
I actually like them in the source file as well as the allowlist is basically invisible when developing with the stubs, while the comment in the source are visible when jumping into the stub file.
This PR updates stubs to recognize new attributes added since the
original stubbing in #5784.