-
Notifications
You must be signed in to change notification settings - Fork 128
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
No module named 'json' error #108
Comments
same |
3 similar comments
same |
same |
same |
I haven't tried your scenario, but I can roughly guess the reason for the problem, mainly related to the location of Python. When building the project, the Python related environment will be copied to |
I resolved this issue through the following steps: Start the Image: docker start <container_name>
docker exec -it <container_name> /bin/bash Modify the Default Python Path: Check the current Python path: which python Update the PATH environment variable to point to Miniconda’s Python: export PATH="/path/to/miniconda/bin:$PATH" Verify the change: which python Save the Changes: docker commit <container_id> <new_image_name> Restart the Image: docker stop <container_name>
docker start <container_name>
docker exec -it <container_name> /bin/bash
which python # Confirm the Python path is correctly set By following this approach, I successfully switched the Python environment of the sandbox image to Miniconda, resolving the related issue. |
I have deployed the Sanbox local source code, and I have updated the python_path to the path of the Miniconda virtual environment (python_path=/root/miniconda3/envs/sanbox/bin/python). However, when I actually use it, it still reports a 'No module named 'json'' error
If I'm deploying with Miniconda, is this configuration not workable?
The text was updated successfully, but these errors were encountered: