Skip to content

upgrading from v6.3.0 to v6.4.0 breaks sequelize-cli #994

@MichaelTaylor3d

Description

@MichaelTaylor3d

Project works fine when migrating with v6.3.0, it breaks when using v6.4.0. I have tried using the file:// scheme as it asks but it didnt make a difference in the error.

Sequelize CLI [Node: 16.0.0, CLI: 6.4.0, ORM: 6.13.0]

ERROR: Error reading "src\config\config.cjs". Error: Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only file and data URLs are supported by the default ESM loader. On Windows, absolute paths must be valid file:// URLs. Received protocol 'c:'

.sequalizerc

var path = require('path');

module.exports = {
  config: path.resolve('src', 'config', 'config.cjs'),
  'migrations-path': path.resolve('migrations'),
  'models-path': path.resolve('src', 'models'),
  'seeders-path': path.resolve('seeders'),
};

config.cjs

require('dotenv').config();

module.exports = {
  local: {
    dialect: 'sqlite',
    storage: './data.sqlite3',
  },
  test: {
    dialect: 'sqlite',
    storage: './test.sqlite3',
  },
  mirrorTest: {
    dialect: 'sqlite',
    storage: './testMirror.sqlite3',
  },
  mirror: {
    username: process.env.DB_USERNAME,
    password: process.env.DB_PASSWORD,
    database: process.env.DB_NAME,
    host: process.env.DB_HOST,
    dialect: 'mysql',
  },
};

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions