Skip to content

Commit

Permalink
Merge branch 'main' into remove-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lithomas1 authored Mar 26, 2024
2 parents 23952aa + 5703f11 commit 23b9827
Show file tree
Hide file tree
Showing 154 changed files with 1,417 additions and 1,936 deletions.
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ RUN apt-get install -y libhdf5-dev libgles2-mesa-dev
RUN python -m pip install --upgrade pip
COPY requirements-dev.txt /tmp
RUN python -m pip install -r /tmp/requirements-dev.txt
RUN git config --global --add safe.directory /home/pandas
CMD ["/bin/bash"]
2 changes: 1 addition & 1 deletion asv_bench/benchmarks/categoricals.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def setup(self):
)

for col in ("int", "float", "timestamp"):
self.df[col + "_as_str"] = self.df[col].astype(str)
self.df[f"{col}_as_str"] = self.df[col].astype(str)

for col in self.df.columns:
self.df[col] = self.df[col].astype("category")
Expand Down
17 changes: 17 additions & 0 deletions asv_bench/benchmarks/join_merge.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,23 @@ def time_i8merge(self, how):
merge(self.left, self.right, how=how)


class UniqueMerge:
params = [4_000_000, 1_000_000]
param_names = ["unique_elements"]

def setup(self, unique_elements):
N = 1_000_000
self.left = DataFrame({"a": np.random.randint(1, unique_elements, (N,))})
self.right = DataFrame({"a": np.random.randint(1, unique_elements, (N,))})
uniques = self.right.a.drop_duplicates()
self.right["a"] = concat(
[uniques, Series(np.arange(0, -(N - len(uniques)), -1))], ignore_index=True
)

def time_unique_merge(self, unique_elements):
merge(self.left, self.right, how="inner")


class MergeDatetime:
params = [
[
Expand Down
2 changes: 1 addition & 1 deletion asv_bench/benchmarks/timeseries.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ def setup(self):
self.dt_ts = Series(5, rng3, dtype="datetime64[ns]")

def time_resample(self):
self.dt_ts.resample("1S").last()
self.dt_ts.resample("1s").last()


class AsOf:
Expand Down
12 changes: 0 additions & 12 deletions ci/code_checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.Timedelta.to_timedelta64 SA01" \
-i "pandas.Timedelta.total_seconds SA01" \
-i "pandas.Timedelta.view SA01" \
-i "pandas.TimedeltaIndex PR01" \
-i "pandas.TimedeltaIndex.as_unit RT03,SA01" \
-i "pandas.TimedeltaIndex.ceil SA01" \
-i "pandas.TimedeltaIndex.components SA01" \
Expand Down Expand Up @@ -797,8 +796,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.io.formats.style.Styler.clear SA01" \
-i "pandas.io.formats.style.Styler.concat RT03,SA01" \
-i "pandas.io.formats.style.Styler.export RT03" \
-i "pandas.io.formats.style.Styler.format RT03" \
-i "pandas.io.formats.style.Styler.format_index RT03" \
-i "pandas.io.formats.style.Styler.from_custom_template SA01" \
-i "pandas.io.formats.style.Styler.hide RT03,SA01" \
-i "pandas.io.formats.style.Styler.highlight_between RT03" \
Expand All @@ -808,7 +805,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.io.formats.style.Styler.highlight_quantile RT03" \
-i "pandas.io.formats.style.Styler.map RT03" \
-i "pandas.io.formats.style.Styler.map_index RT03" \
-i "pandas.io.formats.style.Styler.relabel_index RT03" \
-i "pandas.io.formats.style.Styler.set_caption RT03,SA01" \
-i "pandas.io.formats.style.Styler.set_properties RT03,SA01" \
-i "pandas.io.formats.style.Styler.set_sticky RT03,SA01" \
Expand Down Expand Up @@ -1022,7 +1018,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.DateOffset.rule_code GL08" \
-i "pandas.tseries.offsets.Day PR02" \
-i "pandas.tseries.offsets.Day.copy SA01" \
-i "pandas.tseries.offsets.Day.delta GL08" \
-i "pandas.tseries.offsets.Day.freqstr SA01" \
-i "pandas.tseries.offsets.Day.is_on_offset GL08" \
-i "pandas.tseries.offsets.Day.kwds SA01" \
Expand Down Expand Up @@ -1075,7 +1070,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.FY5253Quarter.year_has_extra_week GL08" \
-i "pandas.tseries.offsets.Hour PR02" \
-i "pandas.tseries.offsets.Hour.copy SA01" \
-i "pandas.tseries.offsets.Hour.delta GL08" \
-i "pandas.tseries.offsets.Hour.freqstr SA01" \
-i "pandas.tseries.offsets.Hour.is_on_offset GL08" \
-i "pandas.tseries.offsets.Hour.kwds SA01" \
Expand All @@ -1098,7 +1092,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.LastWeekOfMonth.weekday GL08" \
-i "pandas.tseries.offsets.Micro PR02" \
-i "pandas.tseries.offsets.Micro.copy SA01" \
-i "pandas.tseries.offsets.Micro.delta GL08" \
-i "pandas.tseries.offsets.Micro.freqstr SA01" \
-i "pandas.tseries.offsets.Micro.is_on_offset GL08" \
-i "pandas.tseries.offsets.Micro.kwds SA01" \
Expand All @@ -1109,7 +1102,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.Micro.rule_code GL08" \
-i "pandas.tseries.offsets.Milli PR02" \
-i "pandas.tseries.offsets.Milli.copy SA01" \
-i "pandas.tseries.offsets.Milli.delta GL08" \
-i "pandas.tseries.offsets.Milli.freqstr SA01" \
-i "pandas.tseries.offsets.Milli.is_on_offset GL08" \
-i "pandas.tseries.offsets.Milli.kwds SA01" \
Expand All @@ -1120,7 +1112,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.Milli.rule_code GL08" \
-i "pandas.tseries.offsets.Minute PR02" \
-i "pandas.tseries.offsets.Minute.copy SA01" \
-i "pandas.tseries.offsets.Minute.delta GL08" \
-i "pandas.tseries.offsets.Minute.freqstr SA01" \
-i "pandas.tseries.offsets.Minute.is_on_offset GL08" \
-i "pandas.tseries.offsets.Minute.kwds SA01" \
Expand Down Expand Up @@ -1151,7 +1142,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.MonthEnd.rule_code GL08" \
-i "pandas.tseries.offsets.Nano PR02" \
-i "pandas.tseries.offsets.Nano.copy SA01" \
-i "pandas.tseries.offsets.Nano.delta GL08" \
-i "pandas.tseries.offsets.Nano.freqstr SA01" \
-i "pandas.tseries.offsets.Nano.is_on_offset GL08" \
-i "pandas.tseries.offsets.Nano.kwds SA01" \
Expand Down Expand Up @@ -1184,7 +1174,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.QuarterEnd.startingMonth GL08" \
-i "pandas.tseries.offsets.Second PR02" \
-i "pandas.tseries.offsets.Second.copy SA01" \
-i "pandas.tseries.offsets.Second.delta GL08" \
-i "pandas.tseries.offsets.Second.freqstr SA01" \
-i "pandas.tseries.offsets.Second.is_on_offset GL08" \
-i "pandas.tseries.offsets.Second.kwds SA01" \
Expand Down Expand Up @@ -1217,7 +1206,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then
-i "pandas.tseries.offsets.SemiMonthEnd.rule_code GL08" \
-i "pandas.tseries.offsets.Tick GL08" \
-i "pandas.tseries.offsets.Tick.copy SA01" \
-i "pandas.tseries.offsets.Tick.delta GL08" \
-i "pandas.tseries.offsets.Tick.freqstr SA01" \
-i "pandas.tseries.offsets.Tick.is_on_offset GL08" \
-i "pandas.tseries.offsets.Tick.kwds SA01" \
Expand Down
4 changes: 2 additions & 2 deletions ci/deps/actions-310.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ dependencies:
- beautifulsoup4>=4.11.2
- blosc>=1.21.3
- bottleneck>=1.3.6
- fastparquet>=2023.04.0
- fastparquet>=2023.10.0
- fsspec>=2022.11.0
- html5lib>=1.1
- hypothesis>=6.46.1
Expand Down Expand Up @@ -57,7 +57,7 @@ dependencies:
- zstandard>=0.19.0

- pip:
- adbc-driver-postgresql>=0.8.0
- adbc-driver-postgresql>=0.10.0
- adbc-driver-sqlite>=0.8.0
- tzdata>=2022.7
- pytest-localserver>=0.7.1
4 changes: 2 additions & 2 deletions ci/deps/actions-311-downstream_compat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ dependencies:
- beautifulsoup4>=4.11.2
- blosc>=1.21.3
- bottleneck>=1.3.6
- fastparquet>=2023.04.0
- fastparquet>=2023.10.0
- fsspec>=2022.11.0
- html5lib>=1.1
- hypothesis>=6.46.1
Expand Down Expand Up @@ -72,6 +72,6 @@ dependencies:
- pyyaml
- py
- pip:
- adbc-driver-postgresql>=0.8.0
- adbc-driver-postgresql>=0.10.0
- adbc-driver-sqlite>=0.8.0
- tzdata>=2022.7
5 changes: 1 addition & 4 deletions ci/deps/actions-311-numpydev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,7 @@ dependencies:
# test dependencies
- pytest>=7.3.2
- pytest-cov
# Once pytest-cov > 4 comes out, unpin this
# Right now, a DeprecationWarning related to rsyncdir
# causes an InternalError within pytest
- pytest-xdist>=2.2.0, <3
- pytest-xdist>=2.2.0
- hypothesis>=6.46.1

# pandas dependencies
Expand Down
4 changes: 2 additions & 2 deletions ci/deps/actions-311.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ dependencies:
- beautifulsoup4>=4.11.2
- blosc>=1.21.3
- bottleneck>=1.3.6
- fastparquet>=2023.04.0
- fastparquet>=2023.10.0
- fsspec>=2022.11.0
- html5lib>=1.1
- hypothesis>=6.46.1
Expand Down Expand Up @@ -57,6 +57,6 @@ dependencies:
- zstandard>=0.19.0

- pip:
- adbc-driver-postgresql>=0.8.0
- adbc-driver-postgresql>=0.10.0
- adbc-driver-sqlite>=0.8.0
- pytest-localserver>=0.7.1
8 changes: 4 additions & 4 deletions ci/deps/actions-312.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ dependencies:
- beautifulsoup4>=4.11.2
- blosc>=1.21.3
- bottleneck>=1.3.6
- fastparquet>=2023.04.0
- fastparquet>=2023.10.0
- fsspec>=2022.11.0
- html5lib>=1.1
- hypothesis>=6.46.1
- gcsfs>=2022.11.0
- jinja2>=3.1.2
- lxml>=4.9.2
- matplotlib>=3.6.3
# - numba>=0.56.4
- numba>=0.56.4
- numexpr>=2.8.4
- odfpy>=1.4.1
- qtpy>=2.3.0
Expand All @@ -44,7 +44,7 @@ dependencies:
- pyarrow>=10.0.1
- pymysql>=1.0.2
- pyreadstat>=1.2.0
# - pytables>=3.8.0
- pytables>=3.8.0
- python-calamine>=0.1.7
- pyxlsb>=1.0.10
- s3fs>=2022.11.0
Expand All @@ -57,7 +57,7 @@ dependencies:
- zstandard>=0.19.0

- pip:
- adbc-driver-postgresql>=0.8.0
- adbc-driver-postgresql>=0.10.0
- adbc-driver-sqlite>=0.8.0
- tzdata>=2022.7
- pytest-localserver>=0.7.1
4 changes: 2 additions & 2 deletions ci/deps/actions-39-minimum_versions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ dependencies:
- beautifulsoup4=4.11.2
- blosc=1.21.3
- bottleneck=1.3.6
- fastparquet=2023.04.0
- fastparquet=2023.10.0
- fsspec=2022.11.0
- html5lib=1.1
- hypothesis=6.46.1
Expand Down Expand Up @@ -60,6 +60,6 @@ dependencies:
- zstandard=0.19.0

- pip:
- adbc-driver-postgresql==0.8.0
- adbc-driver-postgresql==0.10.0
- adbc-driver-sqlite==0.8.0
- tzdata==2022.7
4 changes: 2 additions & 2 deletions ci/deps/actions-39.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ dependencies:
- beautifulsoup4>=4.11.2
- blosc>=1.21.3
- bottleneck>=1.3.6
- fastparquet>=2023.04.0
- fastparquet>=2023.10.0
- fsspec>=2022.11.0
- html5lib>=1.1
- hypothesis>=6.46.1
Expand Down Expand Up @@ -57,7 +57,7 @@ dependencies:
- zstandard>=0.19.0

- pip:
- adbc-driver-postgresql>=0.8.0
- adbc-driver-postgresql>=0.10.0
- adbc-driver-sqlite>=0.8.0
- tzdata>=2022.7
- pytest-localserver>=0.7.1
2 changes: 1 addition & 1 deletion ci/deps/circle-310-arm64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ dependencies:
- beautifulsoup4>=4.11.2
- blosc>=1.21.3
- bottleneck>=1.3.6
- fastparquet>=2023.04.0
- fastparquet>=2023.10.0
- fsspec>=2022.11.0
- html5lib>=1.1
- hypothesis>=6.46.1
Expand Down
2 changes: 1 addition & 1 deletion ci/run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ echo PYTHONHASHSEED=$PYTHONHASHSEED

COVERAGE="-s --cov=pandas --cov-report=xml --cov-append --cov-config=pyproject.toml"

PYTEST_CMD="MESONPY_EDITABLE_VERBOSE=1 PYTHONDEVMODE=1 PYTHONWARNDEFAULTENCODING=1 pytest -r fE -n $PYTEST_WORKERS --dist=loadfile $TEST_ARGS $COVERAGE $PYTEST_TARGET"
PYTEST_CMD="MESONPY_EDITABLE_VERBOSE=1 PYTHONDEVMODE=1 PYTHONWARNDEFAULTENCODING=1 pytest -r fE -n $PYTEST_WORKERS --dist=worksteal $TEST_ARGS $COVERAGE $PYTEST_TARGET"

if [[ "$PATTERN" ]]; then
PYTEST_CMD="$PYTEST_CMD -m \"$PATTERN\""
Expand Down
2 changes: 1 addition & 1 deletion doc/source/development/contributing_docstring.rst
Original file line number Diff line number Diff line change
Expand Up @@ -940,7 +940,7 @@ Finally, docstrings can also be appended to with the ``doc`` decorator.

In this example, we'll create a parent docstring normally (this is like
``pandas.core.generic.NDFrame``). Then we'll have two children (like
``pandas.core.series.Series`` and ``pandas.core.frame.DataFrame``). We'll
``pandas.core.series.Series`` and ``pandas.DataFrame``). We'll
substitute the class names in this docstring.

.. code-block:: python
Expand Down
4 changes: 2 additions & 2 deletions doc/source/development/maintaining.rst
Original file line number Diff line number Diff line change
Expand Up @@ -151,15 +151,15 @@ and then run::
git bisect start
git bisect good v1.4.0
git bisect bad v1.5.0
git bisect run bash -c "python setup.py build_ext -j 4; python t.py"
git bisect run bash -c "python -m pip install -ve . --no-build-isolation --config-settings editable-verbose=true; python t.py"

This finds the first commit that changed the behavior. The C extensions have to be
rebuilt at every step, so the search can take a while.

Exit bisect and rebuild the current version::

git bisect reset
python setup.py build_ext -j 4
python -m pip install -ve . --no-build-isolation --config-settings editable-verbose=true

Report your findings under the corresponding issue and ping the commit author to get
their input.
Expand Down
4 changes: 2 additions & 2 deletions doc/source/getting_started/install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ SQLAlchemy 2.0.0 postgresql, SQL support for dat
sql-other
psycopg2 2.9.6 postgresql PostgreSQL engine for sqlalchemy
pymysql 1.0.2 mysql MySQL engine for sqlalchemy
adbc-driver-postgresql 0.8.0 postgresql ADBC Driver for PostgreSQL
adbc-driver-postgresql 0.10.0 postgresql ADBC Driver for PostgreSQL
adbc-driver-sqlite 0.8.0 sql-other ADBC Driver for SQLite
========================= ================== =============== =============================================================

Expand All @@ -361,7 +361,7 @@ Dependency Minimum Version pip extra Notes
PyTables 3.8.0 hdf5 HDF5-based reading / writing
blosc 1.21.3 hdf5 Compression for HDF5; only available on ``conda``
zlib hdf5 Compression for HDF5
fastparquet 2023.04.0 - Parquet reading / writing (pyarrow is default)
fastparquet 2023.10.0 - Parquet reading / writing (pyarrow is default)
pyarrow 10.0.1 parquet, feather Parquet, ORC, and feather reading / writing
pyreadstat 1.2.0 spss SPSS files (.sav) reading
odfpy 1.4.1 excel Open document format (.odf, .ods, .odt) reading / writing
Expand Down
8 changes: 0 additions & 8 deletions doc/source/reference/offset_frequency.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1042,7 +1042,6 @@ Properties
.. autosummary::
:toctree: api/

Tick.delta
Tick.freqstr
Tick.kwds
Tick.name
Expand Down Expand Up @@ -1077,7 +1076,6 @@ Properties
.. autosummary::
:toctree: api/

Day.delta
Day.freqstr
Day.kwds
Day.name
Expand Down Expand Up @@ -1112,7 +1110,6 @@ Properties
.. autosummary::
:toctree: api/

Hour.delta
Hour.freqstr
Hour.kwds
Hour.name
Expand Down Expand Up @@ -1147,7 +1144,6 @@ Properties
.. autosummary::
:toctree: api/

Minute.delta
Minute.freqstr
Minute.kwds
Minute.name
Expand Down Expand Up @@ -1182,7 +1178,6 @@ Properties
.. autosummary::
:toctree: api/

Second.delta
Second.freqstr
Second.kwds
Second.name
Expand Down Expand Up @@ -1217,7 +1212,6 @@ Properties
.. autosummary::
:toctree: api/

Milli.delta
Milli.freqstr
Milli.kwds
Milli.name
Expand Down Expand Up @@ -1252,7 +1246,6 @@ Properties
.. autosummary::
:toctree: api/

Micro.delta
Micro.freqstr
Micro.kwds
Micro.name
Expand Down Expand Up @@ -1287,7 +1280,6 @@ Properties
.. autosummary::
:toctree: api/

Nano.delta
Nano.freqstr
Nano.kwds
Nano.name
Expand Down
Loading

0 comments on commit 23b9827

Please sign in to comment.