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

Deface caught in endless loop when processing a certain constellation #155

Open
scan opened this issue Mar 10, 2016 · 0 comments
Open

Deface caught in endless loop when processing a certain constellation #155

scan opened this issue Mar 10, 2016 · 0 comments

Comments

@scan
Copy link

scan commented Mar 10, 2016

We've just had a lot of trouble solving a problem with the Rails Server and Rails Console caught in a loop, not even reacting to SigTerm. After quite a while of trying out different combinations of Gems and Ruby versions, I was able to finally find the solution to lie in Deface.

During development, we added out own stylesheet to the spree head, in /app/overrides/spree/shared/_head/add_stylesheet.html.haml.deface. In the meantime, to do a comparison, the new stylesheet was commented out, which then led to the dev server not reacting and the process taking up 100% of CPU time. It looked like this:

//
    replace 'erb[loud]:contains("stylesheet_link_tag")'
    original '558b22855bf0d0e777aeaa1a8cbb51e628870834'

//= stylesheet_link_tag 'application', media: :screen

Trying to find out why, I was able to get Ruby to react to SigTerm at one point, and that led me to the process hanging in line L108 of lib/deface/dsl/loader.rb. It looks like deface has a problem removing the commented line and is caught in the loop.

Using deface 1.0.2, rubygems release.

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