Enforce empty lines before classes and functions with sticky leading comments (#3302)
Reformat empty and whitespace-only files as either an empty file (if no newline is
present) or as a single newline character (if a newline is present) (#3348)
Implicitly concatenated strings used as function args are now wrapped inside
parentheses (#3307)
Correctly handle trailing commas that are inside a line's leading non-nested parens
(#3370)
Configuration
Fix incorrectly applied .gitignore rules by considering the .gitignore location
and the relative path to the target file (#3338)
Fix incorrectly ignoring .gitignore presence when more than one source directory is
specified (#3336)
Parser
Parsing support has been added for walruses inside generator expression that are
passed as function args (for example,
any(match := my_re.match(text) for text in texts)) (#3327).
Integrations
Vim plugin: Optionally allow using the system installation of Black via
let g:black_use_virtualenv = 0(#3309)
22.10.0
Highlights
Runtime support for Python 3.6 has been removed. Formatting 3.6 code will still be
supported until further notice.
Stable style
Fix a crash when # fmt: on is used on a different block level than # fmt: off
(#3281)
Enforce empty lines before classes and functions with sticky leading comments (#3302)
Reformat empty and whitespace-only files as either an empty file (if no newline is
present) or as a single newline character (if a newline is present) (#3348)
Implicitly concatenated strings used as function args are now wrapped inside
parentheses (#3307)
Correctly handle trailing commas that are inside a line's leading non-nested parens
(#3370)
Configuration
Fix incorrectly applied .gitignore rules by considering the .gitignore location
and the relative path to the target file (#3338)
Fix incorrectly ignoring .gitignore presence when more than one source directory is
specified (#3336)
Parser
Parsing support has been added for walruses inside generator expression that are
passed as function args (for example,
any(match := my_re.match(text) for text in texts)) (#3327).
Integrations
Vim plugin: Optionally allow using the system installation of Black via
let g:black_use_virtualenv = 0(#3309)
22.10.0
Highlights
Runtime support for Python 3.6 has been removed. Formatting 3.6 code will still be
supported until further notice.
Stable style
Fix a crash when # fmt: on is used on a different block level than # fmt: off
(#3281)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Bumps black from 21.9b0 to 22.12.0.
Release notes
Sourced from black's releases.
... (truncated)
Changelog
Sourced from black's changelog.
... (truncated)
Commits
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)