Skip to content
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

New translation for SRT file has all the strings marked as "translated" #8215

Closed
2 tasks done
jerzy-dudzic opened this issue Oct 14, 2022 · 1 comment
Closed
2 tasks done
Assignees
Labels
enhancement Adding or requesting a new feature.
Milestone

Comments

@jerzy-dudzic
Copy link

Describe the issue

Hello,

I have a problem with SRT files translations. Let's say I have a source SRT file in Polish. When I create another translation, for instance English, all units in English translation are being set automatically to "translated" state:
obraz

All those units in English translation have a copy of Polish units:
obraz

It happens both when doing it through the API or a website.

Eventually I need to trigger a machine translation for those SRT files. I can't do that in a straightforward way because in this case, the only filter that triggers autotranslation is 'filter_type' => 'all'.

On a side note, I do exactly the same with HTML files, which work fine. That is units in new translations have needs-editing state. I can easily trigger autotranslation for those.

Thank you in advance for your help,
Jerzy

I already tried

  • I've read and searched the documentation.
  • I've searched for similar issues in this repository.

Steps to reproduce the behavior

  1. Create a project
  2. Create a new Component and fill in a "Translate document" tab - add an example .srt file and select correct source language
  3. Choose "SubRip subtitle file" on the next screen
  4. Use pre-filled settings on the next screen - just press "Save"
  5. Go to newly created Component
  6. Click "Start new translation", choose any language, save
  7. Check that all the units in a new translation have "Translated strings" label

Expected behavior

New translations for SRT file based components should have all units with needs-editing state

Screenshots

New translation of a SRT component:
obraz

New translation of a HTML component:
obraz

Exception traceback

No response

How do you run Weblate?

Docker container

Weblate versions

  • Weblate: 4.14.1
  • Django: 4.1.1
  • siphashc: 2.1
  • translate-toolkit: 3.7.3
  • lxml: 4.9.1
  • Pillow: 9.2.0
  • bleach: 5.0.1
  • python-dateutil: 2.8.2
  • social-auth-core: 4.3.0
  • social-auth-app-django: 5.0.0
  • django-crispy-forms: 1.14.0
  • oauthlib: 3.2.1
  • django-compressor: 4.1
  • djangorestframework: 3.13.1
  • django-filter: 22.1
  • django-appconf: 1.0.5
  • user-agents: 2.2.0
  • filelock: 3.8.0
  • rapidfuzz: 2.8.0
  • openpyxl: 3.0.10
  • celery: 5.2.7
  • kombu: 5.2.4
  • translation-finder: 2.14
  • weblate-language-data: 2022.7
  • html2text: 2020.1.16
  • pycairo: 1.21.0
  • pygobject: 3.42.2
  • diff-match-patch: 20200713
  • requests: 2.28.1
  • django-redis: 5.2.0
  • hiredis: 2.0.0
  • sentry_sdk: 1.9.8
  • Cython: 0.29.32
  • misaka: 2.1.1
  • GitPython: 3.1.27
  • borgbackup: 1.2.2
  • pyparsing: 3.0.9
  • pyahocorasick: 1.4.4
  • python-redis-lock: 3.7.0
  • charset-normalizer: 2.1.1
  • Python: 3.10.7
  • 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
  • boto3: 1.24.73
  • zeep: 4.1.0
  • aeidon: 1.11
  • iniparse: 0.5
  • mysqlclient: 2.1.1
  • Mercurial: 6.2.2
  • git-svn: 2.30.2
  • git-review: 2.3.1
  • Redis server: 6.2.7
  • PostgreSQL server: 14.5
  • Database backends: django.db.backends.postgresql
  • Cache backends: default:RedisCache, avatar:FileBasedCache
  • Email setup: django.core.mail.backends.smtp.EmailBackend: smtp.eu.mailgun.org
  • OS encoding: filesystem=utf-8, default=utf-8
  • Celery: redis://cache:6379/1, redis://cache:6379/1, regular
  • Platform: Linux 5.15.0-1019-aws (x86_64)

Weblate deploy checks

System check identified some issues:

INFOS:
?: (weblate.I021) Error collection is not set up, it is highly recommended for production use
	HINT: https://docs.weblate.org/en/weblate-4.14.1/admin/install.html#collecting-errors
?: (weblate.I028) Backups are not configured, it is highly recommended for production use
	HINT: https://docs.weblate.org/en/weblate-4.14.1/admin/backup.html

System check identified 2 issues (1 silenced).

Additional context

No response

@nijel nijel self-assigned this Oct 17, 2022
@nijel nijel added the enhancement Adding or requesting a new feature. label Oct 17, 2022
@nijel nijel added this to the 4.14.2 milestone Oct 17, 2022
@nijel nijel closed this as completed in b0e7814 Oct 17, 2022
@github-actions
Copy link

Thank you for your report; the issue you have reported has just been fixed.

  • In case you see a problem with the fix, please comment on this issue.
  • In case you see a similar problem, please open a separate issue.
  • If you are happy with the outcome, don’t hesitate to support Weblate by making a donation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Adding or requesting a new feature.
Projects
None yet
Development

No branches or pull requests

2 participants