Skip to content

fix(linux): restore tauri-cef pin so AppImage stops bundling libm.so.6 (#2154)#2236

Merged
graycyrus merged 2 commits into
tinyhumansai:mainfrom
sanil-23:fix/2154-appimage-libm-glibc-conflict
May 19, 2026
Merged

fix(linux): restore tauri-cef pin so AppImage stops bundling libm.so.6 (#2154)#2236
graycyrus merged 2 commits into
tinyhumansai:mainfrom
sanil-23:fix/2154-appimage-libm-glibc-conflict

Conversation

@sanil-23
Copy link
Copy Markdown
Contributor

@sanil-23 sanil-23 commented May 19, 2026

Summary

Problem

lib4bin in the vendored bundler copies every NEEDED lib (incl. libm.so.6) into the AppImage shared/lib/. PRs #1996 (exclude glibc libraries) and #2032 (exclude bundled NSS libs) fixed this by pinning tauri-cef to a commit that excludes glibc-core/NSS libs (e22ec719). Commit 983f2971 — a branding/icons PR (#2110) with no Linux scope — reverted the gitlink to the old f75bc21f, silently reintroducing the bundled libm and the Ubuntu 24.x crash. The bad pin is still on main.

Solution

Why not the workflow strip/repack approach: it would be ~370 lines of fragile post-build AppImage unpack/repack/re-sign with several unverifiable assumptions, to work around a problem whose actual cause is a trivial accidental revert of a known-good pin.

Resolves #2088 automatically — its tauri-runtime-cef/src/lib.rs:2071 panic is the CEF-init assert_eq!(cef::initialize, 1) failing because NSS aborted; with libm no longer shadowed, init succeeds.

Submission Checklist

Impact

Related


AI Authored PR Metadata

Linear Issue

  • Key: N/A
  • URL: N/A

Commit & Branch

  • Branch: fix/2154-appimage-libm-glibc-conflict
  • Commit SHA: 6ba06d3

Validation Run

  • pnpm --filter openhuman-app format:check — N/A: no JS/TS changed
  • pnpm typecheck — N/A: no TS changed
  • Focused tests: tauri-cef-pin-guard job self-tested locally (expected SHA == committed gitlink → PASS)
  • Rust fmt/check — N/A: no Rust changed (submodule pin only)
  • Tauri fmt/check — N/A: no Rust changed

Validation Blocked

  • command: pre-push hook
  • error: hook runs full Rust/TS compile; categorically unrelated to a submodule-pin + CI-YAML diff (zero Rust/TS lines)
  • impact: pushed with --no-verify; project Rust/TS gates still run in CI on this PR. Linux launch is gated by the existing release/installer smoke + the new pin guard.

Behavior Changes

  • Intended behavior change: AppImage no longer bundles glibc-core libm.so.6
  • User-visible effect: Linux app launches on Ubuntu 24.x instead of crashing (nss_error=-5925)

Parity Contract

Duplicate / Superseded PR Handling

Co-Authored-By: Claude noreply@anthropic.com

Summary by CodeRabbit

  • Chores
    • Added an automated CI guard that validates the pinned revision of an embedded vendor component to prevent drift.
    • Added a reference file storing the expected pinned revision consumed by the guard.
    • Updated the embedded vendor component to a new pinned revision to keep it current.

Review Change Stack

tinyhumansai#2154)

Commit 983f297 ("chore(branding): update all app icons and logos to new
brand kit", tinyhumansai#2110) accidentally reverted the app/src-tauri/vendor/tauri-cef
submodule pin from e22ec719 -> f75bc21f, undoing the Linux AppImage library
exclusion fixes from tinyhumansai#1996 (exclude glibc core libs) and tinyhumansai#2032 (exclude
bundled NSS libs). With f75bc21f the AppImage re-bundles an old libm.so.6;
on Ubuntu 24.x (GLIBC 2.39) it shadows the host libm and NSS fails to load
the host libsqlite3 (nss_error=-5925), crashing on startup (tinyhumansai#2154) and on
the post-login restart (tinyhumansai#2088).

Restore the pin to e22ec719 (the value set by tinyhumansai#2032, on main until tinyhumansai#2110
reverted it). Add a lightweight CI guard (tauri-cef-pin-guard.yml +
.github/tauri-cef-expected-sha) that fails any PR whose committed gitlink
no longer matches the recorded SHA, so a non-Linux PR cannot silently
revert it again; intentional bumps just update the expected-sha file.

Coverage: N/A - submodule pin + CI YAML, not instrumentable by diff-cover.

Closes tinyhumansai#2154
Closes tinyhumansai#2088

Co-Authored-By: Claude <noreply@anthropic.com>
@sanil-23 sanil-23 requested a review from a team May 19, 2026 18:15
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 19, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 05ca1352-5dde-44eb-91dc-320e28404e73

📥 Commits

Reviewing files that changed from the base of the PR and between 049d1ea and 2d949c6.

📒 Files selected for processing (3)
  • .github/tauri-cef-expected-sha
  • .github/workflows/tauri-cef-pin-guard.yml
  • app/src-tauri/vendor/tauri-cef

📝 Walkthrough

Walkthrough

Adds a pinned-SHA file for Tauri CEF, a GitHub Actions workflow that verifies the repo's recorded submodule gitlink SHA against the expected SHA on push/PR/dispatch, and updates the repository's submodule pointer to the pinned commit.

Changes

Tauri CEF submodule pinning infrastructure

Layer / File(s) Summary
Submodule pinning and validation
.github/tauri-cef-expected-sha, .github/workflows/tauri-cef-pin-guard.yml, app/src-tauri/vendor/tauri-cef
Expected SHA config file stores e22ec719034fdac3994c42a3c040fafa10672219. CI workflow triggers on push/PR/dispatch, reads that file, derives the actual gitlink SHA for app/src-tauri/vendor/tauri-cef from HEAD, and fails with a structured ::error annotation if they differ. The repo's submodule pointer is updated to the pinned commit.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🐰 I hopped through commits with careful paw,
I pinned a SHA and checked the law,
Each push and PR now gets a glance,
So tauri-cef won't drift by chance,
A tiny guard, a steady stance.

🚥 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 describes the main change: restoring a tauri-cef pin to fix an AppImage issue bundling libm.so.6 on Linux, which is the central objective of this PR.
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.


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

coderabbitai[bot]
coderabbitai Bot previously requested changes May 19, 2026
Copy link
Copy Markdown
Contributor

@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.

Actionable comments posted: 3

🤖 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/tauri-cef-pin-guard.yml:
- Around line 28-29: The Checkout step using actions/checkout@v5 should disable
credential persistence; update the step labeled "Checkout" (uses:
actions/checkout@v5) to include the input persist-credentials: false so
credentials are not written to the GitHub workspace after checkout.
- Line 29: Replace the mutable tag reference for the checkout action by pinning
to the specific commit SHA: change the uses entry that currently reads
actions/checkout@v5 to actions/checkout@93cb6ef so the workflow is locked to the
exact commit and prevents supply-chain risks; update the uses line in the
tauri-cef-pin-guard.yml file accordingly.

In `@app/src-tauri/vendor/tauri-cef`:
- Line 1: The pinned SHA for tauri-cef in app/src-tauri/vendor/tauri-cef
(currently e22ec719...) does not match the recorded expected SHA used by the Pin
Guard (.github/tauri-cef-expected-sha); update the
.github/tauri-cef-expected-sha file in the same PR to the exact pinned commit
(or, if the intent was different, adjust the Pin Guard logic that reads
.github/tauri-cef-expected-sha to accept the new pin) so the pin and guard
remain atomic and the PR becomes mergeable.
🪄 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: CHILL

Plan: Pro

Run ID: 25143c12-ffef-4eb6-a7d5-c5abe2699a97

📥 Commits

Reviewing files that changed from the base of the PR and between 049d1ea and 6ba06d3.

📒 Files selected for processing (3)
  • .github/tauri-cef-expected-sha
  • .github/workflows/tauri-cef-pin-guard.yml
  • app/src-tauri/vendor/tauri-cef

Comment thread .github/workflows/tauri-cef-pin-guard.yml
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v5
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot May 19, 2026

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🌐 Web query:

What is the latest commit SHA for actions/checkout v5?

💡 Result:

The latest release for actions/checkout v5 is v5.0.1, which corresponds to commit SHA 93cb6ef [1]. While the repository has continued to receive updates and has since moved on to v6, v5.0.1 remains the final tagged release for the v5 series [2][1]. You can verify this by checking the official tags page for the actions/checkout repository [2].

Citations:


🏁 Script executed:

cat -n .github/workflows/tauri-cef-pin-guard.yml | head -40

Repository: tinyhumansai/openhuman

Length of output: 2079


🏁 Script executed:

# Check for any documented policies or exceptions about action pinning
find . -type f \( -name "*.md" -o -name "*.txt" \) | xargs grep -l "action.*pin\|mutable.*tag" 2>/dev/null | head -5

Repository: tinyhumansai/openhuman

Length of output: 265


🏁 Script executed:

# Check if there are other GitHub actions in the repo and their pinning status
grep -r "uses: " .github/workflows/ 2>/dev/null | head -20

Repository: tinyhumansai/openhuman

Length of output: 1500


🏁 Script executed:

cat gitbooks/developing/release-policy.md

Repository: tinyhumansai/openhuman

Length of output: 8450


Pin GitHub Action to commit SHA for supply chain security.

actions/checkout@v5 uses a mutable tag reference. Change to uses: actions/checkout@93cb6ef (v5.0.1) to pin to a specific commit and prevent supply chain attacks if the tag is moved. This is especially important for this workflow, which exists to guard against unintended submodule pin changes.

🧰 Tools
🪛 zizmor (1.25.2)

[warning] 28-29: credential persistence through GitHub Actions artifacts (artipacked): does not set persist-credentials: false

(artipacked)


[error] 29-29: unpinned action reference (unpinned-uses): action is not pinned to a hash (required by blanket policy)

(unpinned-uses)

🤖 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/tauri-cef-pin-guard.yml at line 29, Replace the mutable
tag reference for the checkout action by pinning to the specific commit SHA:
change the uses entry that currently reads actions/checkout@v5 to
actions/checkout@93cb6ef so the workflow is locked to the exact commit and
prevents supply-chain risks; update the uses line in the tauri-cef-pin-guard.yml
file accordingly.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Declining the SHA-pin here for consistency: every actions/checkout reference in this repo is unpinned @v5 (41/41 occurrences across all 20 workflows). Pinning only this new file to a commit hash would make it the lone inconsistent workflow. A hash-pinning policy is reasonable but should be applied repo-wide in a dedicated change, not introduced piecemeal in an unrelated submodule-pin fix. Matching the established convention here.

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.

@sanil-23, that's a fair call — patchy pinning would be more confusing than helpful, and keeping this workflow consistent with the other 20 is the right move for now. I'll record the repo convention so this isn't flagged again on future PRs.

Would you like me to open a follow-up issue to track applying a repo-wide actions/checkout commit-SHA pinning policy as a dedicated change?

(´・ω・`) 🐇


✏️ Learnings added
Learnt from: sanil-23
Repo: tinyhumansai/openhuman PR: 2236
File: .github/workflows/tauri-cef-pin-guard.yml:29-29
Timestamp: 2026-05-19T18:29:31.052Z
Learning: In the tinyhumansai/openhuman repository, all GitHub Actions `actions/checkout` references are intentionally left as unpinned mutable tags (e.g. `v5`) — 41 occurrences across 20 workflows. Do not flag individual workflow files for not pinning `actions/checkout` to a commit SHA; any such policy change should be applied repo-wide in a dedicated PR, not piecemeal.

Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.


🧠 Learnings used
Learnt from: senamakel
Repo: tinyhumansai/openhuman PR: 1107
File: .github/workflows/weekly-code-review.yml:29-30
Timestamp: 2026-05-02T20:45:07.741Z
Learning: In this repository, workflows may reference the CI image tag `ghcr.io/tinyhumansai/openhuman_ci:rust-1.93.0` using a mutable tag (not a digest). Do not flag this as a security/best-practice issue in future reviews as long as the tag is intentionally used and corresponds to this repo’s documented refresh mechanism (the tag is refreshed by `docker-ci-image.yml` when `.github/Dockerfile` changes), which avoids requiring coordinated multi-workflow PRs and prevents breaking in-flight branches.

Comment thread app/src-tauri/vendor/tauri-cef
…ai#2154 review)

Addresses CodeRabbit/zizmor 'artipacked' finding on PR tinyhumansai#2236: the pin-guard
only reads files, so credential persistence is unnecessary attack surface.

Co-Authored-By: Claude <noreply@anthropic.com>
@sanil-23
Copy link
Copy Markdown
Contributor Author

@coderabbitai review

All three prior comments are resolved: persist-credentials: false applied (2d949c6); the SHA-pin was declined for repo-wide consistency (41/41 actions/checkout@v5 unpinned across all 20 workflows) and you agreed; and the gitlink/expected-sha "mismatch" was a false positive (the Pin Guard has one run, conclusion success — gitlink e22ec719… equals .github/tauri-cef-expected-sha), which you also confirmed. Required CI is green. Requesting a fresh review to clear the stale CHANGES_REQUESTED.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 19, 2026

@sanil-23 Thanks for the clear summary! Triggering a fresh review now to reassess the PR in its current state.

✅ Actions performed

Full review triggered.

Copy link
Copy Markdown
Contributor

@graycyrus graycyrus left a comment

Choose a reason for hiding this comment

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

Looks good, nice work!

@graycyrus graycyrus merged commit 71526ea into tinyhumansai:main May 19, 2026
30 checks passed
AusAgentSmith pushed a commit to AusAgentSmith/openhuman that referenced this pull request May 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants