Open pybride opened 8 years ago
Thanks for your report. Might be an issue that just occurs on Windows. It would be great if you could verify/falsify this assumption.
In any case, I'll have a look later today.
I was wrong with my assumption. There were two issues:
1) The build failed if you didn't specify a language in the config file.
2) The build assumed .
is the source directory and failed if this wasn't true.
Can you confirm that it works now for you, @pybride ?
As I'm using a French Windows today, I have now another issue:
Exception occurred:
File "c:\python27\lib\subprocess.py", line 958, in _execute_child
startupinfo)
WindowsError: [Error 2] Le fichier spÚcifiÚ est introuvable
Traceback (most recent call last):
File "c:\python27\lib\runpy.py", line 162, in _run_module_as_main
"main", fname, loader, pkg_name)
File "c:\python27\lib\runpy.py", line 72, in _run_code
exec code in run_globals
File "c:\Python27\Scripts\sphinx-build.exemain.py", line 9, in
It seems a common problem with Popen on Windows, but I don't even know which string is creating the issue. I printed some variables: ('project_path', 'c:\python27\lib\site-packages') ('srcdir', u'd:\Projects\Platypus\Main\Doc\Sphinx') ('sources_build_path', '../_build_txt')
For a quick fix, you can try adding these line below line 41 of __init__.py
:
if isinstance(srcdir, unicode):
srcdir = srcdir.encode('UTF-8')
I'll see if I can reproduce your issue on a Windows machine later.
It doesn't resolve the issue.
I could reproduce the issue on a Windows machine and fix it (for me). Can you confirm, @pybride ?
I'm using a English Windows today, therefore I don't expect the same issues. But it is still not working. First, I don't get the 1.3 version (pip install sphinxprettysearchresults --upgrade give me 1.2) Then, I have now "The system cannot find the file specified", even when copying manually version 1.3
Some print out: ('srcdir', 'd:\Projects\Platypus\Main\Doc\Sphinx') ('sources_build_path', '../_build_txt')
I got the _build_txt folder, but a level above my sphinx data and make.bat. Shouldn't it be on the same level as _build?
I change to sources_build_path = '_build_txt'
, but I don't have more success.
The current version on PyPi is 0.1.3, so I can't understand why it doesn't do the update for you. I'll try to reproduce the 2nd issue asap.
@pybride :
I couldn't reproduce these issues on my Windows machine. Could you check which of the directories doesn't exist?
You can add the following line before the build_txt = ...
line:
print 'isdir sources_build_path: ' + os.path.isdir(sources_build_path)
print 'isdir srcdir: ' + os.path.isdir(srcdir)
The exact sphinx-build command you use might also be relevant.
I changed the sources build path to _build_txt
(removed the ../
), but did not release this, yet.
Finally, I could run it, but only with:
build_txt = subprocess.Popen(['c:\Python27\Scripts\sphinx-build', '-a', '-b', 'text','-D' 'language=' + language, srcdir, sources_build_path])
I need the full path to sphinx-build.
Thanks for the info, I'll work on a fix
Maybe the issue is related to how we install Python. As we only use it for sphinx, Python.exe isn't put in the PATH, therefore, for example, pip only work from c:\Python27\Scripts (or if the full path is used).
Also, the make.bat created by sphinx has these lines:
if "%SPHINXBUILD%" == "" ( set SPHINXBUILD="c:\Python27\Scripts\sphinx-build" )
Because I can't reproduce any related errors, I'll close this issue. Please ask me to re-open if you still experience problems.
We updated to 0.3.1, but we still need to change the Popen line to make it work. And it happens on several machines (Windows 10 Pro/Enterprise English)
build_txt = subprocess.Popen(['c:\Python27\Scripts\sphinx-build', '-a', '-b', 'text','-D' 'language=' + language, srcdir, sources_build_path])
Is your project OS or can you provide a minimal working example that allows me to reproduce this issue?
Not open source. As we are now working on the release, I will try to create a working example in the next few days.
Thanks, I'll have a look then
Here is a very simple project, which also has the issue on make html. I also put the log file in it.
Hi,
Thanks for this extension, it is what we need. Unfortunately, it isn't working:
sphinx-err-rmic8m.log.txt
I tried to remove
'-D' 'language=' + language
as I don't need I18N, but then I get:sphinx-err-3cju9l.log.txt
Best regards, Pierre-Yann