Giter Site home page Giter Site logo

Support for Sprockets 4 about xray-rails HOT 12 CLOSED

brentd avatar brentd commented on August 24, 2024
Support for Sprockets 4

from xray-rails.

Comments (12)

patleb avatar patleb commented on August 24, 2024 2

Yep, I'll look into it, but can't tell you when it's gonna be completed, I'm busy with other stuff right now. No help needed, thanks!

from xray-rails.

baburdick avatar baburdick commented on August 24, 2024 1

@mattbrictson: I'm guessing that what sprockets 3.7.0 deprecated was removed in 4:

DEPRECATION WARNING: You are using the a deprecated processor interface #<Proc:0x007f9825d116f8@~/.rvm/gems/ruby-2.2.4@my_app/gems/xray-rails-0.1.21/lib/xray/engine.rb:22>.
Please update your processor interface:
https://github.com/rails/sprockets/blob/master/guides/extending_sprockets.md#supporting-all-versions-of-sprockets-in-processors
 (called from block in <class:Engine> at ~/.rvm/gems/ruby-2.2.4@my_app/gems/xray-rails-0.1.21/lib/xray/engine.rb:22)
DEPRECATION WARNING: You are using the a deprecated processor interface #<Proc:0x007f9827c0b2c0@~/.rvm/gems/ruby-2.2.4@my_app/gems/xray-rails-0.1.21/lib/xray/engine.rb:56>.
Please update your processor interface:
https://github.com/rails/sprockets/blob/master/guides/extending_sprockets.md#supporting-all-versions-of-sprockets-in-processors
 (called from block in <class:Engine> at ~/.rvm/gems/ruby-2.2.4@my_app/gems/xray-rails-0.1.21/lib/xray/engine.rb:56)

from xray-rails.

mattbrictson avatar mattbrictson commented on August 24, 2024 1

@evolve2k Have you tried xray-rails 0.2.0?

from xray-rails.

evolve2k avatar evolve2k commented on August 24, 2024 1

Cheers @mattbrictson. Woops hadn't noticed that 0.2.0 had landed.
Yes updgrading to 0.2.0 fixed the deprecation warnings for me.

Is this issue resolved then?

from xray-rails.

patleb avatar patleb commented on August 24, 2024

I've made it work in my fork, but I've also some personal modifications, so it might be a good starting point for a pull request if you want to take a look : https://github.com/patleb/xray-rails/commit/a5bc3f03a1514d145a848fedcd27cefbe9876950

from xray-rails.

mattbrictson avatar mattbrictson commented on August 24, 2024

Hi, thanks for the report and the commit. Can you provide some more background to bring us up to speed?

  • What changed in Sprockets 4 that breaks xray-rails?
  • What error message or undesirable behavior does this cause?
  • How does your commit fix it?
  • Are these fixes backwards-compatible with Sprockets 2 and 3?

from xray-rails.

patleb avatar patleb commented on August 24, 2024

@mattbrictson, sorry, forgot about it. To answer your questions:

  • the registration interface has changed, now you need to pass un object instead of a block
  • the error message was about what I just said
  • my commit changes the registration with something that works for Sprockets 2, 3 and 4 (although, .jst won't work, I made a mistake... should have been registered as a preprocessor)
  • it should, but I haven't test it yet with other versions

from xray-rails.

mattbrictson avatar mattbrictson commented on August 24, 2024

OK, thanks for the additional info. I would like to turn this into an actual PR so that we can do a more thorough review.

@patleb Are you comfortable taking the lead on these changes and doing a PR? Is there anything you need help with?

from xray-rails.

mattbrictson avatar mattbrictson commented on August 24, 2024

I stumbled across this commit in another project. It may shed some light on what is required for Sprockets 4 compatibility.

ai/autoprefixer-rails@cd9b2ef

from xray-rails.

patleb avatar patleb commented on August 24, 2024

Thx. Sorry for the late feedback, but I'm on the clock to deliver a project, so I think it might take at least a couple of weeks before I look into it.

from xray-rails.

evolve2k avatar evolve2k commented on August 24, 2024

bump

from xray-rails.

mattbrictson avatar mattbrictson commented on August 24, 2024

Sounds like it is resolved. Thanks for verifying!

from xray-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.