You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Furthermore, there appears to be discrepancy between how db:migrate lists pending migrations and how it's checked in db:migrate:status and db:setup as, unlike db:migrate they can see the pending migration:
$ rails db:migrate:status
database: storage/development2.sqlite3
Status Migration ID Migration Name
--------------------------------------------------
down 20240507134124 Create dogs
$ rails db:setup
Database 'storage/development2.sqlite3' already exists
Database 'storage/test.sqlite3' already exists
Database 'storage/test2.sqlite3' already exists
You have 1 pending migration:
20240507134124 CreateDogs
Run `bin/rails db:migrate` to update your database then try again.
The secondary database migration executes correctly if database_tasks: false is removed from primary.
System configuration
Rails version: edge and 7.1.3.2 have the same behaviour Ruby version: 3.3.0
The text was updated successfully, but these errors were encountered:
Steps to reproduce
Create a Rails app and define two databases.
Run
rails db:create
, adddatabase_tasks: false
to theprimary
database:Create a test migration:
Run
rails db:migrate
Expected behavior
Migration should execute in
secondary
databaseActual behavior
Nothing happens.
Furthermore, there appears to be discrepancy between how
db:migrate
lists pending migrations and how it's checked indb:migrate:status
anddb:setup
as, unlikedb:migrate
they can see the pending migration:The
secondary
database migration executes correctly ifdatabase_tasks: false
is removed fromprimary
.System configuration
Rails version: edge and 7.1.3.2 have the same behaviour
Ruby version: 3.3.0
The text was updated successfully, but these errors were encountered: