Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing imports warnings in docs branch #153

Closed
niketagrawal opened this issue Sep 7, 2023 · 2 comments
Closed

Missing imports warnings in docs branch #153

niketagrawal opened this issue Sep 7, 2023 · 2 comments

Comments

@niketagrawal
Copy link
Collaborator

niketagrawal commented Sep 7, 2023

Building the docs in docs branch generates warnings for missing imports.

$ make html
sphinx-build -b html -d _build/doctrees   . _build/html
Running Sphinx v7.1.2
making output directory... done
checking bibtex cache... out of date
parsing bibtex file ~/aeolis-python/docs/aeolis.bib... parsed 160 entries
building [mo]: targets for 0 po files that are out of date
writing output...
building [html]: targets for 18 source files that are out of date
updating environment: [new config] 18 added, 0 changed, 0 removed
<frozen importlib._bootstrap>:219: RuntimeWarning: numpy.ndarray size changed, may indicate binary incompatibility. Expected 16 from C header, got 96 from PyObject
reading sources... [100%] user/whatsnew
WARNING: autodoc: failed to import class 'AeoLiS' from module 'model'; the following exception was raised:
Traceback (most recent call last):
  File "~/aeolis-dev/lib/python3.8/site-packages/sphinx/ext/autodoc/importer.py", line 66, in import_module
    return importlib.import_module(modname)
  File "/usr/lib/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 848, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "~/aeolis-python/aeolis/model.py", line 48, in <module>
    import aeolis.inout
  File "~/aeolis-python/aeolis/__init__.py", line 55, in <module>
    import aeolis.model
  File "~/aeolis-python/aeolis/model.py", line 49, in <module>
    import aeolis.bed
  File "~/aeolis-python/aeolis/bed.py", line 32, in <module>
    import aeolis.gridparams
  File "~/aeolis-python/aeolis/gridparams.py", line 37, in <module>
    def initialize(s:dict, p:dict) -> tuple[dict, dict]:
TypeError: 'type' object is not subscriptable
@manuGil
Copy link
Collaborator

manuGil commented Sep 13, 2023

While following this issue, another came out. There's a conflict between the versions of RTD theme and docutils. readthedocs/sphinx_rtd_theme#1517

They fixed the incompatibility issue but it requires Sphinx > 7.1

@manuGil
Copy link
Collaborator

manuGil commented Sep 13, 2023

There is also incompatibility between sphinx-rtd-theme version 1.3 and Sphinx 7. readthedocs/readthedocs.org#10279
Pining the Sphinx versions ot <7 solved the issue

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

No branches or pull requests

2 participants