Skip to content

Complain about any config.autoload_paths code used in migration? #14

Description

@steobrien

Thanks for your work in creating and maintaining this gem.

Currently, it only warns for app:

if path.starts_with? File.join(Rails.application.root, "app")

We'd love if this was configurable, or perhaps respected config.autoload_paths. The reasoning is: occasionally in our data migrations, we'll use code in /lib. Some production instances of our app may run the migrations months later, when the underlying code may have changed, and any calls to /lib are therefore potentially unsafe.

Happy to submit a PR here if this sounds appropriate!

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