gulpjs / undertaker

Task registry that allows composition through series/parallel methods.
MIT License
200 stars 31 forks source link

Error in parallel #59

Closed TrySound closed 8 years ago

TrySound commented 8 years ago

I run in parallel 4 tasks: markup, script, style, image. If at least one of them is failed, build breaks in the same time. I think end of all tasks in parallel should be waited and then errored. Paralleled tasks do not depends on each other so they should be ended correctly.

[02:23:51] Using gulpfile D:\_host\github\case\gulpfile.js
[02:23:51] Starting 'build'...
[02:23:51] Starting 'clean (skipped)'...
[02:23:51] Finished 'clean (skipped)' after 2.09 ms
[02:23:51] Starting '<parallel>'...
[02:23:51] Starting 'markup'...
[02:23:51] Starting 'script'...
[02:23:51] Starting 'style'...
[02:23:51] Starting 'image'...
[02:23:52] Finished 'image' after 1.14 s
[02:23:52] 'markup' errored after 1.16 s
[02:23:52] Error in plugin 'gulp-file-include'
Message:
    ENOENT, no such file or directory 'D:\_host\github\case\app\markup\sss'
Details:
    domainEmitter: [object Object]
    domain: [object Object]
    domainThrown: false
[02:23:52] '<parallel>' errored after 1.17 s
[02:23:52] 'build' errored after 1.18 s
[02:23:52] The following tasks did not complete: script, style
[02:23:52] Did you forget to signal async completion?
phated commented 8 years ago

This is the standard way parallel async stuff is handled in node (look at the async module, etc). In gulp-cli, we are doing a process.exit(1) when that callback is called; If that is your problem, please open this over there.

phated commented 8 years ago

@TrySound Also, if that is your issue, I think you are looking for the --continue flag that continues on an error.