Jelle Zijlstra

Results 127 issues of Jelle Zijlstra

Currently, Black uses a vendored version of [lib2to3](https://docs.python.org/3/library/2to3.html#module-lib2to3) for parsing. This works well for parsing Python 2 and early Python 3, but Python has now moved on to a PEG-based...

T: enhancement
S: accepted
C: parser

We often get proposals for formatting changes that could be useful, but that change the AST or are otherwise unsafe. Examples include: - Import sorting (#333) - Formatting stringified annotations...

T: enhancement
T: design
S: needs discussion

Currently, our config options are documented only in a collapsed-by-default text block in https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html#command-line-options. This is not very discoverable and makes it hard to give more detailed documentation, such as...

T: documentation

Test cases like `check("""f'{f"hello"}'""")` fail. This is somewhat tricky to implement and it's not very pretty code, so I'm going to not worry about it for now.

We already do this for str.format: https://github.com/JelleZijlstra/autotyping/blob/master/autotyping/autotyping.py#L536

I found a few small differences between this implementation and `collections.namedtuple`: - There's no docstring on the namedtuple class (`Point.__doc__` returns None). - `inspect.signature` doesn't work on cnamedtuple classes, but...

I'd like to start using https://www.python.org/dev/peps/pep-0647/ in typeshed. Do you have any plans in that direction already? I can look into adding basic support to unblock typeshed, which would mean...

enhancement
cat: core

I'm working to get rid of the type checker-specific symbols that currently are in our core stubs but don't exist at runtime. I'll use this issue to track the work...

stubs: improvement

In addition to mypy-primer, it would be useful to have a pyright-primer to see how changes we make affect pyright's type checking. @erictraut do you agree? Would your team be...

project-discussion

Compiling the below: ``` from typing import Final class StringParser: DEFAULT_TOKEN: Final = -1 d: Final = {DEFAULT_TOKEN: 1} ``` And running it produces: ``` $ mypyc fud.py $ python...

bug
priority-0-high