paragon icon indicating copy to clipboard operation
paragon copied to clipboard

Transifex / react-intl "Error validating message" blocking pull translations

Open adamstankiewicz opened this issue 1 year ago • 0 comments

Description

16:38:47 [@formatjs/cli] [WARN] Error validating message "El tipo de archivo debe ser {count, plural, one {{typeString} archivo} otro {one of {typeString} files}}." with ID "dropzone.Dropzone.invalidType" in file "./src/i18n/messages/es_419.json" 16:38:47 SyntaxError: MISSING_OTHER_CLAUSE

It appears there may be a newly reviewed translation for the es_419 locale regarding the dropzone.Dropzone.invalidType message extracted from Dropzone. Let's look into the error and see if we can resolve to get the pull_translations job working again.

Reach out to @adamstankiewicz (preferably on Slack) to re-run the Transifex pull_translations job as needed.

Full stack trace

16:38:00 Started by timer
16:38:00 [EnvInject] - Loading node environment variables.
16:38:00 [EnvInject] - Preparing an environment for the build.
16:38:00 [EnvInject] - Keeping Jenkins system variables.
16:38:00 [EnvInject] - Keeping Jenkins build variables.
16:38:00 [EnvInject] - Injecting as environment variables the properties content 
16:38:00 REPO_NAME=paragon
16:38:00 SETUP_SCRIPT=nodeenv -p --node=12.18.2 --prebuilt --force
16:38:00 JOB_SCRIPT=python3.8 transifex/pull.py https://github.com/edx/paragon.git openedx/paragon --skip-compilemessages
16:38:00 GIT_USER_NAME=edX Transifex Bot
16:38:00 [email protected]
16:38:00 REQUIREMENT_FILE=transifex/requirements/microfrontend-common.txt
16:38:00 LMS_CFG=
16:38:00 STUDIO_CFG=
16:38:00 REVISION_CFG=
16:38:00 
16:38:00 [EnvInject] - Variables injected successfully.
16:38:00 [EnvInject] - Injecting contributions.
16:38:00 Building in workspace /edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace
16:38:00  > git rev-parse --is-inside-work-tree # timeout=10
16:38:00 Fetching changes from the remote Git repository
16:38:00  > git config remote.origin.url https://github.com/edx/ecommerce-scripts.git # timeout=10
16:38:00 Pruning obsolete local branches
16:38:00 Fetching upstream changes from https://github.com/edx/ecommerce-scripts.git
16:38:00  > git --version # timeout=10
16:38:00  > git -c core.askpass=true fetch --tags --progress https://github.com/edx/ecommerce-scripts.git +refs/heads/*:refs/remotes/origin/* --prune
16:38:01  > git rev-parse refs/remotes/origin/master^{commit} # timeout=10
16:38:01  > git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
16:38:01 Checking out Revision 839303f922062f2d0666275de2e04605e951d4a0 (refs/remotes/origin/master)
16:38:01  > git config core.sparsecheckout # timeout=10
16:38:01  > git checkout -f 839303f922062f2d0666275de2e04605e951d4a0
16:38:01  > git rev-list 839303f922062f2d0666275de2e04605e951d4a0 # timeout=10
16:38:01 Cleaning workspace
16:38:01  > git rev-parse --verify HEAD # timeout=10
16:38:01 Resetting working tree
16:38:01  > git reset --hard # timeout=10
16:38:01  > git clean -fdx # timeout=10
16:38:01 [workspace] $ /bin/bash -xe /tmp/hudson6000361139311817300.sh
16:38:01 + set +u
16:38:01 + . /edx/var/jenkins/jobvenvs/virtualenv_tools.sh
16:38:01 + create_virtualenv --python=python3.8 --clear
16:38:01 + '[' -z '' ']'
16:38:01 + echo 'No JOBVENVDIR found. Using default value.'
16:38:01 No JOBVENVDIR found. Using default value.
16:38:01 + JOBVENVDIR=/edx/var/jenkins/jobvenvs
16:38:01 ++ md5sum
16:38:01 ++ cut '-d ' -f1
16:38:01 ++ pwd
16:38:01 + venvname=c1c36453ca7cea9f9a09f2f04c106e3b
16:38:01 + virtualenv --python=python3.8 --clear /edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b
16:38:09 created virtual environment CPython3.8.5.final.0-64 in 8261ms
16:38:09   creator CPython3Posix(dest=/edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b, clear=True, no_vcs_ignore=False, global=False)
16:38:09   seeder FromAppData(download=False, pip=bundle, wheel=bundle, setuptools=bundle, via=copy, app_data_dir=/edx/var/jenkins/.local/share/virtualenv)
16:38:09     added seed packages: pip==22.1.2, setuptools==63.1.0, wheel==0.37.1
16:38:09   activators PythonActivator,FishActivator,XonshActivator,CShellActivator,PowerShellActivator,BashActivator
16:38:09 + venvpath=/edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b
16:38:09 + . /edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin/activate
16:38:09 ++ '[' /edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin/activate = /tmp/hudson6000361139311817300.sh ']'
16:38:09 ++ deactivate nondestructive
16:38:09 ++ unset -f pydoc
16:38:09 ++ '[' -z '' ']'
16:38:09 ++ '[' -z '' ']'
16:38:09 ++ '[' -n /bin/bash ']'
16:38:09 ++ hash -r
16:38:09 ++ '[' -z '' ']'
16:38:09 ++ unset VIRTUAL_ENV
16:38:09 ++ '[' '!' nondestructive = nondestructive ']'
16:38:09 ++ VIRTUAL_ENV=/edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b
16:38:09 ++ '[' linux-gnu = cygwin ']'
16:38:09 ++ '[' linux-gnu = msys ']'
16:38:09 ++ export VIRTUAL_ENV
16:38:09 ++ _OLD_VIRTUAL_PATH=/usr/lib/jvm/java-8-oracle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
16:38:09 ++ PATH=/edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin:/usr/lib/jvm/java-8-oracle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
16:38:09 ++ export PATH
16:38:09 ++ '[' -z '' ']'
16:38:09 ++ '[' -z '' ']'
16:38:09 ++ _OLD_VIRTUAL_PS1=
16:38:09 ++ '[' x '!=' x ']'
16:38:09 +++ basename /edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b
16:38:09 ++ PS1='(c1c36453ca7cea9f9a09f2f04c106e3b) '
16:38:09 ++ export PS1
16:38:09 ++ alias pydoc
16:38:09 ++ true
16:38:09 ++ '[' -n /bin/bash ']'
16:38:09 ++ hash -r
16:38:09 + set -u
16:38:09 + echo '[https://www.transifex.com/]'
16:38:09 + echo 'hostname = https://www.transifex.com/'
16:38:09 + echo 'username = ****'
16:38:09 + echo 'password = ****'
16:38:09 + echo 'rest_hostname = https://rest.api.transifex.com/'
16:38:09 + echo 'token = ********'
16:38:09 + cd ecommerce-scripts
16:38:09 + pip3 install -r transifex/requirements/microfrontend-common.txt
16:38:11 Collecting Django==2.2.20
16:38:11   Using cached Django-2.2.20-py3-none-any.whl (7.5 MB)
16:38:11 Collecting edx-i18n-tools==0.5.3
16:38:11   Using cached edx_i18n_tools-0.5.3-py2.py3-none-any.whl (29 kB)
16:38:11 Collecting PyGithub==1.55
16:38:11   Using cached PyGithub-1.55-py3-none-any.whl (291 kB)
16:38:11 Collecting PyYAML==5.4
16:38:11   Using cached PyYAML-5.4-cp38-cp38-manylinux1_x86_64.whl (662 kB)
16:38:11 Collecting nodeenv==1.3.0
16:38:11   Using cached nodeenv-1.3.0-py3-none-any.whl
16:38:11 Collecting sqlparse>=0.2.2
16:38:11   Using cached sqlparse-0.4.2-py3-none-any.whl (42 kB)
16:38:12 Collecting pytz
16:38:12   Using cached pytz-2022.1-py2.py3-none-any.whl (503 kB)
16:38:12 Collecting six
16:38:12   Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
16:38:12 Collecting path.py>=7.0
16:38:12   Using cached path.py-12.5.0-py3-none-any.whl (2.3 kB)
16:38:12 Collecting polib
16:38:12   Using cached polib-1.1.1-py2.py3-none-any.whl (20 kB)
16:38:12 Collecting pynacl>=1.4.0
16:38:12   Using cached PyNaCl-1.5.0-cp36-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl (856 kB)
16:38:12 Collecting requests>=2.14.0
16:38:12   Using cached requests-2.28.1-py3-none-any.whl (62 kB)
16:38:12 Collecting pyjwt>=2.0
16:38:12   Using cached PyJWT-2.4.0-py3-none-any.whl (18 kB)
16:38:12 Collecting deprecated
16:38:12   Using cached Deprecated-1.2.13-py2.py3-none-any.whl (9.6 kB)
16:38:12 Collecting path
16:38:12   Using cached path-16.4.0-py3-none-any.whl (26 kB)
16:38:13 Collecting cffi>=1.4.1
16:38:13   Using cached cffi-1.15.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (442 kB)
16:38:13 Collecting charset-normalizer<3,>=2
16:38:13   Using cached charset_normalizer-2.1.0-py3-none-any.whl (39 kB)
16:38:13 Collecting certifi>=2017.4.17
16:38:13   Using cached certifi-2022.6.15-py3-none-any.whl (160 kB)
16:38:13 Collecting idna<4,>=2.5
16:38:13   Using cached idna-3.3-py3-none-any.whl (61 kB)
16:38:13 Collecting urllib3<1.27,>=1.21.1
16:38:13   Using cached urllib3-1.24.3-py2.py3-none-any.whl (118 kB)
16:38:13 Collecting wrapt<2,>=1.10
16:38:13   Using cached wrapt-1.14.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (81 kB)
16:38:13 Collecting pycparser
16:38:13   Using cached pycparser-2.21-py2.py3-none-any.whl (118 kB)
16:38:14 Installing collected packages: pytz, polib, nodeenv, wrapt, urllib3, sqlparse, six, PyYAML, pyjwt, pycparser, path, idna, charset-normalizer, certifi, requests, path.py, Django, deprecated, cffi, pynacl, edx-i18n-tools, PyGithub
16:38:19 Successfully installed Django-2.2.20 PyGithub-1.55 PyYAML-5.4 certifi-2022.6.15 cffi-1.15.1 charset-normalizer-2.1.0 deprecated-1.2.13 edx-i18n-tools-0.5.3 idna-3.3 nodeenv-1.3.0 path-16.4.0 path.py-12.5.0 polib-1.1.1 pycparser-2.21 pyjwt-2.4.0 pynacl-1.5.0 pytz-2022.1 requests-2.28.1 six-1.16.0 sqlparse-0.4.2 urllib3-1.24.3 wrapt-1.14.1
16:38:19 
16:38:19 [notice] A new release of pip available: 22.1.2 -> 22.2.1
16:38:19 [notice] To update, run: pip install --upgrade pip
16:38:19 + mkdir transifex_client
16:38:19 + cd transifex_client
16:38:19 + curl -o- https://raw.githubusercontent.com/transifex/cli/master/install.sh
16:38:19 + bash
16:38:19   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
16:38:19                                  Dload  Upload   Total   Spent    Left  Speed
16:38:19 
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  3106  100  3106    0     0   121k      0 --:--:-- --:--:-- --:--:--  121k
16:38:19 ** Installing CLI from https://github.com/transifex/cli/releases/latest/download/tx-linux-amd64.tar.gz
16:38:19 
16:38:19   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
16:38:19                                  Dload  Upload   Total   Spent    Left  Speed
16:38:19 
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
16:38:19 
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
16:38:19 
100 4146k  100 4146k    0     0  15.1M      0 --:--:-- --:--:-- --:--:-- 15.1M
16:38:19 
16:38:19 ** Adding CLI to PATH
16:38:19 ** Profile not found, we tried for .profile, .bashrc, .bash_profile, .zshrc
16:38:19 ** Please add this line to the correct file if you want to access 'tx' from any path.
16:38:19 
16:38:19 export PATH="/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/transifex_client:$PATH"
16:38:19 
16:38:19 
16:38:19 ** If everything went fine you should see the Transifex CLI version in the following line.
16:38:19 TX Client, version=1.3.0
16:38:19 + export PATH=/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/transifex_client:/edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin:/usr/lib/jvm/java-8-oracle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
16:38:19 + PATH=/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/transifex_client:/edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin:/usr/lib/jvm/java-8-oracle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
16:38:19 + cd ..
16:38:19 + set +u
16:38:19 + nodeenv -p --node=12.18.2 --prebuilt --force
16:38:23  * Install prebuilt node (12.18.2) ..... done.
16:38:23  * Appending data to /edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin/activate
16:38:23  * Appending data to /edx/var/jenkins/jobvenvs/c1c36453ca7cea9f9a09f2f04c106e3b/bin/activate.fish
16:38:23 + set -u
16:38:23 + python3.8 transifex/pull.py https://github.com/edx/paragon.git openedx/paragon --skip-compilemessages
16:38:24 Cloning into 'configuration'...
16:38:25 Switched to a new branch 'transifex-bot-update-translations2022-08-07'
16:38:25 2022-08-07 20:38:25,220 INFO 127761 [pull.py:54] - Pulling lms/studio settings from [configuration].
16:38:25 Cloning into 'paragon'...
16:38:26 Switched to a new branch 'transifex-bot-update-translations2022-08-07'
16:38:26 2022-08-07 20:38:26,879 INFO 127761 [pull.py:60] - Pulling translations for [paragon].
16:38:26 npm ci
16:38:40 
16:38:40 > @fortawesome/[email protected] postinstall /edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/@fortawesome/fontawesome-common-types
16:38:40 > node attribution.js
16:38:40 
16:38:40 Font Awesome Free 6.1.1 by @fontawesome - https://fontawesome.com/
16:38:40 License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
16:38:40 Copyright 2022 Fonticons, Inc.
16:38:40 
16:38:40 
16:38:40 > @fortawesome/[email protected] postinstall /edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/@fortawesome/fontawesome-svg-core
16:38:40 > node attribution.js
16:38:40 
16:38:40 Font Awesome Free 6.1.1 by @fontawesome - https://fontawesome.com/
16:38:40 License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
16:38:40 Copyright 2022 Fonticons, Inc.
16:38:40 
16:38:41 
16:38:41 > [email protected] postinstall /edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/core-js-pure
16:38:41 > node -e "try{require('./postinstall')}catch(e){}"
16:38:41 
16:38:41 added 1244 packages in 14.042s
16:38:41 tx pull -f --mode reviewed --languages="ar,ca,es_419,fr,he,id,ko_KR,pl,pt_BR,ru,th,uk,zh_CN"
16:38:41 # Getting info about resources
16:38:41 
16:38:41 edx-platform.paragon - Getting info
16:38:42 edx-platform.paragon - Done
16:38:42 
16:38:42 # Pulling files
16:38:42 
16:38:42 edx-platform.paragon [ar] - Pulling file
16:38:42 edx-platform.paragon [ca] - Pulling file
16:38:42 edx-platform.paragon [fr] - Pulling file
16:38:42 edx-platform.paragon [es_419] - Pulling file
16:38:42 edx-platform.paragon [he] - Pulling file
16:38:42 edx-platform.paragon [ar] - Creating download job
16:38:42 edx-platform.paragon [es_419] - Creating download job
16:38:42 edx-platform.paragon [ca] - Creating download job
16:38:42 edx-platform.paragon [he] - Creating download job
16:38:42 edx-platform.paragon [fr] - Creating download job
16:38:43 edx-platform.paragon [es_419] - Done
16:38:43 edx-platform.paragon [id] - Pulling file
16:38:43 edx-platform.paragon [id] - Creating download job
16:38:43 edx-platform.paragon [fr] - Done
16:38:43 edx-platform.paragon [ko_KR] - Pulling file
16:38:43 edx-platform.paragon [ko_KR] - Creating download job
16:38:43 edx-platform.paragon [he] - Done
16:38:43 edx-platform.paragon [pl] - Pulling file
16:38:43 edx-platform.paragon [pl] - Creating download job
16:38:43 edx-platform.paragon [ar] - Done
16:38:43 edx-platform.paragon [pt_BR] - Pulling file
16:38:43 edx-platform.paragon [pt_BR] - Creating download job
16:38:43 edx-platform.paragon [id] - Done
16:38:43 edx-platform.paragon [ru] - Pulling file
16:38:43 edx-platform.paragon [ru] - Creating download job
16:38:43 edx-platform.paragon [ca] - Done
16:38:43 edx-platform.paragon [th] - Pulling file
16:38:43 edx-platform.paragon [th] - Creating download job
16:38:43 edx-platform.paragon [ko_KR] - Done
16:38:43 edx-platform.paragon [uk] - Pulling file
16:38:43 edx-platform.paragon [uk] - Creating download job
16:38:44 edx-platform.paragon [ru] - Done
16:38:44 edx-platform.paragon [zh_CN] - Pulling file
16:38:44 edx-platform.paragon [zh_CN] - Creating download job
16:38:44 edx-platform.paragon [pt_BR] - Done
16:38:44 edx-platform.paragon [uk] - Done
16:38:46 edx-platform.paragon [pl] - Done
16:38:46 edx-platform.paragon [zh_CN] - Done
16:38:46 edx-platform.paragon [th] - Done
16:38:46 # compile files with translated strings to KEYVALUEJSON format which react-intl understands...
16:38:46 npm run-script i18n_compile
16:38:46 
16:38:46 > @edx/[email protected] i18n_compile /edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon
16:38:46 > formatjs compile-folder --format transifex ./src/i18n/messages ./src/i18n/messages
16:38:46 
16:38:47 [@formatjs/cli] [WARN] Error validating message "El tipo de archivo debe ser {count, plural, one {{typeString} archivo} otro {one of {typeString} files}}." with ID "dropzone.Dropzone.invalidType" in file "./src/i18n/messages/es_419.json"
16:38:47 SyntaxError: MISSING_OTHER_CLAUSE
16:38:47     at parse5 (/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/@formatjs/cli/bin/formatjs:147987:21)
16:38:47     at compile7 (/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/@formatjs/cli/bin/formatjs:149646:67)
16:38:47     at async Promise.all (index 2)
16:38:47     at async compileFolder (/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/@formatjs/cli/bin/formatjs:149706:19)
16:38:47     at async Command.<anonymous> (/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/paragon/node_modules/@formatjs/cli/bin/formatjs:155030:5)
16:38:47 npm ERR! code ELIFECYCLE
16:38:47 npm ERR! errno 1
16:38:47 npm ERR! @edx/[email protected] i18n_compile: `formatjs compile-folder --format transifex ./src/i18n/messages ./src/i18n/messages`
16:38:47 npm ERR! Exit status 1
16:38:47 npm ERR! 
16:38:47 npm ERR! Failed at the @edx/[email protected] i18n_compile script.
16:38:47 npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
16:38:47 
16:38:47 npm ERR! A complete log of this run can be found in:
16:38:47 npm ERR!     /edx/var/jenkins/.npm/_logs/2022-08-07T20_38_47_387Z-debug.log
16:38:47 Makefile:51: recipe for target 'pull_translations' failed
16:38:47 make: *** [pull_translations] Error 1
16:38:48 Traceback (most recent call last):
16:38:48   File "transifex/pull.py", line 120, in <module>
16:38:48     pull(
16:38:48   File "transifex/pull.py", line 62, in pull
16:38:48     repo.pull_translations()
16:38:48   File "/edx/var/jenkins/jobs/translations/jobs/paragon-pull_translations/workspace/ecommerce-scripts/transifex/utils.py", line 192, in pull_translations
16:38:48     subprocess.run(['make', 'pull_translations'], check=True)
16:38:48   File "/usr/lib/python3.8/subprocess.py", line 512, in run
16:38:48     raise CalledProcessError(retcode, process.args,
16:38:48 subprocess.CalledProcessError: Command '['make', 'pull_translations']' returned non-zero exit status 2.
16:38:48 Build step 'Execute shell' marked build as failure
16:38:48 Archiving artifacts
16:38:48 Sending e-mails to: [email protected]
16:38:49 Finished: FAILURE

adamstankiewicz avatar Aug 12 '22 11:08 adamstankiewicz