Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blacken .py files in blib2to3 #1011

Merged
merged 2 commits into from Oct 20, 2019
Merged

Blacken .py files in blib2to3 #1011

merged 2 commits into from Oct 20, 2019

Conversation

msullivan
Copy link
Contributor

This is in preparation for adding type annotations to blib2to3 in
order to compiling it with mypyc (#1009, which I can rebase on top of
this).

To enforce that it stays blackened, I just cargo-culted the existing
test code used for validating formatting. It feels pretty clunky now,
though, so I can abstract the common logic out into a helper if that
seems better. (But error messages might be less clear then?)

@JelleZijlstra
Copy link
Collaborator

Sorry for the radio silence on this! I'm about to go on a trip for a week, but after that I can give more feedback and hopefully merge this PR in. I'm excited to get Black faster using mypyc.

It would be good to make the tests less repetitive, but that can be a follow-up PR.

@msullivan
Copy link
Contributor Author

I've cleaned up the tests. CI is failing because of an issue found checking under mypy 0.730, which I put up #1039 to fix.

This is in preparation for adding type annotations to blib2to3 in
order to compiling it with mypyc (psf#1009, which I can rebase on top of
this).

To enforce that it stays blackened, I just cargo-culted the existing
test code used for validating formatting. It feels pretty clunky now,
though, so I can abstract the common logic out into a helper if that
seems better. (But error messages might be less clear then?)
@ambv ambv merged commit 0ff718e into psf:master Oct 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants