Skip to content

Asset compilation stalls with sprockets v4 #640

Open
@leoarnold

Description

@leoarnold

Expected behavior

Asset compilation speed with sprockets v4.0.0 should be comparable to or faster than with v3.7.2.

Actual behavior

When calling rails assets:clobber tmp:clear assets:precompile sprockets will start building the cache (i.e. tmp/cache/assets/sprockets/v4.0.0/) up to about 8 MB (full cache with v3.7.2: 18MB) with no assets written and then the process and all of its six forks seem to come to a complete halt: 0.0% CPU usage according to htop. The process will not react to SIGINT or SIGTERM any more, only SIGHUP and SIGKILL can end the process.

Same with assets compilation in Rails development environment upon first request.

Once sprockets cache is built, sprockets will run smooth and quick as expected, but building the cache seemingly takes forever: Travis CI will just abort the build after 10 minutes.

System configuration

  • Sprockets version 4.0.0
  • Ruby version 2.5.0
  • Rails version 6.0.0
  • execjs 2.7.0
  • coffee-rails 5.0.0 / coffee-script 2.4.1
  • uglifier 4.2.0
  • sass 3.4.25 / sassc-rails 2.1.4 / sassc 2.2.1

Example App (Reproduction)

I couldn't quite figure out what is making sprockets stall so I am not able to provide an example app at time of this writing (project in question is private company property).

Therefore I would be very grateful if the community could provide pointers on how I could debug this and identify the root cause.

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