Skip to content

Commit 493b0d2

Browse files
committed
BUG: Attributes are lost when subsetting columns
1 parent d1b1faa commit 493b0d2

File tree

130 files changed

+1049
-513
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

130 files changed

+1049
-513
lines changed

asv_bench/benchmarks/frame_ctor.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
from .pandas_vb_common import tm
77

88
try:
9-
from pandas.tseries.offsets import Nano, Hour
9+
from pandas.tseries.offsets import Hour, Nano
1010
except ImportError:
1111
# For compatibility with older versions
1212
from pandas.core.datetools import * # noqa

asv_bench/benchmarks/gil.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@
77

88
try:
99
from pandas import (
10-
rolling_median,
10+
rolling_kurt,
11+
rolling_max,
1112
rolling_mean,
13+
rolling_median,
1214
rolling_min,
13-
rolling_max,
14-
rolling_var,
1515
rolling_skew,
16-
rolling_kurt,
1716
rolling_std,
17+
rolling_var,
1818
)
1919

2020
have_rolling_methods = True

asv_bench/benchmarks/io/parsers.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
try:
44
from pandas._libs.tslibs.parsing import (
5-
concat_date_cols,
65
_does_string_look_like_datetime,
6+
concat_date_cols,
77
)
88
except ImportError:
99
# Avoid whole benchmark suite import failure on asv (currently 0.4)

asv_bench/benchmarks/tslibs/normalize.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
try:
2-
from pandas._libs.tslibs import normalize_i8_timestamps, is_date_array_normalized
2+
from pandas._libs.tslibs import is_date_array_normalized, normalize_i8_timestamps
33
except ImportError:
44
from pandas._libs.tslibs.conversion import (
55
normalize_i8_timestamps,

ci/code_checks.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ if [[ -z "$CHECK" || "$CHECK" == "lint" ]]; then
121121

122122
# Imports - Check formatting using isort see setup.cfg for settings
123123
MSG='Check import format using isort' ; echo $MSG
124-
ISORT_CMD="isort --quiet --recursive --check-only pandas asv_bench scripts"
124+
ISORT_CMD="isort --quiet --check-only pandas asv_bench scripts"
125125
if [[ "$GITHUB_ACTIONS" == "true" ]]; then
126126
eval $ISORT_CMD | awk '{print "##[error]" $0}'; RET=$(($RET + ${PIPESTATUS[0]}))
127127
else

ci/deps/azure-36-32bit.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ dependencies:
2323
- pip
2424
- pip:
2525
- cython>=0.29.16
26-
- pytest>=5.0.1,<6.0.0rc0
26+
- pytest>=5.0.1

ci/deps/azure-36-locale.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- pytest-asyncio
1313
- hypothesis>=3.58.0

ci/deps/azure-36-locale_slow.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313
- pytest-azurepipelines

ci/deps/azure-36-slow.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313

ci/deps/azure-37-locale.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ dependencies:
66

77
# tools
88
- cython>=0.29.16
9-
- pytest>=5.0.1,<6.0.0rc0
9+
- pytest>=5.0.1
1010
- pytest-xdist>=1.21
1111
- pytest-asyncio
1212
- hypothesis>=3.58.0

ci/deps/azure-37-numpydev.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ dependencies:
55
- python=3.7.*
66

77
# tools
8-
- pytest>=5.0.1,<6.0.0rc0
8+
- pytest>=5.0.1
99
- pytest-xdist>=1.21
1010
- hypothesis>=3.58.0
1111
- pytest-azurepipelines

ci/deps/azure-macos-36.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ dependencies:
55
- python=3.6.*
66

77
# tools
8-
- pytest>=5.0.1,<6.0.0rc0
8+
- pytest>=5.0.1
99
- pytest-xdist>=1.21
1010
- hypothesis>=3.58.0
1111
- pytest-azurepipelines

ci/deps/azure-windows-36.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313
- pytest-azurepipelines

ci/deps/azure-windows-37.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313
- pytest-azurepipelines

ci/deps/travis-36-cov.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313
- pytest-cov # this is only needed in the coverage build

ci/deps/travis-36-locale.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313

ci/deps/travis-37-arm64.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.13
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313

ci/deps/travis-37.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313

ci/deps/travis-38.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies:
77

88
# tools
99
- cython>=0.29.16
10-
- pytest>=5.0.1,<6.0.0rc0
10+
- pytest>=5.0.1
1111
- pytest-xdist>=1.21
1212
- hypothesis>=3.58.0
1313

doc/source/development/contributing.rst

+29-7
Original file line numberDiff line numberDiff line change
@@ -153,14 +153,38 @@ to build the documentation locally before pushing your changes.
153153
Using a Docker container
154154
~~~~~~~~~~~~~~~~~~~~~~~~
155155

156-
Instead of manually setting up a development environment, you can use Docker to
157-
automatically create the environment with just several commands. Pandas provides a `DockerFile`
158-
in the root directory to build a Docker image with a full pandas development environment.
156+
Instead of manually setting up a development environment, you can use `Docker
157+
<https://docs.docker.com/get-docker/>`_ to automatically create the environment with just several
158+
commands. Pandas provides a `DockerFile` in the root directory to build a Docker image
159+
with a full pandas development environment.
159160

160-
Even easier, you can use the DockerFile to launch a remote session with Visual Studio Code,
161+
**Docker Commands**
162+
163+
Pass your GitHub username in the `DockerFile` to use your own fork::
164+
165+
# Build the image pandas-yourname-env
166+
docker build --tag pandas-yourname-env .
167+
# Run a container and bind your local forked repo, pandas-yourname, to the container
168+
docker run -it --rm -v path-to-pandas-yourname:/home/pandas-yourname pandas-yourname-env
169+
170+
Even easier, you can integrate Docker with the following IDEs:
171+
172+
**Visual Studio Code**
173+
174+
You can use the DockerFile to launch a remote session with Visual Studio Code,
161175
a popular free IDE, using the `.devcontainer.json` file.
162176
See https://code.visualstudio.com/docs/remote/containers for details.
163177

178+
**PyCharm (Professional)**
179+
180+
Enable Docker support and use the Services tool window to build and manage images as well as
181+
run and interact with containers.
182+
See https://www.jetbrains.com/help/pycharm/docker.html for details.
183+
184+
Note that you might need to rebuild the C extensions if/when you merge with upstream/master using::
185+
186+
python setup.py build_ext --inplace -j 4
187+
164188
.. _contributing.dev_c:
165189

166190
Installing a C compiler
@@ -751,7 +775,7 @@ Imports are alphabetically sorted within these sections.
751775

752776
As part of :ref:`Continuous Integration <contributing.ci>` checks we run::
753777

754-
isort --recursive --check-only pandas
778+
isort --check-only pandas
755779

756780
to check that imports are correctly formatted as per the `setup.cfg`.
757781

@@ -770,8 +794,6 @@ You should run::
770794

771795
to automatically format imports correctly. This will modify your local copy of the files.
772796

773-
The `--recursive` flag can be passed to sort all files in a directory.
774-
775797
Alternatively, you can run a command similar to what was suggested for ``black`` and ``flake8`` :ref:`right above <contributing.code-formatting>`::
776798

777799
git diff upstream/master --name-only -- "*.py" | xargs -r isort

doc/source/development/policies.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,6 @@ Python support
5252
~~~~~~~~~~~~~~
5353

5454
pandas will only drop support for specific Python versions (e.g. 3.6.x, 3.7.x) in
55-
pandas **major** releases.
55+
pandas **major** or **minor** releases.
5656

5757
.. _SemVer: https://semver.org

doc/source/user_guide/style.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@
141141
"cell_type": "markdown",
142142
"metadata": {},
143143
"source": [
144-
"In this case, the cell's style depends only on it's own value.\n",
144+
"In this case, the cell's style depends only on its own value.\n",
145145
"That means we should use the `Styler.applymap` method which works elementwise."
146146
]
147147
},

doc/source/whatsnew/index.rst

+9
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,21 @@ This is the list of changes to pandas between each release. For full details,
1010
see the `commit logs <https://github.com/pandas-dev/pandas/commits/>`_. For install and
1111
upgrade instructions, see :ref:`install`.
1212

13+
Version 1.2
14+
-----------
15+
16+
.. toctree::
17+
:maxdepth: 2
18+
19+
v1.2.0
20+
1321
Version 1.1
1422
-----------
1523

1624
.. toctree::
1725
:maxdepth: 2
1826

27+
v1.1.1
1928
v1.1.0
2029

2130
Version 1.0

doc/source/whatsnew/v1.1.1.rst

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
.. _whatsnew_111:
2+
3+
What's new in 1.1.1 (?)
4+
-----------------------
5+
6+
These are the changes in pandas 1.1.1. See :ref:`release` for a full changelog
7+
including other versions of pandas.
8+
9+
{{ header }}
10+
11+
.. ---------------------------------------------------------------------------
12+
13+
.. _whatsnew_111.regressions:
14+
15+
Fixed regressions
16+
~~~~~~~~~~~~~~~~~
17+
18+
-
19+
-
20+
-
21+
22+
.. ---------------------------------------------------------------------------
23+
24+
.. _whatsnew_111.bug_fixes:
25+
26+
Bug fixes
27+
~~~~~~~~~
28+
29+
**Datetimelike**
30+
31+
-
32+
-
33+
34+
**Numeric**
35+
36+
-
37+
-
38+
39+
**Plotting**
40+
41+
-
42+
43+
**Indexing**
44+
45+
-
46+
47+
.. ---------------------------------------------------------------------------
48+
49+
.. _whatsnew_111.contributors:
50+
51+
Contributors
52+
~~~~~~~~~~~~
53+
54+
.. contributors:: v1.1.0..v1.1.1|HEAD

0 commit comments

Comments
 (0)