Giter Club home page Giter Club logo

Comments (6)

EppO avatar EppO commented on July 25, 2024

Interesting fact: if you declare gem "rolify" before gem "less-rails" in the Gemfile, it works.
I guess it's a matter of initializers loading order.

from less-rails.

metaskills avatar metaskills commented on July 25, 2024

Thanks for posting this. I tried this approach 64081fe and published v2.4.1 and it failed. Then I did dfb9a5e along with the test project @raykin put in #62 and it his issue was fixed. After some deep digging, I think after load_config_initializers was a poor decision on my part. From @raykin's project, I could see that the core Railtie load_config_initializers hook was being called 4 times or so.

I then decided that what I really wanted was a before on that and once I changed it, everything just worked. Please test v2.4.2 with your issue and let me know if it works. Again, thanks for looking into this.

from less-rails.

bughit avatar bughit commented on July 25, 2024

@metaskills This must have regressed: rails/rails#35025

If this is caused by initializer 'less-rails.before.load_config_initializers', :before => :load_config_initializers, :group => :all, then a couple of comments:

  1. gem initializers already run before app initilializers, so why is this before needed?
  2. rails is probably at fault because this should not prevent the enforcement of the guarantee that app initializers will run after gems, but a fix in less-rails would be helpful

from less-rails.

metaskills avatar metaskills commented on July 25, 2024

Sorry, it has been awhile. Is there something mintiest-spec-rails needs to do?

from less-rails.

bughit avatar bughit commented on July 25, 2024

You mean less-rails?

If you look through rails/rails#35025, the culprit is initializer 'less-rails.after.append_assets_path', :after => :append_assets_path. This after condition ends up causing app initializers to run before at least some gem initializers (geocoder in the test repo)

But rafaelfranca says there's no guarantee that app inits will run after gem inits, so I suppose technically there's is no issue, however I think practically, it would be nicer if less-rails did not have such an effect (if it's avoidable).

from less-rails.

metaskills avatar metaskills commented on July 25, 2024

Whoops right, repo confusion.

from less-rails.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.