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

CLN: move top-level dirs #15998

Closed
wants to merge 11 commits into from
Closed

CLN: move top-level dirs #15998

wants to merge 11 commits into from

Conversation

jreback
Copy link
Contributor

@jreback jreback commented Apr 14, 2017

xref #13634

  • from pandas.types.concat import union_categoricals ?

  • pandas.types -> pandas.core.typed

  • pandas.computation -> pandas.core.computation

  • pandas.sparse -> pandas.core.sparse

@jreback jreback added the Clean label Apr 14, 2017
@jreback jreback added this to the 0.20.0 milestone Apr 14, 2017
@jreback
Copy link
Contributor Author

jreback commented Apr 14, 2017

this was probably the one with the most actual code changes.

Extension Modules Moved
^^^^^^^^^^^^^^^^^^^^^^^
Modules Privacy Has Changed
^^^^^^^^^^^^^^^^^^^^^^^^^^^

Copy link
Contributor Author

Choose a reason for hiding this comment

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

we can make this more prominent later.

@jreback jreback changed the title CLN: move pandas.types -> pandas.core.types CLN: move pandas.types -> pandas.core.typed Apr 14, 2017
@jreback jreback changed the title CLN: move pandas.types -> pandas.core.typed CLN: move top-level dirs Apr 14, 2017
@jreback
Copy link
Contributor Author

jreback commented Apr 14, 2017

from pandas.types.concat import union_categoricals
we need to change this.

from pandas.api import union_categoricals?

also should change infer_dtype to come from pandas.api as well? (xref #15936) (I will do as a followup I think).

@jreback
Copy link
Contributor Author

jreback commented Apr 14, 2017

cc @chris-b1 @jorisvandenbossche

@chris-b1
Copy link
Contributor

I suppose union_categoricals and infer_dtype should go in pandas.api.types?

@jreback
Copy link
Contributor Author

jreback commented Apr 14, 2017

yep I think that's right place.

@jorisvandenbossche
Copy link
Member

Is there a reason you use core.typed instead of core.types ?

@jreback
Copy link
Contributor Author

jreback commented Apr 15, 2017

Is there a reason you use core.typed instead of core.types ?

yes, unfortunately in python 2 if you do import types and you are in the pandas.core directly you get pandas.core.types, rather than the built in module (it get shadowed). This is a bit annoying because it does work in python 3 :<

we use this in pandas.core.series. I can get around this, but simpler to just rename.

@jorisvandenbossche
Copy link
Member

Ah, just saw you commit message that mentioned it as well.
I might prefer 'dtypes' over 'typed', but not that important

@codecov
Copy link

codecov bot commented Apr 15, 2017

Codecov Report

Merging #15998 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #15998      +/-   ##
==========================================
+ Coverage   91.02%   91.02%   +<.01%     
==========================================
  Files         145      145              
  Lines       50391    50395       +4     
==========================================
+ Hits        45870    45874       +4     
  Misses       4521     4521
Flag Coverage Δ
#multiple 88.79% <100%> (-0.04%) ⬇️
#single 40.41% <94.2%> (+0.08%) ⬆️
Impacted Files Coverage Δ
pandas/core/typed/common.py 93.27% <ø> (ø)
pandas/core/computation/common.py 85.71% <ø> (ø)
pandas/core/typed/generic.py 100% <ø> (ø)
pandas/core/computation/__init__.py 90.9% <ø> (ø)
pandas/core/typed/inference.py 98.33% <ø> (ø)
pandas/core/typed/api.py 100% <ø> (ø)
pandas/core/typed/missing.py 86.87% <ø> (ø)
pandas/core/typed/cast.py 86.89% <ø> (ø)
pandas/indexes/multi.py 96.7% <100%> (ø) ⬆️
pandas/tseries/util.py 100% <100%> (ø) ⬆️
... and 78 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 85a9f8c...a85e487. Read the comment docs.

@codecov
Copy link

codecov bot commented Apr 15, 2017

Codecov Report

Merging #15998 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #15998      +/-   ##
==========================================
+ Coverage   91.02%   91.02%   +<.01%     
==========================================
  Files         145      145              
  Lines       50391    50395       +4     
==========================================
+ Hits        45870    45874       +4     
  Misses       4521     4521
Flag Coverage Δ
#multiple 88.79% <100%> (-0.04%) ⬇️
#single 40.41% <94.2%> (+0.08%) ⬆️
Impacted Files Coverage Δ
pandas/core/typed/generic.py 100% <ø> (ø)
pandas/core/typed/cast.py 86.89% <ø> (ø)
pandas/core/typed/common.py 93.27% <ø> (ø)
pandas/core/computation/common.py 85.71% <ø> (ø)
pandas/core/computation/__init__.py 90.9% <ø> (ø)
pandas/core/typed/inference.py 98.33% <ø> (ø)
pandas/core/typed/missing.py 86.87% <ø> (ø)
pandas/core/typed/api.py 100% <ø> (ø)
pandas/indexes/base.py 96.19% <100%> (ø) ⬆️
pandas/core/window.py 96.24% <100%> (ø) ⬆️
... and 78 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 85a9f8c...a85e487. Read the comment docs.

@codecov
Copy link

codecov bot commented Apr 15, 2017

Codecov Report

Merging #15998 into master will decrease coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #15998      +/-   ##
==========================================
- Coverage   90.99%   90.99%   -0.01%     
==========================================
  Files         154      153       -1     
  Lines       50474    50481       +7     
==========================================
+ Hits        45931    45937       +6     
- Misses       4543     4544       +1
Flag Coverage Δ
#multiple 88.76% <100%> (-0.05%) ⬇️
#single 40.44% <91.05%> (+0.08%) ⬆️
Impacted Files Coverage Δ
pandas/core/dtypes/missing.py 86.87% <ø> (ø)
pandas/core/dtypes/generic.py 100% <ø> (ø)
pandas/core/dtypes/cast.py 86.89% <ø> (ø)
pandas/core/computation/common.py 85.71% <ø> (ø)
pandas/core/dtypes/common.py 93.27% <ø> (ø)
pandas/compat/pickle_compat.py 69.51% <ø> (ø) ⬆️
pandas/core/dtypes/api.py 100% <ø> (ø)
pandas/core/dtypes/inference.py 98.33% <ø> (ø)
pandas/core/sparse/scipy_sparse.py 96.96% <ø> (ø)
pandas/core/computation/__init__.py 90.9% <ø> (ø)
... and 87 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7993fc8...5fe80ae. Read the comment docs.

@jreback
Copy link
Contributor Author

jreback commented Apr 15, 2017

renamed typed -> dtypes, so a bit more natural now

pandas.core.dtypes

@jreback jreback force-pushed the move_types branch 2 times, most recently from b121a57 to c630297 Compare April 15, 2017 19:14
@jreback
Copy link
Contributor Author

jreback commented Apr 15, 2017

finally got this bad boy working. apparently pytestdoesn't like nested conftest.py (of course only when you are running using pytest.main(); it works just fine for development.

@jreback jreback closed this in 005a09e Apr 15, 2017
@jorisvandenbossche
Copy link
Member

Great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants