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

Add tutorial stub based on iPython Sphinx extension #167

Merged
merged 1 commit into from
Sep 21, 2020

Conversation

amotl
Copy link
Member

@amotl amotl commented Sep 18, 2020

Dear Benjamin,

regarding #136, I gave IPython.sphinxext.ipython_directive a shot. With the updates coming from this PR, the iPython Sphinx extension will work in general, but currently will fail when actually hitting code from Wetterdienst [1].

Currently, I am clueless about how to solve this and will be happy if you could take a look. To reproduce, just invoke

cd docs
make html

on this branch.

Cheers,
Andreas.

[1] I've used code from example/simple_example.ipynb for that. Thanks!

cc @larsrinn

@codecov
Copy link

codecov bot commented Sep 18, 2020

Codecov Report

Merging #167 into master will decrease coverage by 0.04%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #167      +/-   ##
==========================================
- Coverage   91.85%   91.80%   -0.05%     
==========================================
  Files          28       28              
  Lines        1436     1440       +4     
  Branches      103      104       +1     
==========================================
+ Hits         1319     1322       +3     
- Misses         88       89       +1     
  Partials       29       29              
Flag Coverage Δ
#unittests 91.80% <100.00%> (-0.05%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
wetterdienst/additionals/functions.py 100.00% <100.00%> (ø)
wetterdienst/data_storing.py 65.00% <0.00%> (-1.67%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 19a80fe...dadc3c7. Read the comment docs.

@gutzbenj
Copy link
Member

Thanks, I'll take a look!

@amotl
Copy link
Member Author

amotl commented Sep 18, 2020

Ah. The imports actually do work, but not real code.

@gutzbenj
Copy link
Member

Please adjust the imports accordingly to make it work (import wetterdienst instead of from wetterdienst import ...)

@amotl
Copy link
Member Author

amotl commented Sep 20, 2020

Please adjust the imports accordingly to make it work (import wetterdienst instead of from wetterdienst import ...)

Hm. Even when trying what you suggest

    In [4]: import warnings
       ...: warnings.filterwarnings("ignore")
       ...: import wetterdienst

It will still croak here:

    In [5]: print("All available combinations")
       ...: print(wetterdienst.discover_climate_observations())

@amotl
Copy link
Member Author

amotl commented Sep 21, 2020

After making a few adjustments, it now seems to work on my machine.

@gutzbenj gutzbenj merged commit daee29d into earthobservations:master Sep 21, 2020
@gutzbenj
Copy link
Member

gutzbenj commented Sep 21, 2020

Docs fail with:

ModuleNotFoundError: No module named 'IPython'

Extension error:
Could not import extension IPython.sphinxext.ipython_directive (exception: No module named 'IPython')

@amotl amotl mentioned this pull request Sep 21, 2020
@amotl amotl deleted the sphinx-ipython branch September 23, 2020 00:30
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.

None yet

2 participants