Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update migration error messages #285

Merged
merged 3 commits into from
Aug 26, 2024
Merged

Conversation

jackphilippi
Copy link
Contributor

@jackphilippi jackphilippi commented Aug 21, 2024

Fixed a couple of error messages for migrate.go

The inconsistent migration error incorrectly swaps the migration names

Steps to reproduce

  1. Create a migration file named 0.0.1-set-up-tables.cql
  2. Run the migrations via gocqlx.Migrate
  3. Rename the migration file to 0.0.1-set-up-tables-RENAMED.cql
  4. Run the migrations again
stderr: panic: inconsistent migrations found, expected "0.0.1.set-up-tables-RENAMED.cql" got "0.0.1.set-up-tables.cql" at 1

should instead be

stderr: panic: inconsistent migrations found, expected "0.0.1.set-up-tables.cql" got "0.0.1.set-up-tables-RENAMED.cql" at 1

@mykaul mykaul requested a review from dkropachev August 21, 2024 07:31
@sylwiaszunejko sylwiaszunejko self-requested a review August 26, 2024 06:37
@sylwiaszunejko
Copy link
Collaborator

@jackphilippi pls address issues in the CI

@jackphilippi
Copy link
Contributor Author

@sylwiaszunejko thanks! i have updated the test

@sylwiaszunejko sylwiaszunejko merged commit c6a436b into scylladb:master Aug 26, 2024
1 check passed
@sylwiaszunejko
Copy link
Collaborator

@jackphilippi thanks for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants