`docpad skeleton` blocks instead of ending #225

Closed
DjebbZ opened this Issue May 22, 2012 · 11 comments

Comments

Projects
None yet
4 participants

DjebbZ commented May 22, 2012

Hi

It may be related to issue #223, when using docpad skeleton, one have to use Ctrl+C to terminate the command after it displays "info: The action completed successfully" because it doesn't end by itself. But everything is fine after that, all files are here and a quick test with docpad server shows no problem in the console or the browser.

I have my folder empty after pressing Ctrl+C no skeleton in there.

Owner

balupton commented May 22, 2012

I can't reproduce this... anyone know where the problem code is?

DjebbZ commented May 23, 2012

In my case, since DocPad displays "info: The action completed successfully", it can come only from these lines in console.coffee :

else
    logger.log 'info', "The action completed successfully"

# Exit or return to cli
if program.mode is 'cli'
    console.log ''
    program.emit 'cli', []

Maybe in some case, the program.mode is not cli ? Or the problem comes from what happens in program.emit 'cli', [].

Owner

balupton commented Jun 21, 2012

Can you try this again with DocPad v6.0.8 or later? Closing for now.

balupton closed this Jun 21, 2012

balupton reopened this Jun 23, 2012

Owner

balupton commented Jun 23, 2012

Not actually sure how to fix this... The mode is definitely not cli.

Somewhere in DocPad (or its dependencies) something would have been started, but never finished, which is quite difficult to debug. Perhaps this one will just have to be left for a pull request by a determined fellow!

DjebbZ commented Jun 26, 2012

Confirming that the issue still exists with v6.0.8. Using node 0.6.13. Will update docpad to 6.0.12, then node to 0.8 and report again.

DjebbZ commented Jun 26, 2012

Same problem with 6.0.12.

Owner

balupton commented Jun 26, 2012

I doubt that the status of this issue has changed, as I haven't done anything to resolve it...

Member

Delapouite commented Oct 18, 2012

The blocking comes from the choose method of commander.

process.stdin needs to be explicitly destroyed as shown in the example : https://github.com/visionmedia/commander.js/blob/master/examples/choice

Owner

balupton commented Oct 18, 2012

That's a bit lame. Can it be reopened once it's been destroyed? Want to submit a pull request?

balupton closed this in e83f755 Oct 19, 2012

@balupton balupton added a commit that referenced this issue Oct 19, 2012

@balupton balupton v6.8.1. Improvement. Bugfix.
- v6.8.1 October 19, 2012
	- Fixed `--port` CLI option not working (and possibly others)
	- Fixed `docpad skeleton` blocking instead of ending
		- Closes [#225](#225) thanks to
[Bruno Héridet](https://github.com/Delapouite)
	- Improved localisation
		- Thanks to [Bruno Héridet](https://github.com/Delapouite) for [pull
request #325](#325)
7d14f9b
Owner

balupton commented Oct 19, 2012

Published to 6.8.1

@balupton balupton added a commit that referenced this issue Oct 23, 2013

@balupton balupton v6.8.1. Improvement. Bugfix.
- v6.8.1 October 19, 2012
	- Fixed `--port` CLI option not working (and possibly others)
	- Fixed `docpad skeleton` blocking instead of ending
		- Closes [#225](#225) thanks to
[Bruno Héridet](https://github.com/Delapouite)
	- Improved localisation
		- Thanks to [Bruno Héridet](https://github.com/Delapouite) for [pull
request #325](#325)
861b7be
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment