From da915b1b0d78394e0f4d96fea8ea43d4b15819b1 Mon Sep 17 00:00:00 2001 From: Fangchen Li Date: Tue, 20 Jul 2021 15:28:26 -0500 Subject: [PATCH 1/2] CLN: move isort config to pyproject.toml --- pyproject.toml | 14 ++++++++++++++ setup.cfg | 15 --------------- 2 files changed, 14 insertions(+), 15 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index e24704e24c5cb..92aecb2ac7b07 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -102,3 +102,17 @@ module = [ "pandas.tests.test_expressions", ] ignore_errors = true + +# To be kept consistent with "Import Formatting" section in contributing.rst +[tool.isort] +known_pre_libs = ["pandas._config"] +known_pre_core = ["pandas._libs", "pandas._typing", "pandas.util._*", "pandas.compat", "pandas.errors"] +known_dtypes = ["pandas.core.dtypes"] +known_post_core = ["pandas.tseries", "pandas.io", "pandas.plotting"] +sections = ["FUTURE", "STDLIB", "THIRDPARTY" ,"PRE_LIBS" , "PRE_CORE", "DTYPES", "FIRSTPARTY", "POST_CORE", "LOCALFOLDER"] +profile = "black" +combine_as_imports = true +force_grid_wrap = 2 +force_sort_within_sections = true +skip_glob = ["env"] +skip = "pandas/__init__.py" diff --git a/setup.cfg b/setup.cfg index dca65be27ab77..62ff0c6934f77 100644 --- a/setup.cfg +++ b/setup.cfg @@ -190,18 +190,3 @@ exclude_lines = [coverage:html] directory = coverage_html_report - -# To be kept consistent with "Import Formatting" section in contributing.rst -[isort] -known_pre_libs = pandas._config -known_pre_core = pandas._libs,pandas._typing,pandas.util._*,pandas.compat,pandas.errors -known_dtypes = pandas.core.dtypes -known_post_core = pandas.tseries,pandas.io,pandas.plotting -sections = FUTURE,STDLIB,THIRDPARTY,PRE_LIBS,PRE_CORE,DTYPES,FIRSTPARTY,POST_CORE,LOCALFOLDER -profile = black -combine_as_imports = True -line_length = 88 -force_grid_wrap = True -force_sort_within_sections = True -skip_glob = env, -skip = pandas/__init__.py From 858c188e97219bc6033643ca8d0113b4e1957b29 Mon Sep 17 00:00:00 2001 From: Fangchen Li Date: Tue, 20 Jul 2021 15:43:01 -0500 Subject: [PATCH 2/2] clean --- pyproject.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 92aecb2ac7b07..bb9b0e5517872 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -105,14 +105,14 @@ ignore_errors = true # To be kept consistent with "Import Formatting" section in contributing.rst [tool.isort] -known_pre_libs = ["pandas._config"] +known_pre_libs = "pandas._config" known_pre_core = ["pandas._libs", "pandas._typing", "pandas.util._*", "pandas.compat", "pandas.errors"] -known_dtypes = ["pandas.core.dtypes"] +known_dtypes = "pandas.core.dtypes" known_post_core = ["pandas.tseries", "pandas.io", "pandas.plotting"] sections = ["FUTURE", "STDLIB", "THIRDPARTY" ,"PRE_LIBS" , "PRE_CORE", "DTYPES", "FIRSTPARTY", "POST_CORE", "LOCALFOLDER"] profile = "black" combine_as_imports = true force_grid_wrap = 2 force_sort_within_sections = true -skip_glob = ["env"] +skip_glob = "env" skip = "pandas/__init__.py"