Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mkdocs2pandoc gives no output #3

Closed
dagerber opened this issue Jan 18, 2016 · 4 comments
Closed

mkdocs2pandoc gives no output #3

dagerber opened this issue Jan 18, 2016 · 4 comments
Assignees

Comments

@dagerber
Copy link

mkdocs2pandoc gives no output an no error message.

  • Ran it without options in the directory where the mkdocs.yml is located
  • Still no output, if I use the -f switch
  • OS: Ubuntu 14.04
  • Python 2.7, mkdocs setup and working

Would be great, if you could add some logging, possibly a '-v' switch

sudo aptitude install fonts-lmodern lmodern pandoc texlive-base texlive-latex-extra texlive-fonts-recommended texlive-latex-recommended texlive-xetex

cd /home/xxxx/temp
virtualenv .
pip install mkdocs-pandoc
cd <dir-containing-mkdocs.yml>
/home/xxxx/temp/py/bin/mkdocs2pandoc
/home/xxxx/temp/py/bin/mkdocs2pandoc -f mkdocs.yml > file

No output...

@jgrassler
Copy link
Owner

Thanks for catching this!

Looks like this appeared in 0.2.2, with the Python 3 compatibility code being the likely culprit. I shouldn't have tested it with just the -o option (which worked fine). For now you can use one of the following two workarounds:

  • Install mkdocs-pandoc==0.2.1
  • Write to file using the -o option: mkdocs2pandoc -o file (this will work for 0.2.2 as well)

@jgrassler jgrassler self-assigned this Jan 18, 2016
@dagerber
Copy link
Author

Works like a charm. Thanks for your valuable work!

@jgrassler jgrassler reopened this Jan 18, 2016
@jgrassler
Copy link
Owner

I'm glad the workaround works for you, but I'll leave this open nonetheless if you don't mind, since I'd rather fix this for all use cases including the one that didn't work for you :-)

jgrassler pushed a commit that referenced this issue Jan 18, 2016
The Python 3 patch broke writing to standard output. This fixes the problem by
moving the call to pconv.convert() back to its proper place, and by accounting
for the different approaches to encoded output on sys.stdout in Python 2 and
Python 3 when opening the `out` filehandle for the first time.

Bug report: #3
@jgrassler
Copy link
Owner

Fixed in abe0f26. This is the basis for the new release 0.2.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants