Skip to content

Migration failed: "pq: unexpected transaction status idle" when running against CRBD #290

Description

@Hades32

when I run sql-migrate up --env=$SQL_ENV I get every time

Migration failed: pq: unexpected transaction status idle handling 20250929142901-some-migration.sql

The DB we're connecting to is a CockroachDB instance, which should be fully PostgreSQL compatible.

Isn't "idle" exactly the state we expect?

Our db config:

staging:
  dialect: postgres
  datasource: dbname=username sslmode=verify-full host=our-db-host.cockroachlabs.cloud port=26257 user=${CRDB_USER} password=${CRDB_PASSWORD} sslrootcert=staging.crt
  dir: migrations
  table: migrations

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions