File Upload API keep geting 500 Error

Using CLI tools or python code gives the same result. Cannot figure out the reason.
Actually I have use an almost same file yesterday and it works. But now it just return 500.

openai api files.create -f data/training_prompt.jsonl -p “fine-tune”
Upload progress: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.07M/1.07M [00:00<00:00, 26.2Mit/s]
Error: HTTP code 500 from API (

Internal Server Error

Internal Server Error

) (HTTP status code: 500)
3 Likes

Hi holdon,

Does this happen multiple times? I’m just wondering if this was transient issue with the server and it’s now ok.

Hi Fox, I have no clue. It has not happened before, but multiple times today.

The CLI command is: openai api files.create -f data/training_prompt_prepared.jsonl -p “fine-tune”
Upload progress: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1.06M/1.06M [00:00<00:00, 25.8Mit/s]

and then, it just take forever to wait the respond and finally return error code 500
Error: HTTP code 500 from API (

Internal Server Error

Internal Server Error

) (HTTP status code: 500)

Interesting, can you try with a different dataset as a further sanity check?

1 Like

Actually I have tried another old and once succeeded dataset, but still got the same result. Can’t imagine what kind of error it could be.

1 Like

Same problem here :sob:

My cmd:
openai api fine_tunes.create -t covid_prepared.jsonl -m davinci
The result on terminal
Upload progress: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████| 345k/345k [00:00<00:00, 314Mit/s]
Error: HTTP code 500 from API (

Internal Server Error

Internal Server Error

) (HTTP status code: 500)

Maybe errors occurs from the openai api server side

Ok, so on the face of it, this may be a server side issue that has not been picked up yet. it would be worth sending an email to support@openai.com informing them of this issue, I doubt you will get a reply today… maybe? they are extremely busy but it is monitored, so I’d do that anyway.

There remains the possibility that there is some change in your procedure that is causing it, but again, that is only a guess.

Thanks! I will double check the whole process very carefully.

1 Like

A New findings, if the file size is small enough, like 30 kb, it may succeed. But if the size larger than 100kb, it will take a long time and fail as a 500 code error.

I guess it is actually some kind of internal timeout error.

I’m trying with smaller file size (about 130Kb) so hope it will not catch timeout error but i think its not the case

I tried 100 kb and it failed, 10 kb succeeded. Maybe you can try a single or several lines (like 1 kb). To see whether the size matters.

No, nothing work for me. Even the smallest file that contain only several of rows :man_facepalming:

1 Like

Some updates, Just test the api on files with different size.
30k, succeeded everytime. 80k, 1/2 success rate. 150k, never, 1mb, always fail.

Awkward error, but cannot figure out the reason.

The problem is solved. But I still have no clue about what happened.

There was a fine tuning issue that got detected, my guess is you were experiencing that system fault, and now that it has been resolved you are back up and running.

I had same issue before and it solved only when I truned off Cloudflare proxy Orange icon for the file-server that receive the uploaded file .