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

Install sos in an environment #66

Open
avianinc opened this issue Aug 3, 2023 · 14 comments
Open

Install sos in an environment #66

avianinc opened this issue Aug 3, 2023 · 14 comments

Comments

@avianinc
Copy link

avianinc commented Aug 3, 2023

Is there a way to install sos in a conda environment. I'm trying to install sos and elyra at the same time and it never works. I'm wondering if there is a way to install sos in an env. If I do get it to install right now... which happens occasionally depending on order of the installation I do not see the sos drop down combo box. I'm assuming this is jupyterlab 4.x related. I rolled the install back to 3.6.x but I never seems to install into the base environment correctly. Lastly, I'm building jupyterhub (not just lab).

@BoPeng
Copy link
Contributor

BoPeng commented Aug 3, 2023

Unfortunately, as reported by #65 as well, we do not yet support JupyterLab 4.x because it has some breaking API change that I currently do not have time to investigate. The only way to proceed is to use JupyterLab 3.x, which we have been using in a JupyterHub environment successfully.

I will see if I can have another look at JupyterLab 4.x this weekend.

@avianinc
Copy link
Author

avianinc commented Aug 4, 2023

My real question should have been. Can I install sos in a conda environment under jupytehub. I have tried several ways but it never seems to work. I can see it in the notebook but not the lab. Do you have an example conda environment I can use to test the install? Thanks

@BoPeng
Copy link
Contributor

BoPeng commented Aug 4, 2023

I may have to consult our admin for this but as far as I remember, he installed jupyterhub using a conda environment, and then I used pip install to install sos related stuff to the conda environment on which jupyterhub/jupyterlab is running. I used pip instead of conda for installation because the pip versions are more up to date. (e.g. the latest version of sos-r is not available from conda-forge).

@BoPeng
Copy link
Contributor

BoPeng commented Sep 15, 2023

JLab 4.x is now (partially) supported.

@BoPeng BoPeng closed this as completed Sep 15, 2023
@avianinc
Copy link
Author

avianinc commented Oct 6, 2023

@BoPeng... thanks for the update. I'm trying my best to install SoS. It's not happening anymore. I have spent hours trying to install this on windows, linux, using both conda and pip methods. I cannot get any working environments. Would you happen to have a working environment you could share? Regards,

@BoPeng BoPeng reopened this Oct 6, 2023
@BoPeng
Copy link
Contributor

BoPeng commented Oct 6, 2023

Please be more specific about what you have done, which versions of packages you have installed so that I can better assist you. But in general,

  1. you can use the sos docker image (https://vatlab.github.io/sos-docs/running.html#content) if you can use docker. It is not updated for JLab 4.x but it works.
  2. You need to use a new conda environment so that I can reproduce your problem. The installation is actually pretty easy usually. WIthout checking syntax etc,
conda create --name jlab python=3.10 -y
cona activate jlab
pip install jupyterlab jupyterlab-sos sos-python
python -m sos_notebook.install

If things do not work, send me the output of

pip list | grep jupyter
pip list | grep sos
jupyter kernelspec list
jupyter labextension list

@avianinc
Copy link
Author

avianinc commented Oct 6, 2023 via email

@BoPeng
Copy link
Contributor

BoPeng commented Oct 7, 2023

First the version of jupyterlab-sos does not look right, pip says 0.10.0, but labextension says 0.8.9 . Then, do you see the right hand side kernel selector from jupyterlab? I do not see it from your screenshot. The output of %use from jupyter will also show status of available kernels.

@avianinc
Copy link
Author

avianinc commented Oct 9, 2023

Bo... I tried the docker image and the same thing is happening. See the included image. This is from a fresh build of the docker image on Linux. You can see that the python kernel is not able to '%get' but in the next cell you can see that R works fine.

image

I have this issue no matter the OS or install method.
Thanks,

@BoPeng
Copy link
Contributor

BoPeng commented Oct 10, 2023

On mac,

image image

@avianinc
Copy link
Author

avianinc commented Oct 10, 2023

Bo... I have tried this everywhere today, aws, linux, docker, no docker, and windows (I don't have a mac...). All of the kernels I have installed work but python. Any chance you might ask someone to run this on a linux or windows box to verify what I'm seeing or even try the sos docker image.
This has been an issue for over a year, I kept thinking it was my installation causing the problem (still could be...) but tried conda, pip, virtualenv, basic jupyterlab installs on several linux flavors. The kicker for me was pulling the sos docker image with the same result right out of the build.

image
image
image

Thanks for all your help here, I really like SoS and wanted to start up again but I'm stuck....

@BoPeng
Copy link
Contributor

BoPeng commented Oct 11, 2023

Thank you for your patience. There are many moving pieces with jupyter and sos-notebook but I can now reproduce the problem with the official docker image. Let me check what is going on.

@BoPeng
Copy link
Contributor

BoPeng commented Oct 11, 2023

This turns out to be an issue of sos-python with python >= 3.10. Please update sos-python to 0.20.2 and see if the problem persists.

@avianinc
Copy link
Author

YES!!!! That was a tough one. Thank you for sticking with me here. The python integration is working now on windows and linux...

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

No branches or pull requests

2 participants