Skip to content

Prevent tasks from interfering with other tasks #364

@yocontra

Description

@yocontra

Scenario:

  • You run two tasks - minify-css, minify-js
  • minify-js is processing a file and blocks the event loop since the underlying module (let's say uglify) is full of nested loops that take forever
  • minify-css is stalled because the main event loop is blocked
  • minify-js finishes the file
  • minify-css starts processing its file asynchronously like it's supposed to
  • minify-js gets another file and blocks the event loop again, thus stalling minify-css until it's done
  • minify-js finished before minify-css ever gets through the first file
  • minify-css shows up as taking way longer than it should have

tl;dr shitty 3rd party modules that run synchronously (like uglify) will block the main loop preventing other things from running

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions