-
Notifications
You must be signed in to change notification settings - Fork 26
No module named 'mywb.sklearn_cookbook' #8
Comments
Thanks for reporting the problem. You mentioned you're running on a clone of the repo. I'm assuming that means you both installed the extension from it, not from the stable pip install, and are using the notebooks from their location within the repo directory structure. If this is correct, a couple potential problems come to mine:
If neither of these relates to your problem, could you please write back with your notebook server version? Edit: Typos while trying to type on a mobile. :/ |
@jhconning I agree with you about changing the way you organize notebooks; once you start importing notebooks, it's hard to stop. I have to admit that it has been a looong time since I've used Windows. However, I did find a Windows 7 machine (I don't have Windows 10 handy, nor did I consider upgrading the Windows 7 machine I did find), and I tried to reproduce your error.
As for your environment, the first thing I would check is the path to the sklearn_notebook. Try an import statement using the full path from the base of the notebook directory, e.g.
|
Thank you all for your detailed troubleshooting help. However the 'import mywb ...' route still does not work for me on a Windows machine. In case it helps you track the problem here is my setup:
Regarding the Thanks again for your help and this expansion in the functionality and power of jupyter. |
The fact that the function works tells me there's a platform specific bug in the handling of the dotted module name. I don't have Windows, but I can give the code a once over.
In case it's an option for you or anyone else that finds this issue in the future, the https://github.com/jupyter/docker-stacks project has a set of ready-to-run, Debian-based images that you could use on your Windows machine via the Docker Toolbox. |
I took a look at the code. The bug is likely in the finder classes https://github.com/jupyter-incubator/contentmanagement/blob/master/urth/cms/loader.py#L228. I'm not seeing it by reading the code. Need a couple prints for name and path in those classes, and then a a couple of attempts to import notebooks using the dotted module notation on Windows. |
I started to have a look. I'm on Win 10, x64, Anaconda Python 2.7. I think I located the issue - at least for me. It seems to be in Edit: typo |
I ran into this myself the other day for the first time. I do not know a better way of identify which notebook server is the "right" notebook server. Adding a note to the README about it sounds like the best approach for the moment. |
The tmpnb online test_cookbooks example worked flawlessly. However I'm running into errors when I try to run same notebook from the cloned repository on my windows 10 machine.
The new search functionality from the jupyter file navigation is working from the Jupyter file browser (and is awesome).
However when I load and the test_cookbooks.ipynb notebook I run into trouble. The first cell
magic runs with no problem but the cell
leads to
As mentioned, I'm running this on an exact clone of the repo. I see and can open the sklearn_cookbook notebook. It's just that the 'fake dir' for mywb does not seem to be working.
P.S. -- This project is fantastic. It will transform how I organize code and notebooks. Thanks.
The text was updated successfully, but these errors were encountered: