choo121600 commented on code in PR #56180: URL: https://github.com/apache/airflow/pull/56180#discussion_r2385418414
########## dev/i18n/check_translations_completeness.py: ########## @@ -581,11 +614,87 @@ def natural_key_sort(obj): return obj lang_data = natural_key_sort(lang_data) - lang_path.parent.mkdir(parents=True, exist_ok=True) - with open(lang_path, "w", encoding="utf-8") as f: - json.dump(lang_data, f, ensure_ascii=False, indent=2) - f.write("\n") # Ensure newline at the end of the file - console.print(f"[green]Added missing translations to {lang_path}[/green]") + + if dry_run: + console.print(f"[blue][DRY RUN] Would add missing translations to {lang_path}[/blue]") + else: + lang_path.parent.mkdir(parents=True, exist_ok=True) + with open(lang_path, "w", encoding="utf-8") as f: + json.dump(lang_data, f, ensure_ascii=False, indent=2) + f.write("\n") # Ensure newline at the end of the file + console.print(f"[green]Added missing translations to {lang_path}[/green]") Review Comment: Thanks for the suggestion! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org