Skip to content

Commit 990b0b5

Browse files
mne-botautofix-ci[bot]larsoner
authored
MAINT: Update dependency specifiers (#13899)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Eric Larson <larson.eric.d@gmail.com>
1 parent 692ecce commit 990b0b5

12 files changed

Lines changed: 34 additions & 28 deletions

File tree

azure-pipelines.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ stages:
114114
- bash: |
115115
set -eo pipefail
116116
python -m pip install --progress-bar off --upgrade pip
117-
python -m pip install --progress-bar off "mne-qt-browser[opengl] @ git+https://github.com/mne-tools/mne-qt-browser.git" pyvista scikit-learn python-picard qtpy nibabel sphinx-gallery "PySide6!=6.8.0,!=6.8.0.1,!=6.8.1.1,!=6.9.1" pandas neo pymatreader antio defusedxml curryreader pymef
117+
python -m pip install --progress-bar off "mne-qt-browser @ https://github.com/mne-tools/mne-qt-browser/archive/refs/heads/main.zip" pyvista scikit-learn python-picard qtpy nibabel sphinx-gallery "PySide6!=6.8.0,!=6.8.0.1,!=6.8.1.1,!=6.9.1" pandas neo pymatreader antio defusedxml curryreader pymef
118118
python -m pip uninstall -yq mne
119119
python -m pip install --progress-bar off --upgrade -e . --group=test
120120
displayName: 'Install dependencies with pip'
@@ -164,7 +164,7 @@ stages:
164164
python -m pip install --progress-bar off --upgrade pip
165165
python -m pip install --progress-bar off --upgrade --pre --only-binary=\"numpy,scipy,matplotlib,vtk\" numpy scipy matplotlib vtk
166166
python -c "import vtk"
167-
python -m pip install --progress-bar off --upgrade -ve .[full] --group=test_extra
167+
python -m pip install --progress-bar off --upgrade -ve .[full] --group=test_extra "mne-qt-browser @ https://github.com/mne-tools/mne-qt-browser/archive/refs/heads/main.zip"
168168
displayName: 'Install dependencies with pip'
169169
- bash: |
170170
set -e
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Updated minimum for:
2+
3+
- Core dependency ``matplotlib >= 3.9``
4+
5+
Changes implemented via CI action created by `Thomas Binns`_.

environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ dependencies:
2727
- jupyter
2828
- lazy_loader >=0.3
2929
- mamba
30-
- matplotlib >=3.8
30+
- matplotlib >=3.9
3131
- mffpy >=0.5.7
3232
- mne-qt-browser
3333
- nest-asyncio2

mne/fixes.py

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,9 @@ def _compare_version(version_a, operator, version_b):
5757

5858

5959
###############################################################################
60-
# NumPy 2.5 deprecates .shape assignment, but .reshape(copy=False) requires 2.1+
60+
# NumPy 2.5 removes .shape assignment, but .reshape(copy=False) requires 2.1+
61+
62+
# TODO VERSION remove on NumPy 2.1+
6163

6264

6365
def _reshape_view(arr, shape):
@@ -66,10 +68,8 @@ def _reshape_view(arr, shape):
6668
This function provides compatibility across NumPy versions for reshaping
6769
arrays as views. On NumPy >= 2.1, it uses ``reshape(copy=False)`` which
6870
explicitly fails if a view cannot be created. On older versions, it uses
69-
direct shape assignment which has the same behavior but is deprecated in
70-
NumPy 2.5+.
71-
72-
Can be removed once NumPy 2.1 is the minimum supported version.
71+
direct shape assignment which has the same behavior but is being removed
72+
as of NumPy 2.5+.
7373
7474
Parameters
7575
----------
@@ -765,8 +765,7 @@ def minimum_phase(h, method="homomorphic", n_fft=None, *, half=True):
765765
return h_minimum[:n_out]
766766

767767

768-
# SciPy 1.15 deprecates sph_harm for sph_harm_y and using it will trigger a
769-
# DeprecationWarning. This is a backport of the new function for older SciPy versions.
768+
# TODO VERSION SciPy 1.15+ (sph_harm -> sph_harm_y)
770769
def sph_harm_y(n, m, theta, phi, *, diff_n=0):
771770
"""Wrap scipy.special.sph_harm for sph_harm_y."""
772771
# Can be removed once we no longer support scipy < 1.15.0

mne/time_frequency/tfr.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1939,7 +1939,7 @@ def plot(
19391939
cnorm=None,
19401940
cmap=None,
19411941
colorbar=True,
1942-
title=None, # don't deprecate this one; has (useful) option title="auto"
1942+
title=None, # keep: has (useful) option title="auto"
19431943
mask=None,
19441944
mask_style=None,
19451945
mask_cmap="Greys",
@@ -2481,7 +2481,7 @@ def plot_topo(
24812481
vmax=None,
24822482
layout=None,
24832483
cmap="RdBu_r",
2484-
title=None, # don't deprecate; topo titles aren't standard (color, size, just.)
2484+
title=None, # keep: topo titles aren't standard (color, size, just.)
24852485
dB=False,
24862486
colorbar=True,
24872487
layout_scale=0.945,
@@ -3432,7 +3432,7 @@ def plot(
34323432
cnorm=None,
34333433
cmap=None,
34343434
colorbar=True,
3435-
title=None, # don't deprecate this one; has (useful) option title="auto"
3435+
title=None, # keep: has (useful) option title="auto"
34363436
mask=None,
34373437
mask_style=None,
34383438
mask_cmap="Greys",
@@ -3484,7 +3484,7 @@ def plot_topo(
34843484
vmax=None,
34853485
layout=None,
34863486
cmap=None,
3487-
title=None, # don't deprecate; topo titles aren't standard (color, size, just.)
3487+
title=None, # keep: topo titles aren't standard (color, size, just.)
34883488
dB=False,
34893489
colorbar=True,
34903490
layout_scale=0.945,

mne/utils/dataframe.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,10 @@ def _convert_times(
5858

5959

6060
def _inplace(df, method, **kwargs):
61-
# TODO VERSION can be removed once pandas>=3.0 is required
61+
# TODO VERSION remove on pandas 3.0+
6262
# Handle transition: inplace=True (pandas <1.5) → copy=False (>=1.5)
6363
# and 3.0 warning:
64-
# E DeprecationWarning: The copy keyword is deprecated and will be removed in a
64+
# The copy keyword will be removed in a
6565
# future version. Copy-on-Write is active in pandas since 3.0 which utilizes a
6666
# lazy copy mechanism that defers copies until necessary. Use .copy() to make
6767
# an eager copy if necessary.

mne/utils/spectrum.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ def _split_psd_kwargs(*, plot_fun=None, kwargs=None):
106106

107107

108108
def _convert_old_birthday_format(info):
109-
"""Convert deprecated birthday tuple to datetime."""
109+
"""Convert old birthday tuple to datetime."""
110110
subject_info = info.get("subject_info")
111111
if subject_info is not None:
112112
birthday = subject_info.get("birthday")

mne/viz/backends/_utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,9 @@ def _init_mne_qtapp(enable_icon=True, pg_app=False, splash=False):
193193
out = app
194194
if splash:
195195
pixmap = QPixmap(f"{icons_path}/mne_splash.png")
196-
pixmap.setDevicePixelRatio(QGuiApplication.primaryScreen().devicePixelRatio())
196+
screen = QGuiApplication.primaryScreen()
197+
ratio = screen.devicePixelRatio() if screen else 1
198+
pixmap.setDevicePixelRatio(ratio)
197199
args = (pixmap,)
198200
if _should_raise_window():
199201
args += (Qt.WindowStaysOnTopHint,)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ dependencies = [
102102
"decorator >= 5.1",
103103
"jinja2 >= 3.1",
104104
"lazy_loader >= 0.3",
105-
"matplotlib >= 3.8", # released 2023-09-15, will become 3.9 on 2026-05-15
105+
"matplotlib >= 3.9", # released 2024-05-15, will become 3.10 on 2026-12-14
106106
"numpy >= 1.26, < 3", # released 2023-09-16, will become 2.0 on 2026-06-16
107107
"packaging",
108108
"pooch >= 1.5",

tools/azure_dependencies.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
55
STD_ARGS="--progress-bar off --upgrade "
66
python -m pip install $STD_ARGS pip setuptools wheel
77
if [ "${TEST_MODE}" == "pip" ]; then
8-
python -m pip install $STD_ARGS --only-binary="numba,llvmlite,numpy,scipy,vtk,dipy,openmeeg" -e .[full] --group=test
8+
python -m pip install $STD_ARGS --only-binary="numba,llvmlite,numpy,scipy,vtk,dipy,openmeeg" -e .[full] --group=test "mne-qt-browser @ https://github.com/mne-tools/mne-qt-browser/archive/refs/heads/main.zip"
99
elif [ "${TEST_MODE}" == "pip-pre" ]; then
1010
${SCRIPT_DIR}/install_pre_requirements.sh
1111
python -m pip install $STD_ARGS --pre -e . --group=test_extra

0 commit comments

Comments
 (0)