karrot-dev / karrot-frontend

We migrated to https://codeberg.org/karrot/karrot-frontend
https://codeberg.org/karrot/karrot-frontend
427 stars 178 forks source link

Fix transifex error on updating locales #2638

Closed nicksellen closed 1 year ago

nicksellen commented 1 year ago

https://app.circleci.com/pipelines/github/karrot-dev/karrot-frontend/4266/workflows/5c3062f8-59b6-45ec-81f8-a00ac05cd19d/jobs/39269 shows an error when doing tx push:

yarn run v1.22.19
$ updateLocalesHelper/env/bin/tx push -s
tx INFO: No credentials file was found at /root/.transifexrc.
tx INFO: Created /root/.transifexrc 
tx INFO: Pushing resource karrot.frontend
tx INFO: Updating /root/.transifexrc file...
tx INFO: Using TX_TOKEN environment variable. Credentials won't be saved to .transifexrc.
tx ERROR: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
// I snipped some content here
  <title>
Page not found
</title>
// I snipped some content here

I guess we need to update tx in our deployment image.

tiltec commented 1 year ago

I had a look, seems the transifex python client and the old API are deprecated and we should switch to the new (Go-based) client.

Also, the URL where we got the translation status (percent translated) from doesn't seem to exist anymore, so we might need to find a replacement there. This might be the only candidate: https://developers.transifex.com/reference/get_resource-language-stats Unfortunately, it requires some computation to get the data...

Do we actually need the translation progress bars in the UI? If not, we could save some work here...

nicksellen commented 1 year ago

I think they are nice! and it might give a hint to translators that use karrot when more stuff is needed... but not essential.

Most important is being up to push/pull changes. Is it something you are motivated to look into more?

tiltec commented 1 year ago

I continued a bit with it today, maybe I can push a fix tomorrow :)

tiltec commented 1 year ago

It should work again, both backend and frontend!