travis-sphinx icon indicating copy to clipboard operation
travis-sphinx copied to clipboard

Error: no such option: --source & [Errno 2] No such file or directory: 'target/doc/build'

Open tyralla opened this issue 8 years ago • 7 comments

At first, thank you very much for providing this handy tool!

Just recently (yesterday evening and this morning), I got the mentioned error messages. The related commands were:

if [ $TRAVIS_PYTHON_VERSION = "2.7" ] ; then travis-sphinx --source=hydpy/docs build; fi
if [ $TRAVIS_PYTHON_VERSION = "2.7" ] ; then python modify_html.py; fi

See the following link for more information: https://github.com/tyralla/hydpy/blob/develop/.travis.yml

Maybe this problem is related with issue #28?

Please let me know if further information is required.

Best regards, Christoph.

tyralla avatar Nov 15 '17 09:11 tyralla

@tyralla The source parameter is for the build command.... Therefore you must call travis-sphinx as

travis-sphinx build --source=hydpy/docs

lmignon avatar Nov 15 '17 09:11 lmignon

Looks like i'm able to reproduce this error, investigating right now.

EDIT: Nevermind, seems my build ran fine and it was only a small error on my side.

Can you confirm that your build command is running and completing? One way you'd receive that error is if the build command failed

Syntaf avatar Nov 15 '17 16:11 Syntaf

@Syntaf The --source parameter must be put after the command... not before. The order matters

travis-sphinx build --source=hydpy/docs

lmignon avatar Nov 15 '17 16:11 lmignon

@lmignon Whoops, you are correct.

I guess this brings up an unfortunate consequence of travis-sphinx 2.0.0 in that we're breaking legacy code. I'm going to create an issue to see if we can still support source coming before build, and simply passing it along into build if it's used beforehand

Syntaf avatar Nov 15 '17 16:11 Syntaf

https://github.com/Syntaf/travis-sphinx/issues/31

Syntaf avatar Nov 15 '17 16:11 Syntaf

For some reasons the order --source=hydpy/docs build did work before.

However, now (with build --source=hydpy/docs) it works again. Thank you for the quick answer!

Besides: At least an additional problem lay in my script modify_html.py. It still assumed the html output path to be target/doc/build instead of doc/build.

tyralla avatar Nov 15 '17 18:11 tyralla

@tyralla The recent major version change no longer allows --source to appear before build, but #31 will add that back for now.

Thanks for the issue report!

I will be leaving this open for a bit as the legacy source option is likely broken on some other repos right now :(

Syntaf avatar Nov 15 '17 18:11 Syntaf