Skip to content

Migration generator creates schema with blank schema name #1339

Description

@philayres

During testing, a CreateSchema... migration is being created with an empty schema string:

require 'active_record/migration/app_generator'
class CreateSchema1ragas2bzo < ActiveRecord::Migration[5.2]
  include ActiveRecord::Migration::AppGenerator

  def change
    self.schema = ''
    self.owner = 'fphs'
    create_schema
  end
end

We should never request the migration generator to actually create a schema that has no name, or if this is not feasible, the migration generator should just log and skip the generation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions