I make a build request using the /api/v2/projects/1234/translations/builds endpoint and with {"targetLanguageIds":["ja"],"branchId":4321} POST payload. Notice that I’m building a specific branch for a specific language (Japanese). This gives me a 201 response code and a response body of {"data" : {"attributes" : {"branchId" : 4321,"directoryId" : null,"exportApprovedOnly" : false,"skipUntranslatedFiles" : false,"skipUntranslatedStrings" : false,"targetLanguageIds" : ["ja"]},"createdAt" : "2024-12-10T20:06:42+00:00","finishedAt" : "2024-12-10T20:06:42+00:00","id" : 111,"progress" : 100,"projectId" : 1234,"status" : "finished","updatedAt" : "2024-12-10T20:06:42+00:00"}}. I then make a download request using the /api/v2/projects/1234/translations/builds/111/download endpoint however I receive a 404 response code with a response body of String Not Found. Why does it show me a completed build with a specific ID but when I go to access that build by its ID it gives me a 404 error? To be 100% sure I’m not tripping I used an entirely new Token that has ALL permissions but it still had the same issue. Odd thing is this only happens randomly on random languages. I was able to build and download many languages before running into this issue.
Another odd thing is I cannot delete (cancel) the build by ID. It tells me the delete request is successful with 204 response code but if I make a build request after it gives me the same build with same ID, etc.
Update: I was forcing new builds of the Japanese language and kept getting the same Build ID. So I forced builds/downloads for other languages (which worked) and then went back to the Japanese language and same issue and Build ID. After typing out the OP above I forced another build of another language and went back to the Japanese language yet again and randomly it started working again… super odd. I didn’t change anything. I was trying this all day and all of a sudden it’s working again. I can’t explain it.
I see that the project you’re participating in is 75% translated into Japanese. Do you have any export options configured? Like skipping strings or files, etc?
I’ve noticed some error logs on my end. Specifically, some 409 Conflict errors (that build_1 was in progress when you triggered build_2), and what is interesting about the mentioned 404 error, it was received when you ran a cURL call, while the same call via GIT (I assume, GitHub Actions) was successful.
If the issue is only with cURL, you can try using some lightweight client or Postman instead.
You can check project API logs (Tools section) to see the detailed response on each action.
Yes, using that API call along with the progress one and download one.
No export options configured other than “Save context info” and “Auto-fill dialects”.
I’m using cURL via PHP (in my application) to make the API calls. I’m also testing it by manually running via cURL on CLI to make sure nothing in the code is wrong. Not using Github actions at all. So in short, both methods (cURL CLI and cURL PHP) are failing. Same methods work with other languages. Just randomly not with some languages.
Update: I came in this morning, tried building Vietnamese and same issue and same Build ID as yesterday. So I forced a build of another language (Danish) which worked so I then immediately forced another build of Vietnamese and it worked as expected with no changes. It’s so odd…
We would need to run few additional tests on the matter, I’ve created internal taskі for this (54544) and (54545).
As for now, I haven’t been able to re-create exactly the same issue in my test project, so I can’t provide any 100% working work-around. Still, I’ve double-checked the project logs, and I have one theory that can help.
I noticed that last time project was fully build on 11 Jul 2023. How about building full project now?
After that, please try adding some buffer time into your CI Pipeline? Let’s say, a 4-5 minutes delay. For example, you received a Build Status reply, that build is ready, wait 4-5 minutes, and then trigger Build download.
I thought the same thing so when I had the issue with Japanese I manually built the language from within the UI and that still didn’t help. I will try that next time I encounter the issue to see if it helps.
I also thought about the buffer and I implemented a loop that sleeps for a few seconds and makes a new call to check the progress and only attempts download when 100%. The sleep is often enough to not exceed the built-in API rate limit.
It’s just an odd issue that happens to random languages for a random period of time. So far today I only ran into it with 1 or 2 languages and have built and downloaded many other languages. So it’s just super odd and very random.