[Bug]: Unsupported operand types: string * int
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.
Hi! Have you found a solution?
Apologies for the delayed response. Since there is no code sample here and no stacktrace I'm afraid I don't have any context as to what to check. Your hint was "creating assistants" and "uploading files" to which I've sampled both without an issue.
So unfortunately I'm going to close this - I don't see enough context to go further on it.