Skip to content

Stop committing generated .mo files; build them with doit localize - #488

Merged
bcantoni merged 2 commits into
developmentfrom
jac/untrack-mo-files
Oct 27, 2026
Merged

bcantoni merged 2 commits into
developmentfrom
jac/untrack-mo-files

Conversation

@jacalata

Copy link
Copy Markdown
Contributor

Stops committing the generated .mo translation bundles. They are built from the .properties files by doit localize, and every PR that changed a string regenerated them, so open PRs conflict on them constantly.

  • Untrack the 11 tabcmd/locales/*/LC_MESSAGES/tabcmd.mo files and add tabcmd/locales/**/*.mo to .gitignore.
  • Run pip install .[localize] and doit localize before pip install . in run-tests, check-coverage, generate-metadata, run-e2-tests, package and publish-pypi, so the bundles exist for tests, python -m build and PyInstaller.
  • Add MANIFEST.in with recursive-include tabcmd/locales *.mo so the sdist carries the generated files.
  • Remove check-mo-freshness.yml, which has nothing left to check.
  • Update bin/i18n/README.md and contributing.md.

Open PRs that changed a .mo file need one more merge of development after this lands. The conflict is modify/delete and resolves with git rm on the .mo file.

The workflow edits can only be exercised in CI. Worth running Package-and-Upload from this branch to confirm the packaged binaries still ship translations.

🤖 Generated with Claude Code

The .mo bundles are generated from the .properties files, and every PR
that changed a string regenerated them, so they conflicted constantly.
Untrack them, ignore them, and run doit localize before building in CI
and packaging. Remove check-mo-freshness, which has nothing left to check.

Co-Authored-By: Claude Code <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 26, 2026 20:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

Untracking the .mo files left the LC_MESSAGES directories empty, and git does not
store empty directories, so doit localize failed on a fresh checkout.

Co-Authored-By: Claude Code <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 26, 2026 20:57

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

@github-actions

Copy link
Copy Markdown

Coverage

Coverage Report
FileStmtsMissCoverMissing
tabcmd
   __main__.py121212 0%
   _version.py111111 0%
   tabcmd.py151515 0%
   version.py1066 40%
tabcmd/commands
   commands.py101010 0%
   constants.py771818 77%
   server.py1351818 87%
tabcmd/commands/auth
   session.py3945050 87%
tabcmd/commands/datasources_and_workbooks
   datasources_and_workbooks_command.py1571818 89%
   datasources_workbooks_views_url_parser.py14255 96%
   delete_command.py702323 67%
   export_command.py1202525 79%
   get_url_command.py1274747 63%
   publish_command.py1341616 88%
   runschedule_command.py2177 67%
tabcmd/commands/extracts
   create_extracts_command.py4288 81%
   decrypt_extracts_command.py2722 93%
   delete_extracts_command.py3766 84%
   encrypt_extracts_command.py2722 93%
   extracts.py2022 90%
   reencrypt_extracts_command.py2722 93%
   refresh_extracts_command.py481010 79%
tabcmd/commands/group
   create_group_command.py2955 83%
   delete_group_command.py2722 93%
tabcmd/commands/project
   create_project_command.py4688 83%
   delete_project_command.py3544 89%
   publish_samples_command.py3044 87%
tabcmd/commands/site
   create_site_command.py3455 85%
   delete_site_command.py2722 93%
   edit_site_command.py661818 73%
   list_command.py771212 84%
   list_sites_command.py2922 93%
tabcmd/commands/user
   add_users_command.py2955 83%
   create_site_users.py581111 81%
   create_users_command.py5999 85%
   delete_site_users_command.py4355 88%
   user_data.py2223131 86%
tabcmd/execution
   _version.py222 0%
   global_options.py14788 95%
   localize.py671111 84%
   logger_config.py6066 90%
   tabcmd_controller.py4277 83%
TOTAL294647084% 

@bcantoni
bcantoni merged commit 687420b into development Oct 27, 2026
26 checks passed
@bcantoni
bcantoni deleted the jac/untrack-mo-files branch October 27, 2026 19:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants