Skip to content

Add py39 target in Black's configuration, bump Black to 21.5b2 #38376

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

Merged
merged 27 commits into from
Jun 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
e325835
Add py39 target for Black
Dec 8, 2020
22db7cb
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli May 11, 2021
fed6c3a
bump black version
fangchenli May 12, 2021
af6632f
bump black version
fangchenli May 12, 2021
b92b327
bump black version
fangchenli May 12, 2021
f18b432
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli May 14, 2021
02f6fca
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli May 16, 2021
15902be
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli May 18, 2021
5c95048
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli May 18, 2021
5986521
fix comments
fangchenli May 18, 2021
031be3c
Merge branch 'master' into add-black-py39-target
fangchenli May 21, 2021
427424e
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli May 21, 2021
f1f1d80
Merge branch 'master' into add-black-py39-target
fangchenli Jun 1, 2021
16071c4
update black version
fangchenli Jun 1, 2021
e4d7df8
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli Jun 6, 2021
c09405f
rebase
fangchenli Jun 6, 2021
f0b2d8e
Merge branch 'master' into add-black-py39-target
fangchenli Jun 8, 2021
cc37bf3
fix typo in comment
fangchenli Jun 8, 2021
d5f65ab
reformat
fangchenli Jun 8, 2021
bc1bdc3
fix error
fangchenli Jun 8, 2021
c81ed54
Merge branch 'master' into add-black-py39-target
fangchenli Jun 8, 2021
5d8a3c9
add comment back
fangchenli Jun 9, 2021
d7d9cc4
Merge remote-tracking branch 'origin/add-black-py39-target' into add-…
fangchenli Jun 9, 2021
a4eef8d
Merge remote-tracking branch 'upstream/master' into add-black-py39-ta…
fangchenli Jun 9, 2021
41dbc41
add comment back
fangchenli Jun 9, 2021
2fc201f
Merge branch 'master' into add-black-py39-target
fangchenli Jun 9, 2021
c3ea1bd
run black again
fangchenli Jun 9, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ repos:
- id: absolufy-imports
files: ^pandas/
- repo: https://github.com/python/black
rev: 20.8b1
rev: 21.5b2
hooks:
- id: black
- repo: https://github.com/codespell-project/codespell
Expand Down
2 changes: 1 addition & 1 deletion doc/source/development/contributing_codebase.rst
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ submitting code to run the check yourself::
to auto-format your code. Additionally, many editors have plugins that will
apply ``black`` as you edit files.

You should use a ``black`` version 20.8b1 as previous versions are not compatible
You should use a ``black`` version 21.5b2 as previous versions are not compatible
with the pandas codebase.

One caveat about ``git diff upstream/master -u -- "*.py" | flake8 --diff``: this
Expand Down
2 changes: 1 addition & 1 deletion environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ dependencies:
- cython>=0.29.21

# code checks
- black=20.8b1
- black=21.5b2
- cpplint
- flake8=3.9.2
- flake8-bugbear=21.3.2 # used by flake8, find likely bugs
Expand Down
8 changes: 4 additions & 4 deletions pandas/_config/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def get_default_val(pat: str):


class DictWrapper:
""" provide attribute-style access to a nested dict"""
"""provide attribute-style access to a nested dict"""

def __init__(self, d: dict[str, Any], prefix: str = ""):
object.__setattr__(self, "d", d)
Expand Down Expand Up @@ -571,7 +571,7 @@ def _get_root(key: str) -> tuple[dict[str, Any], str]:


def _is_deprecated(key: str) -> bool:
""" Returns True if the given option has been deprecated """
"""Returns True if the given option has been deprecated"""
key = key.lower()
return key in _deprecated_options

Expand Down Expand Up @@ -643,7 +643,7 @@ def _warn_if_deprecated(key: str) -> bool:


def _build_option_description(k: str) -> str:
""" Builds a formatted description of a registered option and prints it """
"""Builds a formatted description of a registered option and prints it"""
o = _get_registered_option(k)
d = _get_deprecated_option(k)

Expand All @@ -667,7 +667,7 @@ def _build_option_description(k: str) -> str:


def pp_options_list(keys: Iterable[str], width=80, _print: bool = False):
""" Builds a concise listing of available options, grouped by prefix """
"""Builds a concise listing of available options, grouped by prefix"""
from itertools import groupby
from textwrap import wrap

Expand Down
Loading