Skip to content
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

Handle missing API key more gracefully #174

Merged
merged 2 commits into from
Jun 25, 2024
Merged

Handle missing API key more gracefully #174

merged 2 commits into from
Jun 25, 2024

Conversation

jlowin
Copy link
Member

@jlowin jlowin commented Jun 25, 2024

Closes #169

If you import CF and the default model can't be set (usually/probably because you didn't set the API key env var), a friendly warning is logged but the library doesn't crash. It will crash, however, if you try to use an agent without providing a valid model.

@jlowin jlowin merged commit 8238703 into main Jun 25, 2024
3 checks passed
@jlowin jlowin deleted the import-error branch June 25, 2024 02:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

default_model requires OPENAI_API_KEY to be set even with custom LLMs
1 participant