cheeaun / phanpy

A minimalistic opinionated Mastodon web client
https://phanpy.social
MIT License
1.07k stars 107 forks source link

"Chinese (Traditional)" post translation is not working #626

Open dalechou opened 2 months ago

dalechou commented 2 months ago

"Chinese (Traditional)" post translation is not working, getting "Failed to translate" error message.

Site: phanpy.social Site version: 2024.08.11.16248c4 Instance: g0v.social

I am reporting this for a friend. I cannot reproduce the bug, but he has provided step-by-step screenshots (please see below).

Steps to reproduce behaviour:

  1. Check "Post translation", set target language as, "Chinese (Traditional)".
  2. Check "Auto inline translation".
  3. Check "Cloak mode" (not sure if this is related).
  4. Read foreign posts to trigger auto inline translation.
  5. "Failed to translate" error message is shown where there should be translation.

Expected behaviour: instead of getting the "Failed to translate" error message, there should be translated text in Traditional Chinese displayed under the post.

Device is iPad running iPadOS 17.5.1 (21F90).

Screenshots:

243c433d749c4b5a

7ebb877ed3bb49e3

3fa697f9314f4a49

cheeaun commented 2 months ago

@dalechou does it happen if retrying? It seems like it could be a random network issue (I hope).

dalechou commented 2 months ago

This may be a network issue, but one that is long term. My friend is in Taiwsan. He said that it is still happening, and has happened for weeks. He has tried both at home network and a nearby café, both having the same issue.

I cannot reproduce this issue, but I am not in Taiwan.

(Thanks for responding so fast!)

cheeaun commented 2 months ago

@dalechou there are few possibilities; one of them is probably the API endpoint is blocked by something or a certain proxy altered the response.

This will need more details as I can't reproduce this on my side too. Further questions + steps:

dalechou commented 2 months ago

For OS/browsers, my friend tried the following:

The issue continues to happen with different OS/browsers.

As for the site used, it was Production (phanpy.social). The site version is 2024.08.11.16248c4 on instance g0v.social.


I asked my friend to try accessing sites like https://lingva.ml/ (a site that also uses Lingva) and it turns out that he was blocked from the site. There may be some sort of block like you mentioned.

I started a poll on g0v.social to see if there are other people also blocked. The poll is still ongoing, but it seems like my friend is not alone: https://g0v.social/@dale/112969402911069117

cheeaun commented 2 months ago

@dalechou Phanpy has its own lingva implementation (forked from lingva's) and its own sub-domain too. Try this https://lingva.phanpy.social/api/v1/en/zh_HANT/test and check the response.

dalechou commented 2 months ago

Response from my friend is back!

e85004983fe4e1c2