Skip to content

Commit 1e3df80

Browse files
committed
Merge branch 'master' into parquet-categorical
* master: (40 commits) DOC: Fix GL01 and GL02 errors in the docstrings (pandas-dev#27988) Remove Encoding of values in char** For Labels (pandas-dev#27618) TYPING: more type hints for io.formats.printing (pandas-dev#27765) TST: fix compression tests when run without virtualenv/condaenv (pandas-dev#28051) DOC: Start 0.25.2 (pandas-dev#28111) DOC: Fix docstrings lack of punctuation (pandas-dev#28031) DOC: Remove alias for numpy.random.randn from the docs (pandas-dev#28082) DOC: update GroupBy.head()/tail() documentation (pandas-dev#27844) BUG: timedelta merge asof with tolerance (pandas-dev#27650) BUG: Series.rename raises error on values accepted by Series construc… (pandas-dev#27814) Preserve index when setting new column on empty dataframe. (pandas-dev#26471) BUG: Fixed groupby quantile for listlike q (pandas-dev#27827) BUG: iter with readonly values, closes pandas-dev#28055 (pandas-dev#28074) TST: non-strict xfail for period test (pandas-dev#28072) DOC: Update whatsnew (pandas-dev#28073) CI: disable codecov (pandas-dev#28065) CI: Set SHA for codecov upload (pandas-dev#28067) BUG: Correct the previous bug fixing on xlim for plotting (pandas-dev#28059) CI: Add pip dependence explicitly (pandas-dev#28008) DOC: Change document code prun in a row (pandas-dev#28029) ...
2 parents aebfae7 + 5c0da7d commit 1e3df80

Some content is hidden

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

70 files changed

+1128
-466
lines changed

ci/deps/azure-macos-35.yaml

+1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ dependencies:
2222
- xlrd
2323
- xlsxwriter
2424
- xlwt
25+
- pip
2526
- pip:
2627
- pyreadstat
2728
# universal

ci/run_tests.sh

+6-5
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@ do
5050
# if no tests are found (the case of "single and slow"), pytest exits with code 5, and would make the script fail, if not for the below code
5151
sh -c "$PYTEST_CMD; ret=\$?; [ \$ret = 5 ] && exit 0 || exit \$ret"
5252

53-
if [[ "$COVERAGE" && $? == 0 ]]; then
54-
echo "uploading coverage for $TYPE tests"
55-
echo "bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME"
56-
bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME
57-
fi
53+
# 2019-08-21 disabling because this is hitting HTTP 400 errors GH#27602
54+
# if [[ "$COVERAGE" && $? == 0 && "$TRAVIS_BRANCH" == "master" ]]; then
55+
# echo "uploading coverage for $TYPE tests"
56+
# echo "bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME"
57+
# bash <(curl -s https://codecov.io/bash) -Z -c -F $TYPE -f $COVERAGE_FNAME
58+
# fi
5859
done

doc/source/conf.py

-1
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,6 @@
315315
import numpy as np
316316
import pandas as pd
317317
318-
randn = np.random.randn
319318
np.random.seed(123456)
320319
np.set_printoptions(precision=4, suppress=True)
321320
pd.options.display.max_rows = 15

doc/source/user_guide/enhancingperf.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -243,9 +243,9 @@ We've gotten another big improvement. Let's check again where the time is spent:
243243

244244
.. ipython:: python
245245
246-
%prun -l 4 apply_integrate_f(df['a'].to_numpy(),
247-
df['b'].to_numpy(),
248-
df['N'].to_numpy())
246+
%%prun -l 4 apply_integrate_f(df['a'].to_numpy(),
247+
df['b'].to_numpy(),
248+
df['N'].to_numpy())
249249
250250
As one might expect, the majority of the time is now spent in ``apply_integrate_f``,
251251
so if we wanted to make anymore efficiencies we must continue to concentrate our

doc/source/user_guide/io.rst

+2
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ The pandas I/O API is a set of top level ``reader`` functions accessed like
2828
:delim: ;
2929

3030
text;`CSV <https://en.wikipedia.org/wiki/Comma-separated_values>`__;:ref:`read_csv<io.read_csv_table>`;:ref:`to_csv<io.store_in_csv>`
31+
text;Fixed-Width Text File;:ref:`read_fwf<io.fwf_reader>`
3132
text;`JSON <https://www.json.org/>`__;:ref:`read_json<io.json_reader>`;:ref:`to_json<io.json_writer>`
3233
text;`HTML <https://en.wikipedia.org/wiki/HTML>`__;:ref:`read_html<io.read_html>`;:ref:`to_html<io.html>`
3334
text; Local clipboard;:ref:`read_clipboard<io.clipboard>`;:ref:`to_clipboard<io.clipboard>`
@@ -1372,6 +1373,7 @@ should pass the ``escapechar`` option:
13721373
print(data)
13731374
pd.read_csv(StringIO(data), escapechar='\\')
13741375
1376+
.. _io.fwf_reader:
13751377
.. _io.fwf:
13761378

13771379
Files with fixed width columns

doc/source/whatsnew/index.rst

+1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ Version 0.25
2424
.. toctree::
2525
:maxdepth: 2
2626

27+
v0.25.2
2728
v0.25.1
2829
v0.25.0
2930

doc/source/whatsnew/v0.10.0.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,7 @@ Here is a taste of what to expect.
498498

499499
.. code-block:: ipython
500500
501-
In [58]: p4d = Panel4D(randn(2, 2, 5, 4),
501+
In [58]: p4d = Panel4D(np.random.randn(2, 2, 5, 4),
502502
....: labels=['Label1','Label2'],
503503
....: items=['Item1', 'Item2'],
504504
....: major_axis=date_range('1/1/2000', periods=5),

doc/source/whatsnew/v0.25.1.rst

+30-78
Original file line numberDiff line numberDiff line change
@@ -1,163 +1,115 @@
11
.. _whatsnew_0251:
22

3-
What's new in 0.25.1 (July XX, 2019)
4-
------------------------------------
5-
6-
Enhancements
7-
~~~~~~~~~~~~
3+
What's new in 0.25.1 (August 21, 2019)
4+
--------------------------------------
85

6+
These are the changes in pandas 0.25.1. See :ref:`release` for a full changelog
7+
including other versions of pandas.
98

10-
.. _whatsnew_0251.enhancements.other:
11-
12-
Other enhancements
13-
^^^^^^^^^^^^^^^^^^
9+
I/O and LZMA
10+
~~~~~~~~~~~~
1411

15-
-
16-
-
17-
-
12+
Some users may unknowingly have an incomplete Python installation lacking the `lzma` module from the standard library. In this case, `import pandas` failed due to an `ImportError` (:issue: `27575`).
13+
Pandas will now warn, rather than raising an `ImportError` if the `lzma` module is not present. Any subsequent attempt to use `lzma` methods will raise a `RuntimeError`.
14+
A possible fix for the lack of the `lzma` module is to ensure you have the necessary libraries and then re-install Python.
15+
For example, on MacOS installing Python with `pyenv` may lead to an incomplete Python installation due to unmet system dependencies at compilation time (like `xz`). Compilation will succeed, but Python might fail at run time. The issue can be solved by installing the necessary dependencies and then re-installing Python.
1816

1917
.. _whatsnew_0251.bug_fixes:
2018

2119
Bug fixes
2220
~~~~~~~~~
2321

24-
2522
Categorical
2623
^^^^^^^^^^^
2724

28-
- Bug in :meth:`Categorical.fillna` would replace all values, not just those that are ``NaN`` (:issue:`26215`)
29-
-
25+
- Bug in :meth:`Categorical.fillna` that would replace all values, not just those that are ``NaN`` (:issue:`26215`)
3026

3127
Datetimelike
3228
^^^^^^^^^^^^
33-
- Bug in :func:`to_datetime` where passing a timezone-naive :class:`DatetimeArray` or :class:`DatetimeIndex` and ``utc=True`` would incorrectly return a timezone-naive result (:issue:`27733`)
34-
-
35-
-
36-
-
3729

38-
Timedelta
39-
^^^^^^^^^
40-
41-
-
42-
-
43-
-
30+
- Bug in :func:`to_datetime` where passing a timezone-naive :class:`DatetimeArray` or :class:`DatetimeIndex` and ``utc=True`` would incorrectly return a timezone-naive result (:issue:`27733`)
31+
- Bug in :meth:`Period.to_timestamp` where a :class:`Period` outside the :class:`Timestamp` implementation bounds (roughly 1677-09-21 to 2262-04-11) would return an incorrect :class:`Timestamp` instead of raising ``OutOfBoundsDatetime`` (:issue:`19643`)
32+
- Bug in iterating over :class:`DatetimeIndex` when the underlying data is read-only (:issue:`28055`)
4433

4534
Timezones
4635
^^^^^^^^^
4736

4837
- Bug in :class:`Index` where a numpy object array with a timezone aware :class:`Timestamp` and ``np.nan`` would not return a :class:`DatetimeIndex` (:issue:`27011`)
49-
-
50-
-
5138

5239
Numeric
5340
^^^^^^^
41+
5442
- Bug in :meth:`Series.interpolate` when using a timezone aware :class:`DatetimeIndex` (:issue:`27548`)
5543
- Bug when printing negative floating point complex numbers would raise an ``IndexError`` (:issue:`27484`)
56-
-
57-
-
44+
- Bug where :class:`DataFrame` arithmetic operators such as :meth:`DataFrame.mul` with a :class:`Series` with axis=1 would raise an ``AttributeError`` on :class:`DataFrame` larger than the minimum threshold to invoke numexpr (:issue:`27636`)
45+
- Bug in :class:`DataFrame` arithmetic where missing values in results were incorrectly masked with ``NaN`` instead of ``Inf`` (:issue:`27464`)
5846

5947
Conversion
6048
^^^^^^^^^^
6149

6250
- Improved the warnings for the deprecated methods :meth:`Series.real` and :meth:`Series.imag` (:issue:`27610`)
63-
-
64-
-
65-
66-
Strings
67-
^^^^^^^
68-
69-
-
70-
-
71-
-
72-
7351

7452
Interval
7553
^^^^^^^^
54+
7655
- Bug in :class:`IntervalIndex` where `dir(obj)` would raise ``ValueError`` (:issue:`27571`)
77-
-
78-
-
79-
-
8056

8157
Indexing
8258
^^^^^^^^
8359

8460
- Bug in partial-string indexing returning a NumPy array rather than a ``Series`` when indexing with a scalar like ``.loc['2015']`` (:issue:`27516`)
8561
- Break reference cycle involving :class:`Index` and other index classes to allow garbage collection of index objects without running the GC. (:issue:`27585`, :issue:`27840`)
8662
- Fix regression in assigning values to a single column of a DataFrame with a ``MultiIndex`` columns (:issue:`27841`).
87-
-
63+
- Fix regression in ``.ix`` fallback with an ``IntervalIndex`` (:issue:`27865`).
8864

8965
Missing
9066
^^^^^^^
9167

92-
-
93-
-
94-
-
95-
96-
MultiIndex
97-
^^^^^^^^^^
98-
99-
-
100-
-
101-
-
68+
- Bug in :func:`pandas.isnull` or :func:`pandas.isna` when the input is a type e.g. ``type(pandas.Series())`` (:issue:`27482`)
10269

10370
I/O
10471
^^^
10572

10673
- Avoid calling ``S3File.s3`` when reading parquet, as this was removed in s3fs version 0.3.0 (:issue:`27756`)
10774
- Better error message when a negative header is passed in :func:`pandas.read_csv` (:issue:`27779`)
108-
-
75+
- Follow the ``min_rows`` display option (introduced in v0.25.0) correctly in the HTML repr in the notebook (:issue:`27991`).
10976

11077
Plotting
11178
^^^^^^^^
11279

113-
- Added a pandas_plotting_backends entrypoint group for registering plot backends. See :ref:`extending.plotting-backends` for more (:issue:`26747`).
80+
- Added a ``pandas_plotting_backends`` entrypoint group for registering plot backends. See :ref:`extending.plotting-backends` for more (:issue:`26747`).
81+
- Fixed the re-instatement of Matplotlib datetime converters after calling
82+
:meth:`pandas.plotting.deregister_matplotlib_converters` (:issue:`27481`).
11483
- Fix compatibility issue with matplotlib when passing a pandas ``Index`` to a plot call (:issue:`27775`).
115-
-
11684

11785
Groupby/resample/rolling
11886
^^^^^^^^^^^^^^^^^^^^^^^^
11987

88+
- Fixed regression in :meth:`pands.core.groupby.DataFrameGroupBy.quantile` raising when multiple quantiles are given (:issue:`27526`)
12089
- Bug in :meth:`pandas.core.groupby.DataFrameGroupBy.transform` where applying a timezone conversion lambda function would drop timezone information (:issue:`27496`)
90+
- Bug in :meth:`pandas.core.groupby.GroupBy.nth` where ``observed=False`` was being ignored for Categorical groupers (:issue:`26385`)
12191
- Bug in windowing over read-only arrays (:issue:`27766`)
12292
- Fixed segfault in `pandas.core.groupby.DataFrameGroupBy.quantile` when an invalid quantile was passed (:issue:`27470`)
123-
-
12493

12594
Reshaping
12695
^^^^^^^^^
12796

12897
- A ``KeyError`` is now raised if ``.unstack()`` is called on a :class:`Series` or :class:`DataFrame` with a flat :class:`Index` passing a name which is not the correct one (:issue:`18303`)
98+
- Bug :meth:`merge_asof` could not merge :class:`Timedelta` objects when passing `tolerance` kwarg (:issue:`27642`)
12999
- Bug in :meth:`DataFrame.crosstab` when ``margins`` set to ``True`` and ``normalize`` is not ``False``, an error is raised. (:issue:`27500`)
130100
- :meth:`DataFrame.join` now suppresses the ``FutureWarning`` when the sort parameter is specified (:issue:`21952`)
131101
- Bug in :meth:`DataFrame.join` raising with readonly arrays (:issue:`27943`)
132102

133103
Sparse
134104
^^^^^^
135-
- Bug in reductions for :class:`Series` with Sparse dtypes (:issue:`27080`)
136-
-
137-
-
138-
-
139105

140-
141-
Build Changes
142-
^^^^^^^^^^^^^
143-
144-
-
145-
-
146-
-
147-
148-
ExtensionArray
149-
^^^^^^^^^^^^^^
150-
151-
-
152-
-
153-
-
106+
- Bug in reductions for :class:`Series` with Sparse dtypes (:issue:`27080`)
154107

155108
Other
156109
^^^^^
110+
157111
- Bug in :meth:`Series.replace` and :meth:`DataFrame.replace` when replacing timezone-aware timestamps using a dict-like replacer (:issue:`27720`)
158-
-
159-
-
160-
-
112+
- Bug in :meth:`Series.rename` when using a custom type indexer. Now any value that isn't callable or dict-like is treated as a scalar. (:issue:`27814`)
161113

162114
.. _whatsnew_0.251.contributors:
163115

doc/source/whatsnew/v0.25.2.rst

+110
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
.. _whatsnew_0252:
2+
3+
What's new in 0.25.2 (October XX, 2019)
4+
---------------------------------------
5+
6+
These are the changes in pandas 0.25.2. See :ref:`release` for a full changelog
7+
including other versions of pandas.
8+
9+
.. _whatsnew_0252.bug_fixes:
10+
11+
Bug fixes
12+
~~~~~~~~~
13+
14+
Categorical
15+
^^^^^^^^^^^
16+
17+
-
18+
19+
Datetimelike
20+
^^^^^^^^^^^^
21+
22+
-
23+
-
24+
-
25+
26+
Timezones
27+
^^^^^^^^^
28+
29+
-
30+
31+
Numeric
32+
^^^^^^^
33+
34+
-
35+
-
36+
-
37+
-
38+
39+
Conversion
40+
^^^^^^^^^^
41+
42+
-
43+
44+
Interval
45+
^^^^^^^^
46+
47+
-
48+
49+
Indexing
50+
^^^^^^^^
51+
52+
-
53+
-
54+
-
55+
-
56+
57+
Missing
58+
^^^^^^^
59+
60+
-
61+
62+
I/O
63+
^^^
64+
65+
-
66+
-
67+
-
68+
69+
Plotting
70+
^^^^^^^^
71+
72+
-
73+
-
74+
-
75+
76+
Groupby/resample/rolling
77+
^^^^^^^^^^^^^^^^^^^^^^^^
78+
79+
-
80+
-
81+
-
82+
-
83+
-
84+
85+
Reshaping
86+
^^^^^^^^^
87+
88+
-
89+
-
90+
-
91+
-
92+
-
93+
94+
Sparse
95+
^^^^^^
96+
97+
-
98+
99+
Other
100+
^^^^^
101+
102+
-
103+
-
104+
105+
.. _whatsnew_0.252.contributors:
106+
107+
Contributors
108+
~~~~~~~~~~~~
109+
110+
.. contributors:: v0.25.1..HEAD

0 commit comments

Comments
 (0)