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

Not working with WebGL builds #47

Closed
LucienMaman opened this issue Apr 25, 2023 · 6 comments
Closed

Not working with WebGL builds #47

LucienMaman opened this issue Apr 25, 2023 · 6 comments

Comments

@LucienMaman
Copy link

Hi @srcnalt , thanks for this amazing project!
As with previous similar issues, I am stuck with my WebGL build. It works well in the editor but not in the web version where I got an error 400 when posting to https://api.openai.com/v1/chat/completions (ie, when sending a message) from the game hosted on my website.

I am developing on MacOS (M1 chip) and the editor version is 2021.3.22f1.
I tried to pull the latest code from the repo but still do not solve the issue.

Some of my build settings that might be of interest are attached.
Any help would be really appreciated :)

I'll keep you updated if I find any solution in the meantime.

Cheers.

Capture d’écran 2023-04-25 à 13 06 19

Capture d’écran 2023-04-25 à 13 05 59

@srcnalt
Copy link
Owner

srcnalt commented May 1, 2023

Hi @LucienMaman I was able to test on 3 different Unity versions and 2020.x and 2022.x worked, however 2021 is nor able to build it. Added a small table at the end of the readme file and I will update it as I can find more about which features break where.

@srcnalt srcnalt closed this as completed May 1, 2023
@LucienMaman
Copy link
Author

Hi @srcnalt, thanks for the support! However, I tried out to build it with the versions 2022.2.8f1 but also 2022.2.17f1, and I'm still receiving an error 400 when posting to https://api.openai.com/v1/chat/completions.

I double-checked, and it is working well in my editor. Any guess/hints I can try out to make it works?
Thanks again,

@srcnalt
Copy link
Owner

srcnalt commented May 1, 2023

I will be able to get my hands on a MAC only 2 weeks later, I hope some can with Mac can take a look and check that.

@LucienMaman
Copy link
Author

Thanks @srcnalt. I will post an update if I manage to find the bug before you get access to a MAC :)

@LucienMaman
Copy link
Author

Quick update, it looks like a similar issue as in #21

I tried the same debugging steps and it looks like the error comes from Newtonsoft as well. Not sure how to debug further yet.

@LucienMaman
Copy link
Author

Hi @srcnalt, I had access to a PC so I tried to open my Unity project with it. The webGL build is still not working (ie, getting a 400 error when posting to chatGPT). It still works in the editor.
I tried with the 3 versions as you did (2020, 2021, 2022), double-checked that the version of Newtonsoft was updated (ie, I tried with 3.1.0 and 3.2.0) and a similar issue is happening. Any help would be highly appreciated :)

Thanks!

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