cowboy/grunt — Issue #38: async tasks don't work
Author: wookiehangover
Created: 2012-02-09 18:50:01+00:00
State: open

due to the changes introduced in 3eba018, long running asynchronous tasks never finish. We discovered this while migrating a project from a Cakefile based build task using [stitch](https://github.com/sstephenson/stitch) to grunt.

Here's the build task that worked on previous versions:

```javascript
task.registerBasicTask("stitch", "Compile common.js modules with stitch", function( data, name ){

data.paths = data.paths.map(function(dir){
return "./" + dir;
});

stitch.createPackage( data ).compile(function( error, src ){

if( error ){
return log.error( error );
}

file.write( name, src );

log.writeln("File \"" + name + "\" created.");
});

});
```

In the current version of grunt the callback passed into compile is never called.