-
-
Notifications
You must be signed in to change notification settings - Fork 959
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
i18next plural form missing in Json response #7540
Comments
If you want to create plural string, use the API directly - pass |
Thank you for your reply. But creating plural forms works as expected. But when requesting the translations by using the rest api with the query parameter |
This issue looks more like a support question than an issue. We strive to answer these reasonably fast, but purchasing the support subscription is not only more responsible and faster for your business but also makes Weblate stronger. In case your question is already answered, making a donation is the right way to say thank you! |
The plain JSON format does not support plurals, see https://docs.weblate.org/en/latest/formats.html#translation-types-capabilities |
This issue has been automatically marked as stale because there wasn’t any recent activity. It will be closed soon if no further action occurs. Thank you for your contributions! |
Describe the issue
Hi,
I am using i18next format for my translations and pluralizations. I added some translation keys for pluralizations. Always one without suffix and one with the
_plural
suffix. I am updating the translations by using the REST API.Pushing the translations works as expected.
Also the UI shows the translation inputs as correct, for language
de
always one input for singular and one for plural in one form.I am using the REST API for pulling the translations and now some unexpected behavior appears.
When I am trying to fetch the Json file with
get
tohttps://some-base-url.com/api/translations/component-123/app/de/file/
the_plural
translations do exist in response. But when I am using theformat=json
parameter for the dotted notation the_plural
field is missing.Maybe I am doing something wrong?
Thank you for your help. BR Philipp
I already tried
Steps to reproduce the behavior
plural
translation keys by using REST APIformat=json
_plural
field is missing in response.Expected behavior
A Json response with the existing plural-form
Screenshots
No response
Exception traceback
No response
How do you run Weblate?
Docker container
Weblate versions
Weblate 4.11.2 Django 4.0.3 siphashc 2.1 translate-toolkit 3.6.0 lxml 4.7.1 Pillow 9.0.1 bleach 4.1.0 python-dateutil 2.8.2 social-auth-core 4.2.0 social-auth-app-django 5.0.0 django-crispy-forms 1.14.0 oauthlib 3.2.0 django-compressor 3.1 djangorestframework 3.13.1 django-filter 21.1 django-appconf 1.0.5 user-agents 2.2.0 filelock 3.6.0 jellyfish 0.9.0 openpyxl 3.0.9 celery 5.2.3 kombu 5.2.3 translation-finder 2.12 weblate-language-data 2022.2 html2text 2020.1.16 pycairo 1.20.1 pygobject 3.42.0 diff-match-patch 20200713 requests 2.27.1 django-redis 5.2.0 hiredis 2.0.0 sentry_sdk 1.5.6 Cython 0.29.28 misaka 2.1.1 GitPython 3.1.27 borgbackup 1.2.0 pyparsing 3.0.7 pyahocorasick 1.4.4 python-redis-lock 3.7.0 charset-normalizer 2.0.12 Python 3.10.2 Git 2.30.2 psycopg2 2.9.3 psycopg2-binary 2.9.3 phply 1.2.5 ruamel.yaml 0.17.21 tesserocr 2.5.2 akismet 1.1 boto3 1.21.12 zeep 4.1.0 aeidon 1.10.1 iniparse 0.5 mysqlclient 2.1.0 Mercurial 6.1 git-svn 2.30.2 git-review 2.2.0 Redis server 6.2.5 PostgreSQL server 11.15
Weblate deploy checks
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: