feat(powersync): migrate vendor patches + add CI hooks - #1
Conversation
|
pr-review-lead (round 3): PR Review: Migrate all fn-cli vendor/powersync patches into forked SDKReviewed by: pr-code-reviewer, pr-principles-reviewer, pr-silent-failure-hunter, pr-test-analyzer, pr-comment-analyzer, pr-type-design-analyzer Critical Issues (0 found)None. All 9 patches are correct and faithfully applied. Important Issues (1 found)
Suggestions (4 found)
Test Coverage Notes
Strengths
Verdict: LGTM ✅All 9 patches are correct. The one important issue ( |
|
coder (round 4): Review Triage: feat(powersync) vendor patchesVerdict: Accepted — LGTM from pr-review-lead Actionable items addressed:
Non-blocking suggestions (deferred to follow-up):
|
- reqwest: disable default-features, add rustls to avoid openssl-sys on musl - db/pool: set busy_timeout on reader connections, store release sender directly in Reader lease - db: use BEGIN IMMEDIATE in complete_crud_items and streams checkpoint to prevent BUSY_SNAPSHOT - sync: scope writer in download event loop, use BEGIN IMMEDIATE in invoke_control and checkpoint complete - error: add From<io::Error> impl - http: only emit ConnectionEstablished on successful response - util: strip CRLF line endings in line_split with test 🍷 Generated with Lenos Assisted-by: MiniMax-M2.7-highspeed via Lenos <lenos@tta-lab.com>
80147c8 to
685c822
Compare
Summary
Part 1 — Vendor patches (migrated from fn-cli vendor/powersync):
default-features = falseandrustls(no openssl-sys on musl)release: Senderdirectly (eliminates pool unwrap in Drop)complete_crud_itemsand streams checkpoint (prevents BUSY_SNAPSHOT deadlocks)From<io::Error>impl forPowerSyncErrorConnectionEstablishedon successful HTTP response\r\n) line endings inLineSplitterwith testPart 2 — CI / hooks (mirrored from flicknote-cli):
.github/workflows/ci.yml: separate build and lint jobs with cargo cache.github/workflows/pr.yml: PR checks: fmt, clippy, tests, cargo-deny, OSV scandeny.toml: cargo-deny config for licenses/bans/advisorieslefthook.yml: lefthook config (fmt on pre-commit, clippy+deny on pre-push).hooks/: shell scripts for pre-commit and pre-push (fmt check / clippy + deny)Test plan
cargo build --all-features— passescargo test --all-features— 48 tests passcargo fmt --check— passescargo clippy --all-targets --all-features -- -D warnings— passescargo deny check— passes (only warnings: duplicates from cross-platform deps, advisory-not-detected for ignored advisory)native-tls,openssl-sys,hyper-tls,tokio-native-tlsPost-merge setup (one-time)
After merging, collaborators cloning the repo should run once:
(Alternatively, clone and
lefthook installif using lefthook.)🍷 Generated with Lenos