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

BUG: Fix issue in preserving index name on empty DataFrame #36532

Merged
merged 2 commits into from
Sep 21, 2020

Conversation

Dr-Irv
Copy link
Contributor

@Dr-Irv Dr-Irv commented Sep 21, 2020

@pep8speaks
Copy link

pep8speaks commented Sep 21, 2020

Hello @Dr-Irv! 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 2020-09-21 20:17:46 UTC

@WillAyd WillAyd added the Regression Functionality that used to work in a prior pandas version label Sep 21, 2020
@WillAyd WillAyd added this to the 1.1.3 milestone Sep 21, 2020
@WillAyd WillAyd added Index Related to the Index class or subclasses Indexing Related to indexing on series/frames, not to indexes themselves and removed Index Related to the Index class or subclasses labels Sep 21, 2020
Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

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

@jreback jreback merged commit f59700b into pandas-dev:master Sep 21, 2020
@jreback
Copy link
Contributor

jreback commented Sep 21, 2020

thanks @Dr-Irv

@jorisvandenbossche
Copy link
Member

@meeseeksdev backport to 1.1.x

df["series"] = series
expected = pd.DataFrame(
{"series": [1.23] * 4}, index=pd.RangeIndex(4, name="series_index")
)
Copy link
Member

Choose a reason for hiding this comment

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

I think you forgor the assert here ;)

(thanks for the PR for the rest!)

Copy link
Member

Choose a reason for hiding this comment

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

-> #36546

meeseeksmachine pushed a commit to meeseeksmachine/pandas that referenced this pull request Sep 22, 2020
jorisvandenbossche pushed a commit that referenced this pull request Sep 22, 2020
…DataFrame (#36545)

Co-authored-by: Irv Lustig <irv@princeton.com>
kesmit13 pushed a commit to kesmit13/pandas that referenced this pull request Nov 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Indexing Related to indexing on series/frames, not to indexes themselves Regression Functionality that used to work in a prior pandas version
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: Different behaviour for index after assign dataframe new column by series
5 participants