oxidecomputer / oxidecomputer/omicron
versions_have_idempotent_up test fails with "Failed to ROLLBACK failed transaction...there is no transaction in progress"
Open
@smklein is already working on this.
Since Dec 7, 2023.
Test Flake
- Dominant language
- Rust
- Stars
- 572
- Forks
- 97
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 96
Description
Test omicron-nexus::test_all integration_tests::schema::versions_have_idempotent_up failed with
thread 'integration_tests::schema::versions_have_idempotent_up' panicked at 'Failed to ROLLBACK failed transaction: Error { kind: Db, cause: Some(DbError { severity: "ERROR", parsed_severity: Some(Error), code: SqlState(Other("XXUUU")), message: "there is no transaction in progress", detail: None, hint: None, position: None, where_: None, schema: None, table: None, column: None, datatype: None, constraint: None, file: Some("exec_util.go"), line: Some(741), routine: Some("init") }) }', nexus/tests/integration_tests/schema.rs:96:22
From @davepacheco:
- looks like we executed
BEGIN;and the update SQL, thenCOMMIT; - the first two succeeded (or we would have panicked)
- the
COMMIT;failed and CockroachDB reportsrestart transaction: TransactionRetryWithProtoRefreshError: TransactionRetryError: retry txn (RETRY_SERIALIZABLE) - apply_update_as_transaction then issues a ROLLBACK; but that fails because the transaction is no longer in progress
- so we panic
It's not clear to me why we'd ever expect to get a serializeable error here or what the logic here is trying to do in terms of retrying (or why it's issuing a rollback, since the only that can have failed here is the commit
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.