8000 Fix create issue script by sofide · Pull Request #2876 · python/python-docs-es · GitHub
[go: up one dir, main page]

Skip to content

Fix create issue script #2876

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

Merged
merged 9 commits into from
Nov 21, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
improve readability in check_translation_is_pending
  • Loading branch information
sofide committed Nov 21, 2024
commit 9461867ba21199c762498f2fe9281b3c06778f14
9 changes: 5 additions & 4 deletions scripts/create_issue.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,11 @@ def check_issue_not_already_existing(self, pofilename):

@staticmethod
def check_translation_is_pending(pofile):
if pofile.fuzzy == 0 and any([
pofile.translated == pofile.entries,
pofile.untranslated == 0,
]):
no_fuzzy_translations = pofile.fuzzy == 0
translated_match_all_entries = pofile.translated == pofile.entries
no_untranslated_entries_left = pofile.untranslated == 0

if no_fuzzy_translations and (translated_match_all_entries or no_untranslated_entries_left):
print(f'Skipping {pofile.filename}. The file is 100% translated already.')
raise PoFileAlreadyTranslated

Expand Down
0