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

Warning messages when using "sequelize db:migrate" #240

Closed
leedongwei opened this issue Oct 1, 2018 · 0 comments
Closed

Warning messages when using "sequelize db:migrate" #240

leedongwei opened this issue Oct 1, 2018 · 0 comments

Comments

@leedongwei
Copy link
Contributor

Steps to reproduce

  1. Setup migration config as per documentation
  2. Create a dummy migration
  3. Run the migration with sequelize db:migrate

Expected behavior

No warning messages when running migration

Actual behavior

image

Cause

This happens because sequelize migration tool assumes that the migration folder contains only migration scripts. The config and models folders are not valid JS files and caused the warning to be issued.

Fix

Warnings can be avoided by moving all migration scripts into a sub-folder (suggested by @DesignByOnyx on the Slack channel, confirmed when I tested it on my project)

@leedongwei leedongwei changed the title Warning messages Warning messages when using "sequelize db:migrate" Oct 2, 2018
@daffl daffl closed this as completed in e0b5d5c Oct 29, 2018
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

No branches or pull requests

1 participant