-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
8.2.0: sphinx warnings #5525
Comments
I don't see any warnings when building the docs locally: $ rm -rf docs/_build
$ make doc
/Library/Developer/CommandLineTools/usr/bin/make -C docs html
sphinx-build -b html -W --keep-going -d _build/doctrees . _build/html
Running Sphinx v4.0.1
making output directory... done
loading intersphinx inventory from https://docs.python.org/3/objects.inv...
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 91 source files that are out of date
updating environment: [new config] 91 added, 0 changed, 0 removed
reading sources... [100%] releasenotes/versioning
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
preparing documents... done
writing output... [100%] releasenotes/versioning
generating indices... genindex py-modindex done
highlighting module code... [100%] PIL.features
writing additional pages... search done
copying images... [100%] ../Tests/images/imagedraw_stroke_different.png
copying static files... done
copying extra files... done
dumping search index in English (code: en)... done
dumping object inventory... done
build succeeded.
The HTML pages are in _build/html.
Build finished. The HTML pages are in _build/html. Nor those specific warnings on ReadTheDocs: Am I missing something? Is there something we need to change in Pillow? |
You are using sphinx 4.0.1. I'm using 4.0.2. |
I get the same result with 4.0.2: $ rm -rf docs/_build
$ make doc
/Library/Developer/CommandLineTools/usr/bin/make -C docs html
sphinx-build -b html -W --keep-going -d _build/doctrees . _build/html
Running Sphinx v4.0.2
making output directory... done
loading intersphinx inventory from https://docs.python.org/3/objects.inv...
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 91 source files that are out of date
updating environment: [new config] 91 added, 0 changed, 0 removed
reading sources... [100%] releasenotes/versioning
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
preparing documents... done
writing output... [100%] releasenotes/versioning
generating indices... genindex py-modindex done
highlighting module code... [100%] PIL.features
writing additional pages... search done
copying images... [100%] ../Tests/images/imagedraw_stroke_different.png
copying static files... done
copying extra files... done
dumping search index in English (code: en)... done
dumping object inventory... done
build succeeded.
The HTML pages are in _build/html.
Build finished. The HTML pages are in _build/html. And different (but expected?) warnings using your command to build man pages: $ rm -rf docs/_build
$ PYTHONPATH=$PWD/src python3 setup.py build_sphinx -b man --build-dir build/sphinx
running build_sphinx
Running Sphinx v4.0.2
loading intersphinx inventory from https://docs.python.org/3/objects.inv...
building [mo]: targets for 0 po files that are out of date
building [man]: all manpages
updating environment: [new config] 91 added, 0 changed, 0 removed
reading sources... [100%] releasenotes/versioning
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
writing... pillowpilfork.1 { installation handbook/index handbook/overview handbook/tutorial handbook/concepts handbook/appendices handbook/image-file-formats handbook/text-anchors handbook/writing-your-own-file-decoder reference/index reference/Image reference/ImageChops reference/ImageCms reference/ImageColor reference/ImageDraw reference/ImageEnhance reference/ImageFile reference/ImageFilter reference/ImageFont reference/ImageGrab reference/ImageMath reference/ImageMorph reference/ImageOps reference/ImagePalette reference/ImagePath reference/ImageQt reference/ImageSequence reference/ImageShow reference/ImageStat reference/ImageTk reference/ImageWin reference/ExifTags reference/TiffTags reference/JpegPresets reference/PSDraw reference/PixelAccess reference/PyAccess reference/features PIL reference/plugins reference/internal_design reference/open_files reference/limits reference/block_allocator reference/internal_modules reference/c_extension_debugging porting about releasenotes/index releasenotes/8.3.0 releasenotes/8.2.0 releasenotes/8.1.2 releasenotes/8.1.1 releasenotes/8.1.0 releasenotes/8.0.1 releasenotes/8.0.0 releasenotes/7.2.0 releasenotes/7.1.2 releasenotes/7.1.1 releasenotes/7.1.0 releasenotes/7.0.0 releasenotes/6.2.2 releasenotes/6.2.1 releasenotes/6.2.0 releasenotes/6.1.0 releasenotes/6.0.0 releasenotes/5.4.1 releasenotes/5.4.0 releasenotes/5.3.0 releasenotes/5.2.0 releasenotes/5.1.0 releasenotes/5.0.0 releasenotes/4.3.0 releasenotes/4.2.1 releasenotes/4.2.0 releasenotes/4.1.1 releasenotes/4.1.0 releasenotes/4.0.0 releasenotes/3.4.0 releasenotes/3.3.2 releasenotes/3.3.0 releasenotes/3.2.0 releasenotes/3.1.2 releasenotes/3.1.1 releasenotes/3.1.0 releasenotes/3.0.0 releasenotes/2.8.0 releasenotes/2.7.0 releasenotes/versioning deprecations } /Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
/Users/hugo/github/Pillow/docs/installation.rst:: WARNING: "table row spanning" not supported
done
build succeeded, 11 warnings.
The manual pages are in build/sphinx/man. And the same when omitting |
@kloczek Did you build Pillow before building docs? You have to either install Pillow (so you won't need PYTHONPATH) or run an |
Yes, I built with |
Apologies for the confusion, I was asking the OP, since I suspect that is the reason for their issue. |
From my python-pillow.spec file: %build
%py3_build
PYTHONPATH=$PWD/src \
%py3_build_sphinx_man [tkloczko@barrel SPECS]$ rpm -E %py3_build_sphinx_man
\
/usr/bin/python3 setup.py build_sphinx -b man --build-dir build/sphinx Issue seems is that pillow builds some DSO modules which are under In other words .. implementation of the setuptools |
Yes. Pillow has a build process, and adding the source directory to the python path will not work. Pillow requires the ability to import the c library to be able to import pillow at all, and sphinx needs to import the library to build the docs. Therefore, you need to actually install Pillow, either in a develop mode or virtual env. If you are making manual changes to the python path, you’re doing it wrong. (unless you’re writing a packaging system or otherwise boiling the ocean) |
@kloczek after the discussion in pytest-dev/pytest#8731, do you have any updated thoughts on this? |
I've switched from $ rpm -E %pytest
\
CFLAGS="-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none";
CXXFLAGS="-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none";
FFLAGS="-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -I/usr/lib64/gfortran/modules";
FCFLAGS="-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -I/usr/lib64/gfortran/modules";
LDFLAGS="-Wl,-z,relro -Wl,--as-needed -Wl,--gc-sections -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -flto=auto -flto-partition=none -fuse-linker-plugin";
CC="/usr/bin/gcc"; CXX="/usr/bin/g++"; FC="/usr/bin/gfortran";
AR="/usr/bin/gcc-ar"; NM="/usr/bin/gcc-nm"; RANLIB="/usr/bin/gcc-ranlib";
export CFLAGS CXXFLAGS FFLAGS FCFLAGS LDFLAGS CC CXX FC AR NM RANLIB;
\
PATH="/home/tkloczko/rpmbuild/BUILDROOT/%{NAME}-%{VERSION}-%{RELEASE}.x86_64/usr/bin:$PATH" \
PYTHONPATH="${PYTHONPATH:-/home/tkloczko/rpmbuild/BUILDROOT/%{NAME}-%{VERSION}-%{RELEASE}.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/%{NAME}-%{VERSION}-%{RELEASE}.x86_64/usr/lib/python3.8/site-packages}" \
PYTHONDONTWRITEBYTECODE=1 \
\
/usr/bin/pytest -ra Still I did not finished testing that macro against all my pytton-* rpm packages but ifew cases it solved testing issues. Generally issue is that python build tooling does not forces enough some exact metgodologies so generally in python whole landscape is quite messy :/ Going back to sphinx subject. I still have no GoodEnough™️ solution about how to generate sphinx documentation. Will try to drop here some update about that topic if I'll manage make some progress about that. |
So if I'm understanding correctly, your issue is with sphinx in general, and there's nothing for us at Pillow to do at the moment? |
OK I'm closing that ticket because more likely it is issue with setuptools because on execution `setup.py build_sphinx" settuptools should set $PYTHONPATH to proper value. Thank you. |
BTW because you PIL and other modules code is under
src/
it is necessary to add$PYTHONPATH
The text was updated successfully, but these errors were encountered: