Skip to content

Fix pg18 extra image CI failures by skipping tools/osmium build in update.sh#80

Open
sanak wants to merge 2 commits intopgRouting:masterfrom
sanak:fix-pg18-extra-osmium-build
Open

Fix pg18 extra image CI failures by skipping tools/osmium build in update.sh#80
sanak wants to merge 2 commits intopgRouting:masterfrom
sanak:fix-pg18-extra-osmium-build

Conversation

@sanak
Copy link
Copy Markdown
Member

@sanak sanak commented Apr 23, 2026

Fixes the regression introduced after #75 was merged.

Changes proposed in this pull request:

  • Fix update.sh to comment out the tools/osmium build block when
    the target Debian suite is trixie (pg18)
  • Regenerate 18-3.6-{3.7,3.8,4.0,develop,main}/extra/Dockerfile
    with the osmium build skipped

Background

PR #75 commit 9fe515a manually commented out the tools/osmium build
lines in each 18-3.6-*/extra/Dockerfile to work around the
libosmium2-dev C++ API incompatibility on Trixie:

However, update.sh (and extra/Dockerfile.template) were not updated
at the same time. The subsequent nightly "Update hashes and versions" PRs
(#76, #78) ran make update, which regenerated those files from the
unchanged template — silently reverting the comments and causing all
18-3.6-* extra image builds to fail.

This PR moves the osmium skip into update.sh itself, so make update
produces the correct output and the fix survives future regenerations.

Summary by CodeRabbit

  • Chores
    • Docker image build configuration updated across multiple release versions to disable compilation of a tool component, potentially reducing build time and image size.
    • Build automation script modified to consistently apply the updated compilation configuration.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 23, 2026

Walkthrough

The changes disable the compilation and installation of the osmium tools component across Docker builds in multiple branches and versions. The update.sh script is updated to comment out the osmium build step specifically for the trixie Debian suite during image generation.

Changes

Cohort / File(s) Summary
Osmium Tool Removal from Dockerfiles
18-3.6-3.7/extra/Dockerfile, 18-3.6-3.8/extra/Dockerfile, 18-3.6-4.0/extra/Dockerfile, 18-3.6-develop/extra/Dockerfile, 18-3.6-main/extra/Dockerfile
All Dockerfile versions have the cd ../tools/osmium build sequence (cmake configure, make compile, and make install) commented out, disabling osmium compilation in the Docker build pipeline.
Build Script Update
update.sh
Modified to automatically comment out the osmium build/install step (cd ../../tools/osmium and make install) in generated Dockerfiles for the trixie Debian suite.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 With a hop and a skip, we've tidied the build,
Osmium's step now silenced, as planned.
Five Dockerfiles quieted with comments so mild,
And update.sh guides us with surgical hand. 🏗️✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and specifically describes the main change: fixing pg18 extra image CI failures by skipping the tools/osmium build in update.sh.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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 and usage tips.

@sanak sanak self-assigned this Apr 23, 2026
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (2)
update.sh (2)

99-100: Flag this as a temporary workaround in a tracking issue.

The inline comment already references osm2pgrouting issue #323 — nice. Consider also opening (or linking) a repo-local issue so the workaround isn't forgotten once upstream fixes the libosmium2-dev C++ API compatibility, and the trixie branch in update.sh can be reverted.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@update.sh` around lines 99 - 100, Add a permanent, repo-local tracking issue
for this temporary workaround and link it from the inline comment in update.sh
so we don't forget to revert the trixie branch change later: create an issue in
the repository (title like "Temporary: skip tools/osmium build for trixie due to
libosmium2-dev C++ API incompatibility") that references upstream issue `#323` and
the pr/commit, include expected revert criteria and an owner; then update the
comment near the trixie/tools/osmium skip in update.sh to include the new local
issue number/URL, a TODO tag (e.g. TODO: TEMP_WORKAROUND), and a target/review
date or owner so the workaround can be tracked and removed when upstream is
fixed.

99-103: Approach is correct; consider also removing the now-unused libosmium2-dev install/purge for trixie.

Applying the skip at generation time (rather than in extra/Dockerfile.template) is the right call since bullseye (pg ≤ 17) still needs to build tools/osmium. The sed range is well-anchored (cd ../tools/osmium/ … first subsequent make install), idempotent (a second run won't match ^ \+\&\& on already-commented lines), and the linked tracking issue comment is helpful.

One optional follow-up: since tools/osmium is no longer built on trixie, libosmium2-dev is installed (line 15 of the generated Dockerfile) and then purged (line 41) for no reason. Not a correctness issue (same RUN layer, so no image bloat), but you could extend the trixie branch to also strip it for clarity.

Optional: also drop libosmium2-dev on trixie
         if [ "$suite" = "trixie" ]; then
             sed -i '/\&\& cd \.\.\/tools\/osmium\//,/\&\& make install/ s/^ \+\&\& /#  \&\& /' "$version/extra/Dockerfile"
+            sed -i '/libosmium2-dev/d' "$version/extra/Dockerfile"
         fi
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@update.sh` around lines 99 - 103, The trixie branch currently comments out
the tools/osmium build but leaves the libosmium2-dev install/purge steps in the
generated Dockerfile; update the if [ "$suite" = "trixie" ] block (the same
branch that runs the sed that comments out the osmium build) to also remove or
comment the lines that install and purge libosmium2-dev in
"$version/extra/Dockerfile" (match the install and purge commands by the literal
string "libosmium2-dev" and either delete them or prefix them with "# " so the
change is idempotent like the existing sed for the tools/osmium section).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@update.sh`:
- Around line 99-100: Add a permanent, repo-local tracking issue for this
temporary workaround and link it from the inline comment in update.sh so we
don't forget to revert the trixie branch change later: create an issue in the
repository (title like "Temporary: skip tools/osmium build for trixie due to
libosmium2-dev C++ API incompatibility") that references upstream issue `#323` and
the pr/commit, include expected revert criteria and an owner; then update the
comment near the trixie/tools/osmium skip in update.sh to include the new local
issue number/URL, a TODO tag (e.g. TODO: TEMP_WORKAROUND), and a target/review
date or owner so the workaround can be tracked and removed when upstream is
fixed.
- Around line 99-103: The trixie branch currently comments out the tools/osmium
build but leaves the libosmium2-dev install/purge steps in the generated
Dockerfile; update the if [ "$suite" = "trixie" ] block (the same branch that
runs the sed that comments out the osmium build) to also remove or comment the
lines that install and purge libosmium2-dev in "$version/extra/Dockerfile"
(match the install and purge commands by the literal string "libosmium2-dev" and
either delete them or prefix them with "# " so the change is idempotent like the
existing sed for the tools/osmium section).

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c79e2f89-7d5f-4a65-acb7-6bf38f2c812b

📥 Commits

Reviewing files that changed from the base of the PR and between d3578b4 and 3add4e3.

📒 Files selected for processing (6)
  • 18-3.6-3.7/extra/Dockerfile
  • 18-3.6-3.8/extra/Dockerfile
  • 18-3.6-4.0/extra/Dockerfile
  • 18-3.6-develop/extra/Dockerfile
  • 18-3.6-main/extra/Dockerfile
  • update.sh

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