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

[Bug]: Unsupported operand types: string * int #443

Open
Muhammad-Huzaifa7 opened this issue Jul 4, 2024 · 1 comment
Open

[Bug]: Unsupported operand types: string * int #443

Muhammad-Huzaifa7 opened this issue Jul 4, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@Muhammad-Huzaifa7
Copy link

Description

I am encountering an error "Unsupported operand types: string * int" when trying to use the OpenAI PHP Client to upload files and create assistants. The error occurs in the following scenarios:

When calling the uploadFileToOpenAI method and other methods like creating assistants etc

Steps To Reproduce

Steps To Reproduce
Set up the environment:

Ensure you have the OpenAI PHP Client package installed.
Set the OPENAI_API_KEY in the .env file.
Create a Laravel service class:
Call the methods:

OpenAI PHP Client Version

v0.10.1

PHP Version

8.2.12

Notes

The issue seems to stem from the file handling or request payload preparation within the OpenAI PHP Client.
I have verified that the API key is correctly set and that the file path is valid.
Any additional insights or troubleshooting steps would be greatly appreciated.

@Muhammad-Huzaifa7 Muhammad-Huzaifa7 added the bug Something isn't working label Jul 4, 2024
@kayke-fairy
Copy link

Hi! Have you found a solution?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants