genai-impact / ecologits

🌱 EcoLogits tracks the energy consumption and environmental footprint of using generative AI models through APIs.
https://ecologits.ai/
Mozilla Public License 2.0
63 stars 8 forks source link

OpenAI cassette bug #18

Closed adrienbanse closed 6 months ago

adrienbanse commented 6 months ago

Bug description OpenAI test fails even with the cassette, I get the following error: "FAILED tests/test_openai.py::test_openai_chat - openai.OpenAIError: The api_key client option must be set either by passing api_key to the client or by setting the OPENAI_API_KEY environment variable"

Am I doing something wrong?

To Reproduce Update deps poetry install --all-extras --with dev,docs Run tests poetry run pytest

System information OS: macOS Ventura 13.5.2