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

padrino rake mi:create_indexes doesn't handle all mongoid models #2208

Open
sriedel opened this issue Mar 13, 2019 · 0 comments
Open

padrino rake mi:create_indexes doesn't handle all mongoid models #2208

sriedel opened this issue Mar 13, 2019 · 0 comments

Comments

@sriedel
Copy link

sriedel commented Mar 13, 2019

Do you want to request a feature or report a bug?

A Bug.

What is the current behavior?

If you have mongoid models residing in a directory other than /models or /app/models, invoking padrino rake mi:create_indexes will be a silent no-op.

Invoking ::Mongoid::Tasks::Database.create_indexes (as seen in $MONGOID_GEM_ROOT/lib/mongoid/tasks/database.rake) in a padrino console however does find and deal with all models.

What is the expected behavior?

Invoking 'padrino rake mi:create_indexes` will create any missing indexes of any mongoid model in memory, regardless of where the model resides in the directory tree.

Which versions of Ruby, Padrino, Sinatra, Rack, OS are you using? Did this work in previous versions?

MRI 2.6.1, Padrino 0.14.4, Sinatra 2.0.5, Rack 2.0.6, Linux 5.0.0

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