Page MenuHomePhabricator

[betacluster] Special:Translate does not allow to translate article content - multiple "Uncaught SyntaxError: Unexpected token < in JSON at position 0"
Closed, ResolvedPublic

Description

As part of checking T159795: Port Translate to new RC Filters system, I created a page to be translated on https://meta.wikimedia.beta.wmflabs.org/wiki/Mavetuna (the page has 'Translate this page' link)

  1. On Mavetuna page click on 'Translate this page' link.
  2. Change the language to de and the translation can be started. However, typing anything in tux-textarea-translation will produce multiple errors in the Console:
Uncaught SyntaxError: Unexpected token < in JSON at position 0
  1. Upon saving, the following warning will be displayed:
Saving the translation failed: This namespace is reserved for content page translations. The page you are trying to edit does not seem to correspond any page marked for translation.

Is this issue some sort of beta cluster env limitation?

Event Timeline

I think Translate extension is not properly set up in deployment-prep. @KartikMistry can you check whether Translate's database tables are present?

I think Translate extension is not properly set up in deployment-prep. @KartikMistry can you check whether Translate's database tables are present?

Yes. It seems missing translate_ tables in enwiki database.

greg renamed this task from [betalabs] Special:Translate does not allow to translate article content - multiple "Uncaught SyntaxError: Unexpected token < in JSON at position 0" to [betacluster] Special:Translate does not allow to translate article content - multiple "Uncaught SyntaxError: Unexpected token < in JSON at position 0".Dec 12 2017, 7:45 PM
greg updated the task description. (Show Details)

I think Translate extension is not properly set up in deployment-prep. @KartikMistry can you check whether Translate's database tables are present?

Yes. It seems missing translate_ tables in enwiki database.

Oh, metawiki in betaclusters contains Translate tables. So, this seems different issue now.

Mentioned in SAL (#wikimedia-releng) [2018-01-15T13:37:24Z] <kart_> Ran update.php on metawiki betacluster (T180841)

Mentioned in SAL (#wikimedia-releng) [2018-01-15T13:59:38Z] <kart_> Ran: "mwscript extensions/Translate/scripts/createMessageIndex.php --wiki=metawiki" for T180841

@Etonkovidova Can you mark the page for translation again? It seems my account doesn't have admin rights.

Mentioned in SAL (#wikimedia-releng) [2018-01-15T13:59:38Z] <kart_> Ran: "mwscript extensions/Translate/scripts/createMessageIndex.php --wiki=metawiki" for T180841

This fixed the "state" of Translate's tracking. It is unclear what caused the state to become invalid in the first place. We wanted to test whether it breaks if we mark page for translation, but neither of our accounts have the rights to do that.

Checked in betalabs - no Console errors as described in the ticket. I was able to type, save etc the translation.

However, there is a peculiar error when you click on one of the row tux-message-selector options ('All', 'Untranslated "Outdated', 'Translated', 'Unreviewed'). The issue seems a quite minor - filed as T185038