Skip to content

deps: land safe Dependabot bumps; triage jni & gotatun#637

Merged
kasnder merged 1 commit into
masterfrom
claude/dependabot-safe-bumps
Jul 11, 2026
Merged

deps: land safe Dependabot bumps; triage jni & gotatun#637
kasnder merged 1 commit into
masterfrom
claude/dependabot-safe-bumps

Conversation

@kasnder

@kasnder kasnder commented Jul 11, 2026

Copy link
Copy Markdown
Member

Summary

Triage of the five open Dependabot PRs (#629, #630, #631, #632, #633). Each was investigated in an isolated worktree and its fix compiled + tested. This PR carries the three that are verified green and documents the two that need manual work (left as their own Dependabot PRs).

All five were red in CI. The common thread: four of them (#629#632) touch the shared Rust crate wgbridge-rs, and #633 was blocked by an unrelated compileSdk floor. None were safe to merge blind.

✅ Included in this PR (verified green)

#633 — gradle-minor-patch group (8 updates)

  • androidx.core:core-ktx 1.18.0 → 1.19.0
  • com.google.android.material 1.13.0 → 1.14.0
  • androidx.lifecycle 2.10.0 → 2.11.0
  • glide 5.0.7 → 5.0.9
  • okhttp 5.3.2 → 5.4.0
  • AGP 9.0.1 → 9.2.1, Gradle wrapper 9.2.1 → 9.6.1

Why CI failed: core-ktx:1.19.0 and glide:5.0.9 declare minCompileSdk=37 (confirmed from their AAR metadata), but the project was on compileSdk = 36, so :app:checkGithubDebugAarMetadata failed. AGP ≥9.1.0 is also required — the group's bump to 9.2.1 satisfies that.

Fix: bump compileSdk/targetSdk 36 → 37. Platform 37 is released and installed; SDK 38 is not needed (correcting an earlier assumption). targetSdk moved in lockstep with compileSdk, matching this file's existing convention — this is the one judgment call, since only compileSdk is strictly forced by the AAR metadata.

Verified: ./gradlew :app:assembleGithubDebug → BUILD SUCCESSFUL, including the native wgbridge-rs build via cargo-ndk.

Note: the checked-in gradlew/gradlew.bat/gradle-wrapper.jar bootstrap regen from Dependabot's diff is not included here — only distributionUrl was bumped. The old bootstrap correctly downloads and runs Gradle 9.6.1. If you prefer the full wrapper regen, take those files from #633.

#631 — android_logger 0.14 → 0.15

Not breaking for our single call site in jni_bindings.rs (Config::with_max_level/with_tag/init_once are unchanged in 0.15). Cargo.toml + lock only, no code change. Verified via cargo ndk arm64 cross-compile.

#630 — getrandom 0.2 → 0.3

0.3 renamed the free function getrandom::getrandom()getrandom::fill(). Updated the single call site in keys.rs (WireGuard private-key generation). getrandom 0.3.4 was already in the tree via gotatun → rand 0.9 → rand_core 0.9, so this adds no new version; 0.2.17 remains for ring/chacha20poly1305. Not blocked by any other dep. Verified cargo build + cargo test (18/18) + arm64 cross-compile.

⚠️ NOT included — need manual work (kept as separate Dependabot PRs)

#629 — jni 0.21 → 0.22 · fix exists, needs on-device test

jni 0.22 is a ground-up API redesign, not a signature tweak: JNIEnv split into EnvUnowned/Env (closure-based with_env upgrade + ErrorPolicy), closure-based thread attachment (attach_current_thread_permanently removed), GlobalRefGlobal<T>, call_method now takes compile-time jni_str!/jni_sig!, and jboolean changed from u8 to bool.

A full rewrite of jni_bindings.rs was produced that compiles cleanly for all four ABIs and preserves the exported FFI symbols (verified with llvm-nm against the Kotlin native declarations). But it changes runtime semantics (exception propagation via ThrowRuntimeExAndDefault, worker thread attach/detach lifecycle) on the most safety-critical FFI path. Recommendation: review + on-device test (tunnel start/stop, key gen, DNS recording) before merging. Too large for a rubber-stamp. The ready fix can be dropped in when someone can validate on a device.

#632 — gotatun 0.7.2 → 0.8.0 · defer / file upstream

Root cause: 0.8.0 made UdpSocket's inner an opaque enum (Socket / DisabledIpv6) to support IPv4-only fallback, and removed the public impl AsFd for UdpSocket. There is now no public API to obtain the raw fd that our code hands to Android's VpnService.protect(fd) — this is our loop-prevention / socket-protection path.

A workaround compiles (bind our own tokio::net::UdpSocket, protect it, implement gotatun's UdpSend/UdpRecv on it), but it swaps gotatun's optimized Linux datapath (sendmmsg/recvmmsg + UDP GRO) for per-packet send/recv — more syscalls/wakeups under load, which is a direct throughput and battery/radio-wakeup concern for this app. Recommendation: don't merge as-is. Preferred path: file an upstream request for a public fallible fd accessor (e.g. UdpSocket::as_raw_fd() -> Option<RawFd>) so the optimized datapath is retained, and defer #632 until then. gotatun also migrated internal logging logtracing (lock churn only) and added DeviceBuilder::suspended (additive).

Verification summary

PR Status Verification
#633 gradle group ✅ included assembleGithubDebug passes (incl. native build)
#631 android_logger ✅ included arm64 cross-compile clean
#630 getrandom ✅ included host build + 18/18 tests + arm64 cross-compile
#629 jni ⚠️ documented fix compiles 4 ABIs, FFI symbols match — needs on-device test
#632 gotatun ⚠️ documented workaround compiles but regresses UDP datapath — defer

Suggested follow-up

🤖 Generated with Claude Code

…ndom)

Consolidates the three Dependabot updates that are verified green, and
documents (in the PR) the two that need manual work.

#633 gradle-minor-patch group:
  - androidx.core:core-ktx 1.18.0 -> 1.19.0
  - com.google.android.material 1.13.0 -> 1.14.0
  - androidx.lifecycle 2.10.0 -> 2.11.0
  - glide 5.0.7 -> 5.0.9
  - okhttp 5.3.2 -> 5.4.0
  - AGP 9.0.1 -> 9.2.1, Gradle wrapper 9.2.1 -> 9.6.1
  core-ktx 1.19.0 and glide 5.0.9 ship minCompileSdk=37, so bump
  compileSdk/targetSdk 36 -> 37 (platform 37 is released/installed;
  no SDK 38 needed). Verified: ./gradlew :app:assembleGithubDebug passes,
  including the native wgbridge-rs build.

#631 android_logger 0.14 -> 0.15: no API change for our call site
  (with_max_level/with_tag/init_once unchanged). Cargo.toml only.

#630 getrandom 0.2 -> 0.3: renamed free fn getrandom() -> fill(); update
  the single call site in keys.rs. getrandom 0.3.4 was already in the tree
  via gotatun's rand 0.9 path, so this adds no new version.

Verified: cargo build + cargo test (18/18) on host, and cargo ndk arm64
cross-compile of the combined tree.

Not included (need manual work, see PR body):
  - #629 jni 0.21 -> 0.22: compiles only after a full FFI-layer rewrite;
    needs on-device testing.
  - #632 gotatun 0.7.2 -> 0.8.0: removes the public AsFd on UdpSocket used
    for VpnService.protect(); workaround regresses the optimized UDP
    datapath. Defer / file upstream for a public fd accessor.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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