Skip to content

Commit 6a1cc2b

Browse files
Merge remote-tracking branch 'upstream/master' into arrow-string-array-dtype
2 parents 56714c9 + b1e62a1 commit 6a1cc2b

Some content is hidden

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

57 files changed

+582
-607
lines changed

.travis.yml

Lines changed: 0 additions & 72 deletions
This file was deleted.

ci/check_git_tags.sh

Lines changed: 0 additions & 28 deletions
This file was deleted.
File renamed without changes.

ci/prep_cython_cache.sh

Lines changed: 0 additions & 74 deletions
This file was deleted.

ci/setup_env.sh

Lines changed: 12 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -12,41 +12,30 @@ if [[ "$(uname)" == "Linux" && -n "$LC_ALL" ]]; then
1212
echo
1313
fi
1414

15-
MINICONDA_DIR="$HOME/miniconda3"
16-
17-
18-
if [ -d "$MINICONDA_DIR" ]; then
19-
echo
20-
echo "rm -rf "$MINICONDA_DIR""
21-
rm -rf "$MINICONDA_DIR"
22-
fi
2315

2416
echo "Install Miniconda"
25-
UNAME_OS=$(uname)
26-
if [[ "$UNAME_OS" == 'Linux' ]]; then
17+
DEFAULT_CONDA_URL="https://repo.continuum.io/miniconda/Miniconda3-latest"
18+
if [[ "$(uname -m)" == 'aarch64' ]]; then
19+
CONDA_URL="https://github.com/conda-forge/miniforge/releases/download/4.10.1-4/Miniforge3-4.10.1-4-Linux-aarch64.sh"
20+
elif [[ "$(uname)" == 'Linux' ]]; then
2721
if [[ "$BITS32" == "yes" ]]; then
28-
CONDA_OS="Linux-x86"
22+
CONDA_URL="$DEFAULT_CONDA_URL-Linux-x86.sh"
2923
else
30-
CONDA_OS="Linux-x86_64"
24+
CONDA_URL="$DEFAULT_CONDA_URL-Linux-x86_64.sh"
3125
fi
32-
elif [[ "$UNAME_OS" == 'Darwin' ]]; then
33-
CONDA_OS="MacOSX-x86_64"
26+
elif [[ "$(uname)" == 'Darwin' ]]; then
27+
CONDA_URL="$DEFAULT_CONDA_URL-MacOSX-x86_64.sh"
3428
else
35-
echo "OS $UNAME_OS not supported"
29+
echo "OS $(uname) not supported"
3630
exit 1
3731
fi
38-
39-
if [ "${TRAVIS_CPU_ARCH}" == "arm64" ]; then
40-
CONDA_URL="https://github.com/conda-forge/miniforge/releases/download/4.8.5-1/Miniforge3-4.8.5-1-Linux-aarch64.sh"
41-
else
42-
CONDA_URL="https://repo.continuum.io/miniconda/Miniconda3-latest-$CONDA_OS.sh"
43-
fi
32+
echo "Downloading $CONDA_URL"
4433
wget -q $CONDA_URL -O miniconda.sh
4534
chmod +x miniconda.sh
4635

47-
# Installation path is required for ARM64 platform as miniforge script installs in path $HOME/miniforge3.
36+
MINICONDA_DIR="$HOME/miniconda3"
37+
rm -rf $MINICONDA_DIR
4838
./miniconda.sh -b -p $MINICONDA_DIR
49-
5039
export PATH=$MINICONDA_DIR/bin:$PATH
5140

5241
echo
@@ -63,29 +52,6 @@ conda update -n base conda
6352
echo "conda info -a"
6453
conda info -a
6554

66-
echo
67-
echo "set the compiler cache to work"
68-
if [ -z "$NOCACHE" ] && [ "${TRAVIS_OS_NAME}" == "linux" ]; then
69-
echo "Using ccache"
70-
export PATH=/usr/lib/ccache:/usr/lib64/ccache:$PATH
71-
GCC=$(which gcc)
72-
echo "gcc: $GCC"
73-
CCACHE=$(which ccache)
74-
echo "ccache: $CCACHE"
75-
export CC='ccache gcc'
76-
elif [ -z "$NOCACHE" ] && [ "${TRAVIS_OS_NAME}" == "osx" ]; then
77-
echo "Install ccache"
78-
brew install ccache > /dev/null 2>&1
79-
echo "Using ccache"
80-
export PATH=/usr/local/opt/ccache/libexec:$PATH
81-
gcc=$(which gcc)
82-
echo "gcc: $gcc"
83-
CCACHE=$(which ccache)
84-
echo "ccache: $CCACHE"
85-
else
86-
echo "Not using ccache"
87-
fi
88-
8955
echo "source deactivate"
9056
source deactivate
9157

ci/submit_cython_cache.sh

Lines changed: 0 additions & 29 deletions
This file was deleted.

doc/source/whatsnew/v1.2.5.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,9 @@ including other versions of pandas.
1515
Fixed regressions
1616
~~~~~~~~~~~~~~~~~
1717
- Regression in :func:`concat` between two :class:`DataFrames` where one has an :class:`Index` that is all-None and the other is :class:`DatetimeIndex` incorrectly raising (:issue:`40841`)
18+
- Fixed regression in :meth:`DataFrame.sum` and :meth:`DataFrame.prod` when ``min_count`` and ``numeric_only`` are both given (:issue:`41074`)
1819
- Regression in :func:`read_csv` when using ``memory_map=True`` with an non-UTF8 encoding (:issue:`40986`)
19-
-
20+
- Regression in :meth:`DataFrame.replace` and :meth:`Series.replace` when the values to replace is a NumPy float array (:issue:`40371`)
2021

2122
.. ---------------------------------------------------------------------------
2223

doc/source/whatsnew/v1.3.0.rst

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,7 @@ Other enhancements
341341
- Add keyword ``sort`` to :func:`pivot_table` to allow non-sorting of the result (:issue:`39143`)
342342
- Add keyword ``dropna`` to :meth:`DataFrame.value_counts` to allow counting rows that include ``NA`` values (:issue:`41325`)
343343
- :meth:`Series.replace` will now cast results to ``PeriodDtype`` where possible instead of ``object`` dtype (:issue:`41526`)
344-
- Improved error message in ``corr` and ``cov`` methods on :class:`.Rolling`, :class:`.Expanding`, and :class:`.ExponentialMovingWindow` when ``other`` is not a :class:`DataFrame` or :class:`Series` (:issue:`41741`)
344+
- Improved error message in ``corr`` and ``cov`` methods on :class:`.Rolling`, :class:`.Expanding`, and :class:`.ExponentialMovingWindow` when ``other`` is not a :class:`DataFrame` or :class:`Series` (:issue:`41741`)
345345

346346
.. ---------------------------------------------------------------------------
347347
@@ -751,6 +751,7 @@ Other API changes
751751
- Partially initialized :class:`CategoricalDtype` (i.e. those with ``categories=None`` objects will no longer compare as equal to fully initialized dtype objects.
752752
- Accessing ``_constructor_expanddim`` on a :class:`DataFrame` and ``_constructor_sliced`` on a :class:`Series` now raise an ``AttributeError``. Previously a ``NotImplementedError`` was raised (:issue:`38782`)
753753
- Added new ``engine`` and ``**engine_kwargs`` parameters to :meth:`DataFrame.to_sql` to support other future "SQL engines". Currently we still only use ``SQLAlchemy`` under the hood, but more engines are planned to be supported such as ``turbodbc`` (:issue:`36893`)
754+
- Removed redundant ``freq`` from :class:`PeriodIndex` string representation (:issue:`41653`)
754755

755756
Build
756757
=====
@@ -794,6 +795,7 @@ Deprecations
794795
- Deprecated passing arguments (apart from ``cond`` and ``other``) as positional in :meth:`DataFrame.mask` and :meth:`Series.mask` (:issue:`41485`)
795796
- Deprecated passing arguments as positional in :meth:`DataFrame.clip` and :meth:`Series.clip` (other than ``"upper"`` and ``"lower"``) (:issue:`41485`)
796797
- Deprecated special treatment of lists with first element a Categorical in the :class:`DataFrame` constructor; pass as ``pd.DataFrame({col: categorical, ...})`` instead (:issue:`38845`)
798+
- Deprecated behavior of :class:`DataFrame` constructor when a ``dtype`` is passed and the data cannot be cast to that dtype. In a future version, this will raise instead of being silently ignored (:issue:`24435`)
797799
- Deprecated passing arguments as positional (except for ``"method"``) in :meth:`DataFrame.interpolate` and :meth:`Series.interpolate` (:issue:`41485`)
798800
- Deprecated passing arguments as positional in :meth:`DataFrame.ffill`, :meth:`Series.ffill`, :meth:`DataFrame.bfill`, and :meth:`Series.bfill` (:issue:`41485`)
799801
- Deprecated passing arguments as positional in :meth:`DataFrame.sort_values` (other than ``"by"``) and :meth:`Series.sort_values` (:issue:`41485`)
@@ -805,6 +807,8 @@ Deprecations
805807
- Deprecated passing arguments (apart from ``value``) as positional in :meth:`DataFrame.fillna` and :meth:`Series.fillna` (:issue:`41485`)
806808
- Deprecated passing arguments as positional in :meth:`DataFrame.reset_index` (other than ``"level"``) and :meth:`Series.reset_index` (:issue:`41485`)
807809
- Deprecated construction of :class:`Series` or :class:`DataFrame` with ``DatetimeTZDtype`` data and ``datetime64[ns]`` dtype. Use ``Series(data).dt.tz_localize(None)`` instead (:issue:`41555`,:issue:`33401`)
810+
- Deprecated behavior of :class:`Series` construction with large-integer values and small-integer dtype silently overflowing; use ``Series(data).astype(dtype)`` instead (:issue:`41734`)
811+
- Deprecated inference of ``timedelta64[ns]``, ``datetime64[ns]``, or ``DatetimeTZDtype`` dtypes in :class:`Series` construction when data containing strings is passed and no ``dtype`` is passed (:issue:`33558`)
808812
- In a future version, constructing :class:`Series` or :class:`DataFrame` with ``datetime64[ns]`` data and ``DatetimeTZDtype`` will treat the data as wall-times instead of as UTC times (matching DatetimeIndex behavior). To treat the data as UTC times, use ``pd.Series(data).dt.tz_localize("UTC").dt.tz_convert(dtype.tz)`` or ``pd.Series(data.view("int64"), dtype=dtype)`` (:issue:`33401`)
809813
- Deprecated passing arguments as positional in :meth:`DataFrame.set_axis` and :meth:`Series.set_axis` (other than ``"labels"``) (:issue:`41485`)
810814
- Deprecated passing arguments as positional in :meth:`DataFrame.where` and :meth:`Series.where` (other than ``"cond"`` and ``"other"``) (:issue:`41485`)
@@ -1067,6 +1071,7 @@ MultiIndex
10671071
- Bug in :meth:`MultiIndex.equals` incorrectly returning ``True`` when :class:`MultiIndex` containing ``NaN`` even when they are differently ordered (:issue:`38439`)
10681072
- Bug in :meth:`MultiIndex.intersection` always returning empty when intersecting with :class:`CategoricalIndex` (:issue:`38653`)
10691073
- Bug in :meth:`MultiIndex.reindex` raising ``ValueError`` with empty MultiIndex and indexing only a specific level (:issue:`41170`)
1074+
- Bug in :meth:`MultiIndex.reindex` raising ``TypeError`` when reindexing against a flat :class:`Index` (:issue:`41707`)
10701075

10711076
I/O
10721077
^^^
@@ -1181,6 +1186,7 @@ Reshaping
11811186
- Bug in :meth:`DataFrame.sort_values` not reshaping index correctly after sorting on columns, when ``ignore_index=True`` (:issue:`39464`)
11821187
- Bug in :meth:`DataFrame.append` returning incorrect dtypes with combinations of ``ExtensionDtype`` dtypes (:issue:`39454`)
11831188
- Bug in :meth:`DataFrame.append` returning incorrect dtypes with combinations of ``datetime64`` and ``timedelta64`` dtypes (:issue:`39574`)
1189+
- Bug in :meth:`DataFrame.append` with a :class:`DataFrame` with a :class:`MultiIndex` and appending a :class:`Series` whose :class:`Index` is not a :class:`MultiIndex` (:issue:`41707`)
11841190
- Bug in :meth:`DataFrame.pivot_table` returning a ``MultiIndex`` for a single value when operating on and empty ``DataFrame`` (:issue:`13483`)
11851191
- Allow :class:`Index` to be passed to the :func:`numpy.all` function (:issue:`40180`)
11861192
- Bug in :meth:`DataFrame.stack` not preserving ``CategoricalDtype`` in a ``MultiIndex`` (:issue:`36991`)
@@ -1235,6 +1241,7 @@ Other
12351241
- Bug in :meth:`DataFrame.clip` not interpreting missing values as no threshold (:issue:`40420`)
12361242
- Bug in :class:`Series` backed by :class:`DatetimeArray` or :class:`TimedeltaArray` sometimes failing to set the array's ``freq`` to ``None`` (:issue:`41425`)
12371243
- Bug in creating a :class:`Series` from a ``range`` object that does not fit in the bounds of ``int64`` dtype (:issue:`30173`)
1244+
- Bug in creating a :class:`Series` from a ``dict`` with all-tuple keys and an :class:`Index` that requires reindexing (:issue:`41707`)
12381245

12391246
.. ---------------------------------------------------------------------------
12401247

pandas/_libs/lib.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ def ensure_string_array(
153153

154154
def infer_datetimelike_array(
155155
arr: np.ndarray # np.ndarray[object]
156-
) -> str: ...
156+
) -> tuple[str, bool]: ...
157157

158158
def astype_intsafe(
159159
arr: np.ndarray, # np.ndarray[object]

0 commit comments

Comments
 (0)