Skip to content
This repository was archived by the owner on Apr 17, 2018. It is now read-only.

Models in Rails Engines Erroring (1.2.0, I think) #52

@tpitale

Description

@tpitale

Originally opened by @jkestr: datamapper/dm-core#175

I've been running into an issue with existing models and engines I have built from previous versions of DataMapper.

It appears with 1.2.0, it is no longer possible to have models inside of an engine without explicitly calling #finalize on each model. Is this a known issue, and if so are there any work arounds?

DataMapper.finalize does not work in this context, as it does not see the models inside of the engines. I tried creating an initializer that calls finalize on each model, but I ran into issues with Devise not yet being loaded.

What did work was putting .finalize at the bottom of each model definition, but I would rather not have to do that, and I am sure it would only cause other issues with relationships and such.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions