No matter how I set my variables, it keeps wanting to use an OPENAI_API_KEY, throwing the same error. Seems like it’s missing the VIRTUAL_ENV location somehow, so is defaulting to something else which doesn’t have the variables set? I don’t see where to set these things in the web UI at all.
Subprocess execution failed: Subprocess failed with return code 1.
STDERR: warning: VIRTUAL_ENV=/data/internal/venv does not match the project environment path /shared_venv and will be ignored; use --active to target the active environment instead
Building reasoning-swarm-with-persistent-memory @ file:///tmp/crewai_gmj6zrys
Built reasoning-swarm-with-persistent-memory @ file:///tmp/crewai_gmj6zrys
Uninstalled 1 package in 0.22ms
Installed 1 package in 1ms
Error during execution: Error importing native provider: OPENAI_API_KEY is required
Traceback (most recent call last):
File “/shared_venv/lib/python3.12/site-packages/crewai/llm.py”, line 404, in new
native_class(model=model_string, provider=provider, **kwargs_copy),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/shared_venv/lib/python3.12/site-packages/crewai/llms/providers/openai/completion.py”, line 97, in init
client_config = self._get_client_params()
^^^^^^^^^^^^^^^^^^^^^^^^^
File “/shared_venv/lib/python3.12/site-packages/crewai/llms/providers/openai/completion.py”, line 134, in _get_client_params
raise ValueError(“OPENAI_API_KEY is required”)
ValueError: OPENAI_API_KEY is required
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File “/automation/src/crewai_studio_runner/subprocess/launcher.py”, line 324, in main
execute_crew(args.module_name, args.class_name, inputs)
File “/automation/src/crewai_studio_runner/subprocess/launcher.py”, line 236, in execute_crew
crew = crew_class().crew()
^^^^^^^^^^^^^^^^^^^
File “/shared_venv/lib/python3.12/site-packages/crewai/project/utils.py”, line 70, in wrapper
result = meth(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File “/shared_venv/lib/python3.12/site-packages/crewai/project/annotations.py”, line 237, in wrapper
crew_instance: Crew = _call_method(meth, self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/shared_venv/lib/python3.12/site-packages/crewai/project/annotations.py”, line 163, in _call_method
result = method(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^
File “/tmp/crewai_gmj6zrys/src/reasoning_swarm_with_persistent_memory/crew.py”, line 201, in crew
chat_llm=LLM(model=“openai/gpt-4o-mini”),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/shared_venv/lib/python3.12/site-packages/crewai/llm.py”, line 409, in new
raise ImportError(f"Error importing native provider: {e}") from e
ImportError: Error importing native provider: OPENAI_API_KEY is required


