Skip to content

Update statsmodels due to issue in latest scipy 1.16.0#18

Open
stefanDeveloper wants to merge 1 commit intoFengrui-Liu:mainfrom
stefanDeveloper:main
Open

Update statsmodels due to issue in latest scipy 1.16.0#18
stefanDeveloper wants to merge 1 commit intoFengrui-Liu:mainfrom
stefanDeveloper:main

Conversation

@stefanDeveloper
Copy link
Copy Markdown

@stefanDeveloper stefanDeveloper commented Jul 31, 2025

Issue with latest scipy version 1.16.0

As described here statsmodels/statsmodels#9584 , in our project https://github.com/stefanDeveloper/heiDGAF that heavily builds on your library, we run into the same issue.

ImportError: Failed to import test module: inspector.test_inspector
Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/unittest/loader.py", line 419, in _find_test_path
    module = self._get_module_from_name(name)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/unittest/loader.py", line 362, in _get_module_from_name
    __import__(name)
  File "/home/runner/work/heiDGAF/heiDGAF/tests/inspector/test_inspector.py", line 8, in <module>
    from streamad.model import ZScoreDetector, RShashDetector
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/streamad/__init__.py", line 12, in <module>
    from . import model
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/streamad/model/__init__.py", line 13, in <module>
    from .SArima_Detector import SArimaDetector
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/streamad/model/SArima_Detector.py", line 5, in <module>
    import statsmodels.api as sm
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/statsmodels/api.py", line 72, in <module>
    from . import datasets, distributions, iolib, regression, robust, tools
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/statsmodels/distributions/__init__.py", line 4, in <module>
    from .discrete import genpoisson_p, zipoisson, zigenpoisson, zinegbin
  File "/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/statsmodels/distributions/discrete.py", line 4, in <module>
    from scipy._lib._util import _lazywhere
ImportError: cannot import name '_lazywhere' from 'scipy._lib._util' (/opt/hostedtoolcache/Python/3.11.13/x64/lib/python3.11/site-packages/scipy/_lib/_util.py)

@stefanDeveloper stefanDeveloper changed the title Update statsmodels due to issue in latest scipy 1.6.0 Update statsmodels due to issue in latest scipy 1.16.0 Jul 31, 2025
@stefanDeveloper
Copy link
Copy Markdown
Author

Just checking in — is there any update on upgrading statsmodels to the latest version?
We’d really appreciate it since we need it in order to support higher Python versions.

@maldwg
Copy link
Copy Markdown

maldwg commented Sep 25, 2025

I second this PR, please merge.
@stefanDeveloper thank you for the PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants