{"action":"opened","issue":{"url":"https://api.github.com/repos/adambom/parallel.js/issues/102","labels_url":"https://api.github.com/repos/adambom/parallel.js/issues/102/labels{/name}","comments_url":"https://api.github.com/repos/adambom/parallel.js/issues/102/comments","events_url":"https://api.github.com/repos/adambom/parallel.js/issues/102/events","html_url":"https://github.com/adambom/parallel.js/issues/102","id":74540414,"number":102,"title":"Asynchronous spawn","user":{"login":"sbalko","id":2197299,"avatar_url":"https://avatars.githubusercontent.com/u/2197299?v=3","gravatar_id":"","url":"https://api.github.com/users/sbalko","html_url":"https://github.com/sbalko","followers_url":"https://api.github.com/users/sbalko/followers","following_url":"https://api.github.com/users/sbalko/following{/other_user}","gists_url":"https://api.github.com/users/sbalko/gists{/gist_id}","starred_url":"https://api.github.com/users/sbalko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sbalko/subscriptions","organizations_url":"https://api.github.com/users/sbalko/orgs","repos_url":"https://api.github.com/users/sbalko/repos","events_url":"https://api.github.com/users/sbalko/events{/privacy}","received_events_url":"https://api.github.com/users/sbalko/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-09T00:25:45Z","updated_at":"2015-05-09T00:25:45Z","closed_at":null,"body":"Is there a way to use spawn in an asynchronous way? My use-case is unit testing: inside of the worker code I use requirejs to retrieve all dependencies before I then run any code. Hence, merely returning from the serialized function that is passed to spawn is not exactly an option. Instead, I would need to use a callback, which I call when my work is done and the worker can be terminated.\r\n\r\n"}}