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
Is upload_file thread safe? #327
Comments
Does this mean that this method does not support concurrency? |
the error desc:[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:2621) |
@jiupinjiandingshi, I tried running Prompting with media files tutorial and |
If I run it once, there is no problem, as follows: But if my interface receives two requests at the same time, this code may be called twice in the same time period. In this case, an error will be reported as follows: |
try to run |
Thanks, please reopen this if the problem comes back in a reproducible way. |
i tried upgrading the library as suggested by @sMx7d . But still getting errors
anyone else finding the same issue? |
@ronfromhp , uninstall and reinstall it. |
@sMx7d somehow its gone back to giving the ssl error these are the installed libraries: This is the same old error trace im getting:
|
Its stil a ssl error , sorry but i don't know anything in ssl or what it means . |
@jiupinjiandingshi can you reopen the issue? As currently I havent found a resolution which works |
sorry , i just reviewed the error and i saw |
as of my previous comment i was still getting the same ssl error even after updating genai @sMx7d |
Description of the bug:
when I want use genai , I need to use this method in an interface request, but when I put "genai.upload_file(path=path,display_name=file)" into the interface method, it will report an error SLL_ERROR
@app.route("/xxx",method=["GET"]) def upload_video(): output_frame_folder = requests.output_frame_folder time.sleep(1.0) lists = [] try: for file in os.listdir(f"{output_frame_folder}"): path = os.path.join(f"{output_frame_folder}", file) sample_file = genai.upload_file(path=path,display_name=file)
Actual vs expected behavior:
No response
Any other information you'd like to share?
No response
The text was updated successfully, but these errors were encountered: