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

Usage.fromMap fails on completions property #5

Open
tomtaila opened this issue Jan 9, 2023 · 1 comment
Open

Usage.fromMap fails on completions property #5

tomtaila opened this issue Jan 9, 2023 · 1 comment

Comments

@tomtaila
Copy link

tomtaila commented Jan 9, 2023

I get the following when requesting some completions:

error: type 'Null' is not a subtype of type 'int' in type cast, stacktrace: #0 new Usage.fromMap (package:openai_client/src/model/shared_models/usage.dart:17:53)

I imagine it happens when no results are generated by openAI

@Azzeccagarbugli
Copy link
Owner

Hello @tomtaila, would you be able to reproduce the error and share the code snippet? Thanks a lot in advance!

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

No branches or pull requests

2 participants