Skip to content

Commit

Permalink
fix matplotlib deprecation
Browse files Browse the repository at this point in the history
  • Loading branch information
weaverba137 committed Aug 2, 2024
1 parent 3b513b4 commit 46ad6aa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: [3.8]
python-version: ['3.10']

steps:
- name: Checkout code
Expand All @@ -72,7 +72,7 @@ jobs:
run: |
python -m pip install --upgrade pip wheel setuptools
python -m pip install pytest pytest-astropy pyyaml coveralls
python -m pip install Pillow\<10.4 numpy\<1.21 scipy\<1.6 matplotlib\<3.4 astropy\<5.0
python -m pip install numpy\<2.0 scipy matplotlib astropy
- name: Run the test with coverage
run: pytest --cov
Expand Down
5 changes: 4 additions & 1 deletion speclite/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -1991,7 +1991,10 @@ def plot_filters(responses, wavelength_unit=None,
min_wlen, max_wlen = min(effective_wavelengths), max(effective_wavelengths)

import matplotlib.pyplot as plt
import matplotlib.cm as cm
try:
import matplotlib.colormaps as cm
except ImportError:
import matplotlib.cm as cm

cmap = cm.get_cmap(cmap)
fig, ax = plt.subplots()
Expand Down

0 comments on commit 46ad6aa

Please sign in to comment.