Skip to content
This repository was archived by the owner on Jan 6, 2026. It is now read-only.
This repository was archived by the owner on Jan 6, 2026. It is now read-only.

Bug: Concurrent workload still hangs on main (follow-up to #38) #45

@ElecTwix

Description

@ElecTwix

Hi Turso team — thanks for landing the fix referenced in #38. We pulled the latest main to verify, but unfortunately the concurrent workload still hangs on our end. We don’t have permission to reopen the closed issue, so we’re filing this follow-up.

Environment

Steps to Reproduce

  1. Pull the commit above and run ./build_lib.sh.
  2. Check out our fork branch with a regression test mirroring the original workload: https://github.com/ElecTwix/turso-go/tree/concurrency-hang-test
  3. Run:
    go test -run TestConcurrentWorkloadRespectsContextDeadline -v
    (The new test lives at concurrency_regression_test.go:1 on that branch.)

Observed Behavior

=== RUN   TestConcurrentWorkloadRespectsContextDeadline
    concurrency_regression_test.go:47: workload error: database error: database is locked
--- FAIL: TestConcurrentWorkloadRespectsContextDeadline (0.01s)
FAIL

The console still needs a 45 s watchdog to exit, so the workload never drains.

Diagnostics

  • With RUST_LOG=turso_go=trace TURSO_LOG_FILE=hang_trace.log, we see repeated "Busy error during statement execution".
  • Debug prints on the Go side show getTimeoutMs(ctx) returning ~30 000 ms for every Exec/Query, confirming the context deadline is being passed into stmtExec.
  • Despite the timeout being set, the Rust layer returns Busy immediately under concurrent writes, so the threads stay blocked.

Expected Behavior
The workload should complete (or time out via context cancellation) rather than looping on Busy.

Artifacts

Could you take another look? Let us know if there’s anything else we can collect.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions