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

Assume str return annotation if none provided #708

Merged
merged 1 commit into from
Jan 2, 2024
Merged

Conversation

jlowin
Copy link
Member

@jlowin jlowin commented Jan 2, 2024

AI functions without return annotations currently raise a cryptic pydantic error. This PR:

  • raises a more explicit and clear error if an empty annotation is provided
  • makes ai functions return string values by default, to avoid the error entirely

@jlowin jlowin merged commit 7295c29 into main Jan 2, 2024
11 checks passed
@jlowin jlowin deleted the fix-no-return-error branch January 2, 2024 21:08
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.

None yet

2 participants