mirror of
https://github.com/open-webui/open-webui.git
synced 2026-07-16 23:21:44 -05:00
[GH-ISSUE #5748] Problem loading Python Library when running the code on the sandbox - Asking for python 3.12 #68714
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @peuportier on GitHub (Sep 27, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/5748
Bug Report
Installation Method
Pip install under python 3.11
Environment
Open WebUI Version: [e.g., v0.3.30] ---> 0.3.30
Ollama (if applicable): [e.g., v0.2.0, v0.1.32-rc1] ---> 0.3.12
Operating System: [e.g., Windows 10, macOS Big Sur, Ubuntu 20.04] ---> MacOS X M1 -- Somona 14.1.1
Browser (if applicable): [e.g., Chrome 100.0, Firefox 98.0] --> Safari 17.4.1
Confirmation:
Expected Behavior:
Expected that gave me the result or display what we asking for.
It only work for Mermaid or Matplolib
Actual Behavior:
Problem to get the library or to call it
Description
So when first I ask
This no problem (Libraries likes numpy, matplotlib, seaborn) work fine. But when I need something more specific such as using Network X . I get the error.
If you want reproduce just asking:
Can you make me a mind map with fictional data?
it generate
then when run the code
PythonError: Traceback (most recent call last): File "/lib/python312.zip/_pyodide/_base.py", line 502, in eval_code .run(globals, locals) ^^^^^^^^^^^^^^^^^^^^ File "/lib/python312.zip/_pyodide/_base.py", line 340, in run coroutine = eval(self.code, globals, locals) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<exec>", line 1, in <module> ModuleNotFoundError: No module named 'networkx' The module 'networkx' is included in the Pyodide distribution, but it is not installed. You can install it by calling: await micropip.install("networkx") in Python, or await pyodide.loadPackage("networkx") in JavaScript See https://pyodide.org/en/stable/usage/loading-packages.html for more details.Thanks you for your time, and guide me to a solution, if you have no time of course.