aws-samples / aws-samples/sagemaker-studio-lifecycle-config-examples
scripts/install-lsp-features/on-jupyter-server-start.sh causes studio to fail
- Dominant language
- Shell
- Stars
- 88
- Forks
- 54
- PR merge metrics
- No merged PRs in 30d
Description
On sagemaker studio with jupyter lab version 3, the script installs incompatible dependencies. This causes the launcher to be completely removed from studio with no way to recover (not even deleting and recreating the jupyter server app is recoverable). The only way to recover it to totally delete a user's profile and re-create them.
https://github.com/aws-samples/sagemaker-studio-lifecycle-config-examples/blob/be187b588255a83ed5137d95791b2e1dd1c2bfd1/scripts/install-lsp-features/on-jupyter-server-start.sh#L28-L31
It seems the dependencies should be pinned to compatible versions in the script to avoid this issue.
Output:
```
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
sagemaker-sharing 0.1 requires attrs==21.4.0, but you have attrs 23.1.0 which is incompatible.
sagemaker-sharing 0.1 requires jsonschema==4.17.3, but you have jsonschema 4.19.0 which is incompatible.
sagemaker-sharing 0.1 requires jupyter-client==7.1.2, but you have jupyter-client 7.4.9 which is incompatible.
sagemaker-sharing 0.1 requires notebook-shim==0.1.0, but you have notebook-shim 0.2.3 which is incompatible.
sagemaker-sharing 0.1 requires packaging==21.3, but you have packaging 23.1 which is incompatible.
sagemaker-sharing 0.1 requires pyzmq==22.3.0, but you have pyzmq 25.1.1 which is incompatible.
sagemaker-sharing 0.1 requires Send2Trash==1.8.0, but you have send2trash 1.8.2 which is incompatible.
sagemaker-sharing 0.1 requires tornado==6.1, but you have tornado 6.3.3 which is incompatible.
sagemaker-sharing 0.1 requires traitlets==5.2.2.post1, but you have traitlets 5.9.0 which is incompatible.
sagemaker-nb2kg 0.1 requires jsonschema==4.17.3, but you have jsonschema 4.19.0 which is incompatible.
sagemaker-nb2kg 0.1 requires jupyter-client==7.1.2, but you have jupyter-client 7.4.9 which is incompatible.
sagemaker-nb2kg 0.1 requires tornado==6.1, but you have tornado 6.3.3 which is incompatible.
jupyter-server-mathjax 0.2.5 requires jupyter-server~=1.1, but you have jupyter-server 2.7.3 which is incompatible.
```
Contributor guide
Research direction
Start with scripts/install-lsp-features/on-jupyter-server-start.sh at lines 28–31 and inspect the dependencies installed for JupyterLab 3. Compare those requirements with the listed SageMaker conflicts, then verify that compatible versions are pinned and the launcher remains available after the script runs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- jupyter, shell
- Domain
- devops, tooling
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100