Skip to content

Conversation

@tegardp
Copy link
Contributor

@tegardp tegardp commented May 29, 2021

@pep8speaks
Copy link

pep8speaks commented May 29, 2021

Hello @tegardp! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2021-06-06 11:25:15 UTC

Copy link
Member

@MarcoGorelli MarcoGorelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally looks good, thanks! Can you drop the commits from the read_table PR here?

@jreback jreback added Deprecate Functionality to remove in pandas Reshaping Concat, Merge/Join, Stack/Unstack, Explode labels May 31, 2021
@jreback jreback added this to the 1.3 milestone May 31, 2021
@jreback
Copy link
Contributor

jreback commented May 31, 2021

can you rebase; this appears to have a read_table change (already merged) so need to remove that

@simonjayhawkins simonjayhawkins changed the title Deprecate nonkeyword args concat DEPR: Deprecated passing arguments as positional in pd.concat Jun 2, 2021
def test_concat_posargs_deprecation(all_parsers):
# https://github.com/pandas-dev/pandas/issues/41485
df = pd.DataFrame([[1, 2, 3]], index=["a"])
df2 = pd.DataFrame([[4, 5, 6]], index=["b"])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pandas/tests/reshape/concat/test_concat.py:645:10: PDF019 found both 'pd.DataFrame' and 'DataFrame' in the same file
pandas/tests/reshape/concat/test_concat.py:646:11: PDF019 found both 'pd.DataFrame' and 'DataFrame' in the same file

@jreback
Copy link
Contributor

jreback commented Jun 3, 2021

@tegardp if you can update

@tegardp
Copy link
Contributor Author

tegardp commented Jun 3, 2021

@tegardp if you can update

sorry i'm still confused about rebase workflow

@simonjayhawkins
Copy link
Member

@tegardp if you can update

sorry i'm still confused about rebase workflow

that is now sorted in d9b3712,

comments #41718 (comment) and #41718 (comment) to be addressed. will fix test and lint failures on ci

@MarcoGorelli MarcoGorelli self-requested a review June 4, 2021 09:53
@simonjayhawkins
Copy link
Member

comments #41718 (comment) and #41718 (comment) to be addressed. will fix test and lint failures on ci

tests are still failing... see #41718 (comment)

Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great ping on green

@jreback
Copy link
Contributor

jreback commented Jun 4, 2021

you need to change any existing test which uses positional args to avoid the warnings.

@jreback
Copy link
Contributor

jreback commented Jun 4, 2021

"except for the argument 'objs' will be keyword-only"
)
warning_ctx = tm.assert_produces_warning(FutureWarning, match=warn_msg)
with pytest.raises(TypeError, match=err_msg), warning_ctx:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when we deprecate, python will raise TypeError: concat() takes 1 positional argument but 2 were given before the function validates the first argument.

maybe concat(df1, df2) -> concat(df1)

Copy link
Member

@simonjayhawkins simonjayhawkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @tegardp and @MarcoGorelli lgtm

ci failures are codecov failed uploads.

@simonjayhawkins simonjayhawkins mentioned this pull request Jun 7, 2021
@jreback jreback merged commit a2c65df into pandas-dev:master Jun 7, 2021
@jreback
Copy link
Contributor

jreback commented Jun 7, 2021

thanks @tegardp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Deprecate Functionality to remove in pandas Reshaping Concat, Merge/Join, Stack/Unstack, Explode

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants