Skip to content

fix(deps): bump ffi-rs to 1.3.7 to fix Android arm64 startup crash - #44856

Open
noah1510 wants to merge 1 commit into
pingdotgg:mainfrom
noah1510:fix/bump-ffi-rs-1.3.7
Open

noah1510 wants to merge 1 commit into
pingdotgg:mainfrom
noah1510:fix/bump-ffi-rs-1.3.7

Conversation

@noah1510

Copy link
Copy Markdown

Problem

On Android arm64 (Termux, Node v26.13.1), ffi-rs@1.3.2 fails to load at server startup with:

Error: dlopen failed: cannot locate symbol "__clear_cache" referenced by ".../ffi-rs.android-arm64.node"

This prevents @ff-labs/fff-node from loading at startup even though @ff-labs/fff-node@0.11.0 already ships @ff-labs/fff-bin-android-arm64.

Change

Bump ffi-rs from 1.3.2 to 1.3.7 across apps/server/package.json, apps/desktop/package.json, packages/shared/package.json, and pnpm-lock.yaml. Upstream ffi-rs@1.3.7 fixes the Android arm64 build to link libclang_rt.builtins via the Android NDK, allowing @ff-labs/fff-node to load and index natively on Android/Termux.

Split out from #42200 so each fix is reviewed independently (see #42200 for the companion Android SELinux hardlink fallback; full native Termux setup also depends on upstream microsoft/node-pty#1019). Creating the fork, commits, and this PR were all done using T3 Code itself running inside Termux via t3 serve and controlled from the T3 Code Android app (the web UI was also tested and used to configure Antigravity).

Scope

Patch-level dependency bump (ffi-rs 1.3.2 -> 1.3.7) across the three workspace manifests that pin ffi-rs plus pnpm-lock.yaml, with no source code changes. No prior issue was filed because the failure is a straightforward missing-symbol crash on Android arm64 already fixed upstream in ffi-rs@1.3.7.

Verification

Verified directly on Android arm64 (Termux, Node v26.13.1, pnpm 12.14.0):

  • @ff-labs/fff-node@0.11.0 + ffi-rs@1.3.7 end-to-end: Ran FileFinder.create, waitForIndexReady(5000), and fileSearch("package.json") against the live apps/server checkout and in a clean temporary directory: returned fff-node ready: { ok: true, value: true } and fff-node search ok: true items: [ 'package.json' ] with no __clear_cache error.
  • Live T3 Code server on Android/Termux: Booted t3 serve directly with ffi-rs@1.3.7 (without any lazy-loading workaround in WorkspaceSearchIndex), controlled it from the T3 Code Android app, and tested the web UI directly.
  • Lockfile & formatting checks: pnpm install --lockfile-only --ignore-scripts passed pnpm's supply-chain policy check (2205 entries) with pnpm-lock.yaml diff strictly limited to ffi-rs and @yuuang/ffi-rs-* (1.3.2 -> 1.3.7); oxfmt --check passed on all 3 modified package.json files.
  • Could not run locally: vp (vite-plus) does not ship an android-arm64 native binding yet, so vp run check:changed relies on GitHub Actions CI.

Written with Gemini 4 Neon via Antigravity (running inside T3 Code on Android/Termux).

ffi-rs@1.3.2 fails to load on Android arm64 because its prebuilt binary references an undefined __clear_cache symbol, breaking @ff-labs/fff-node at startup.

Upgrade ffi-rs to 1.3.7 across apps/server, apps/desktop, packages/shared, and pnpm-lock.yaml so the Android arm64 native addon loads and indexes cleanly.

Co-authored-by: Antigravity (Gemini 4 Neon) <noreply@google.com>
@github-actions github-actions Bot added the vouch:unvouched Author is not yet trusted in the VOUCHED list. label Nov 28, 2026
@github-actions github-actions Bot added the size:L 100-499 changed lines (additions + deletions). label Nov 28, 2026
@coderabbitai

coderabbitai Bot commented Nov 28, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The ffi-rs dependency version changes from 1.3.2 to 1.3.7 in the desktop, server, and shared package manifests.

Changes: ffi-rs dependency update

Layer / File(s) Summary
Update ffi-rs versions
apps/desktop/package.json, apps/server/package.json, packages/shared/package.json
All three manifests update ffi-rs from version 1.3.2 to 1.3.7.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Bug fix

Possibly related PRs

  • pingdotgg/t3code#42200: Updates ffi-rs in the same manifests and includes an Android hardlink fallback not present in this pull request.

Suggested labels: bugfix

Suggested reviewers: juliusmarminge, yash-singh1, macroscopeapp

Merge Risk: Minimal · up to f2a02 · assessed changes only

Path filters excluded changed files. This rating applies only to the assessed changes.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: bumping ffi-rs from 1.3.2 to 1.3.7 to fix an Android arm64 startup crash. The title is specific, follows conventional commit form, and matches the manifest changes in …
Description check Passed The description follows the template. It has Problem, Change, Scope, and Verification sections, and each section gives specific content. The Problem section states the error and environment. The Chang…
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.
Full details: Title check

Explanation

The title names the main change: bumping ffi-rs from 1.3.2 to 1.3.7 to fix an Android arm64 startup crash. The title is specific, follows conventional commit form, and matches the manifest changes in the summary and objectives.

Full details: Description check

Explanation

The description follows the template. It has Problem, Change, Scope, and Verification sections, and each section gives specific content. The Problem section states the error and environment. The Change section explains the ffi-rs bump and the files touched. The Scope section explains why no issue was filed and links the related PR #42200. The Verification section lists concrete checks with observed results and states what could not be run locally (vp check). The template asks for a model and harness line when an agent was used, and the author includes one. The Scope section does not link an issue that shows the bug, but it gives a reason for the omission, which the template allows for small fixes of an obvious bug.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 39d0e0f and f2a0256.

Files ignored due to path filters: 1

  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing: 3

  • apps/desktop/package.json
  • apps/server/package.json
  • packages/shared/package.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant