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
ModuleNotFoundError during Kernel Initialization (Windows) #98
Comments
Yeah, I was able to get the Python bits loaded but ran into a few other issues that I’m working through in lldb itself (like module loading) |
Okay, so, one thing that I've found is that we need a few extra flags when starting the REPL: I think that for the Jupyter notebook case, we can workaround this by modifying the toolchain in the Jupyter setup - take an additional parameter in the install script |
Awesome, I'll give that a go. Is the SDK root this
If it's all in relative paths I could add the SDKROOT as an env variable (a little messy with the dirname's and path joining), and we could symlink for readability. |
Yes, that’s the SDKROOT (%SystemDrive%\Library\Developer\Platforms\Windows.platform\Developer\SDKs\Windows.sdk). Wait, you’re saying that it’s possible to do this with environment variables? That would be really handy to switch between different SDK versions. Hmm, I didn’t catch that before. Windows doesn’t have the concept of LD_LIBRARY_PATH. The path needs to be added to the PATH variable. The path that you are spending which “diverges” is not the SDK. XCTest is not part of the SDK (you don’t ship the tests, you ship the application/library), it’s a developer library. That’s why it is separate. Most things are relative to the SDKROOT. The only thing which is relative to the DEVELOPERROOT is XCTest. |
Currently the Oh I see, I think I might need your help with what each section in the folder tree does (and consequently what swift-jupyter needs). Which one contains the Swift toolchain libs, the XCTest or the SDK root? |
Actually, it does adjust the path. The installer has been getting better over time, but, I think it comes down to finding the ways to improve it and finding others to help with it :) The current three interesting bits: https://github.com/compnerd/swift-build/blob/master/wix/windows-runtime.wxs#L104-L106 Basically, the toolchain, runtime, and tensorflow are injected into the path. Im totally open to patches to improve the installers BTW :) If it would make things easier, having an advanced option to set I am absolutely happy to explain that. I'll actually see if I can draft up something as an explanation of the current layout in the swift-build project, and for whatever other pieces which are missing, we can extend it to cover that. That way we have an easy reference for the future. |
Initial pass at the documentation of the layout: https://github.com/compnerd/swift-build/blob/master/docs/Layout.md For improvements to the toolchain layout/installation lets keep the discussion on the swift-build project so that others watching that project can possibly get involved as well. |
Still getting the error "ImportError: DLL load failed while importing _lldb: The specified module could not be found." Any resolution? |
I think that your |
Thanks |
Steps to reproduce:
git remote add -f mikkeyboi https://github.com/mikkeyboi/swift-jupyter.git
git checkout mikkeyboi/master
register.py
while inside conda environmentpython register.py --sys-prefix --swift-python-use-conda --use-conda-shared-libs --swift-toolchain path/to/toolchain
jupyter notebook
while within conda environmentAlternatively..
path/to/toolchain/usr/lib/site-packages
and run interactive pythonipython
import lldb
I think it's not loading the
_lldb.pyd
file that's inside the lldb module. Either that, or I'm missing DLLs (can confirm with Dependency Walker).@compnerd Were you able to load the lldb module during your testing (specifically the
_lldb.pyd
file)?The text was updated successfully, but these errors were encountered: