Skip to content

ci: stop updating .pot file, rely on Weblate doing it#2078

Open
amezin wants to merge 1 commit into
masterfrom
pot-weblate
Open

ci: stop updating .pot file, rely on Weblate doing it#2078
amezin wants to merge 1 commit into
masterfrom
pot-weblate

Conversation

@amezin

@amezin amezin commented Jul 21, 2026

Copy link
Copy Markdown
Member

No description provided.

@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

  • Bug Fixes

    • Improved translation change detection by comparing translation sources while ignoring non-functional metadata changes.
    • Simplified generation of translation catalog files and removed automatic copyright-year rewriting.
  • Documentation

    • Updated generated-file notices to clearly explain how to regenerate translation files.
  • Chores

    • Removed the automated pull request creation workflow.

Walkthrough

The pull-request composite action was removed. Translation generation headers and Meson gettext configuration were simplified, and CI now performs separate checks for POTFILES and translation files while ignoring volatile headers.

Changes

Translation pipeline

Layer / File(s) Summary
Translation generation and gettext build configuration
po/gen-potfiles.py, po/POTFILES.in, po/meson.build
Generated-file headers now identify the update command. Meson removes the copyright-holder argument and post-processing target wrapper.
CI translation diff checks and pull-request action removal
.github/workflows/ci.yml, .github/actions/pull-request/action.yml
CI separates POTFILES and translation diffs, ignores volatile headers, and no longer wires the removed pull-request action into this process.

Estimated code review effort: 2 (Simple) | ~15 minutes

🚥 Pre-merge checks | ✅ 3 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive No meaningful pull request description was provided, so the change context is not described. Add a short description summarizing the purpose and scope of the CI and .pot update changes.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title matches the main change: stopping .pot updates in CI and delegating that work to Weblate.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch pot-weblate

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@amezin
amezin marked this pull request as ready for review July 22, 2026 05:08

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/ci.yml:
- Around line 423-430: Update the “Diff translations” workflow step to remove
the po/*.pot pathspec, leaving the git diff check scoped only to po/*.po.
Preserve the existing ignored translation metadata lines and all other CI
behavior.
- Around line 423-430: Update the “Diff translations” workflow step to pass
--exit-code to git diff, ensuring differences in po/*.po or po/*.pot cause the
CI step to fail while preserving the existing ignored-line filters.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: d329a9a4-bffc-4b44-a18d-0957319db79f

📥 Commits

Reviewing files that changed from the base of the PR and between a8395c2 and 51d8be8.

📒 Files selected for processing (5)
  • .github/actions/pull-request/action.yml
  • .github/workflows/ci.yml
  • po/POTFILES.in
  • po/gen-potfiles.py
  • po/meson.build
💤 Files with no reviewable changes (1)
  • .github/actions/pull-request/action.yml
📜 Review details
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2026-03-08T15:48:59.252Z
Learnt from: amezin
Repo: ddterm/gnome-shell-extension-ddterm PR: 1801
File: .github/workflows/ci.yml:132-137
Timestamp: 2026-03-08T15:48:59.252Z
Learning: In CI workflows (e.g., .github/workflows/*.yml) avoid enforcing meson subprojects download in lint-like jobs if the typical developer workflow includes running meson setup, which downloads subprojects. Treat missing subproject downloads as a concern only for jobs that do not run meson setup (e.g., lint). If a workflow runs meson setup, do not flag lint entrypoints for missing subproject downloads.

Applied to files:

  • .github/workflows/ci.yml
📚 Learning: 2026-05-12T20:24:18.229Z
Learnt from: amezin
Repo: ddterm/gnome-shell-extension-ddterm PR: 1908
File: .github/workflows/ci.yml:309-326
Timestamp: 2026-05-12T20:24:18.229Z
Learning: In this repo’s CI workflows, assume the `meson dist` tarball includes all git-tracked files, including `.github/actions/`. After extracting the dist tarball in a CI job (e.g., `tar xvf ... --strip-components=1`), it is valid to reference local actions directly via `uses: ./.github/actions/<action>` without performing a separate `actions/checkout` step. When reviewing, ensure the workflow extracts the dist tarball before any `uses: ./.github/actions/...` and that the dist packaging indeed includes `.github/actions/`; if the dist output would omit it, require adding a checkout step or otherwise ensuring those action files are present.

Applied to files:

  • .github/workflows/ci.yml
🔇 Additional comments (4)
po/gen-potfiles.py (1)

61-61: LGTM!

po/POTFILES.in (1)

3-3: LGTM!

po/meson.build (1)

5-11: LGTM!

Also applies to: 25-25

.github/workflows/ci.yml (1)

411-414: LGTM!

Comment thread .github/workflows/ci.yml
Comment on lines +423 to +430
- name: Diff translations
run: >-
git diff
--color
'--ignore-matching-lines=^"POT-Creation-Date: '
'--ignore-matching-lines=^"Report-Msgid-Bugs-To: '
'po/*.po'
'po/*.pot'

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

Do not keep Weblate-owned POT files in this CI contract.

The pathspec still includes po/*.pot, so this job continues to treat generated POT output as CI-owned synchronization data, contrary to the PR objective. Scope this check to po/*.po and remove the POT update/check from this job.

Proposed pathspec change
           'po/*.po'
-          'po/*.pot'
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- name: Diff translations
run: >-
git diff
--color
'--ignore-matching-lines=^"POT-Creation-Date: '
'--ignore-matching-lines=^"Report-Msgid-Bugs-To: '
'po/*.po'
'po/*.pot'
- name: Diff translations
run: >-
git diff
--color
'--ignore-matching-lines=^"POT-Creation-Date: '
'--ignore-matching-lines=^"Report-Msgid-Bugs-To: '
'po/*.po'
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml around lines 423 - 430, Update the “Diff
translations” workflow step to remove the po/*.pot pathspec, leaving the git
diff check scoped only to po/*.po. Preserve the existing ignored translation
metadata lines and all other CI behavior.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Make this translation check fail on differences.

Unlike the POTFILES check, this git diff omits --exit-code, so .po/.pot changes are printed but the step still succeeds. Add --exit-code.

Proposed fix
           git diff
+          --exit-code
           --color
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- name: Diff translations
run: >-
git diff
--color
'--ignore-matching-lines=^"POT-Creation-Date: '
'--ignore-matching-lines=^"Report-Msgid-Bugs-To: '
'po/*.po'
'po/*.pot'
- name: Diff translations
run: >-
git diff
--exit-code
--color
'--ignore-matching-lines=^"POT-Creation-Date: '
'--ignore-matching-lines=^"Report-Msgid-Bugs-To: '
'po/*.po'
'po/*.pot'
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml around lines 423 - 430, Update the “Diff
translations” workflow step to pass --exit-code to git diff, ensuring
differences in po/*.po or po/*.pot cause the CI step to fail while preserving
the existing ignored-line filters.

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.

1 participant