Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #9873

Re: providing sphinx3-* binaries

Path csiph.com!feeder.erje.net!2.us.feeder.erje.net!goblin1!goblin2!goblin.stu.neva.ru!news.unit0.net!news.panservice.it!bofh.it!news.nic.it!robomod
From Thomas Goirand <zigo@debian.org>
Newsgroups linux.debian.maint.python
Subject Re: providing sphinx3-* binaries
Date Fri, 29 Sep 2017 13:00:02 +0200
Message-ID <uv1bs-54Y-3@gated-at.bofh.it> (permalink)
References <uu6wx-2em-17@gated-at.bofh.it>
X-Mailbox-Line From debian-python-request@lists.debian.org Fri Sep 29 10:58:24 2017
Old-Return-Path <zigo@debian.org>
X-Amavis-Spam-Status No, score=-5.76 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, LDO_WHITELIST=-5, RCVD_IN_DNSWL_NONE=-0.0001, SARE_LWSHORTT=1.24] autolearn=no autolearn_force=no
X-Policyd-Weight using cached result; rate: -5
Organization Debian
User-Agent Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0
MIME-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Language en-US
Content-Transfer-Encoding quoted-printable
X-Mailing-List <debian-python@lists.debian.org> archive/latest/15255
List-ID <debian-python.lists.debian.org>
List-URL <https://lists.debian.org/debian-python/>
List-Archive https://lists.debian.org/msgid-search/ff878371-16bb-c0ad-0dcc-32208f64a7c5@debian.org
Approved robomod@news.nic.it
Lines 48
Sender robomod@news.nic.it
X-Original-Date Fri, 29 Sep 2017 12:58:04 +0200
X-Original-Message-ID <ff878371-16bb-c0ad-0dcc-32208f64a7c5@debian.org>
X-Original-References <877ewlqeku.fsf@curie.anarc.at>
Xref csiph.com linux.debian.maint.python:9873

Show key headers only | View raw


Hi Antoine,

Thanks for your post.

On 09/27/2017 12:29 AM, Antoine Beaupré wrote:
>  6. there are currently packages depending on *both* python-sphinx and
>     python3-sphinx. for me, that makes no sense at all: there is a
>     single set of documentation files built in a package, and it must be
>     on either one of those packages, but not both. if the software
>     supports building with python3, then it should depend on
>     python3-sphinx, if not, it should depend on python-sphinx. by
>     switching to sphinx{,3} binary packages, this would make that
>     distinction clearer as well.

It does make sense if the package is a sphinx extension, and it has
tests that you may want to run in both Python 2 and 3 cases. I do have a
few of these cases (even though I'm planning on switching to Python3
support only in the short term).

On 09/28/2017 02:27 PM, Antoine Beaupré wrote:
> A simple --with=sphinxdoc should be sufficient to build sphinx docs.
> We shouldn't expect upstream to do that step in setup.py, as it is
> rarely hooked into the main build.

I don't agree with this. I generally prefer to write things this way:

override_dh_sphinxdoc:
ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS)))
        sphinx-build -b html doc/source \
  $(CURDIR)/debian/python-foo-doc/usr/share/doc/python-foo-doc/html
        dh_sphinxdoc
endif

(sorry for the indentation above, lines are too short in emails)

This way, there's no need to pickup/copy the docs in doc/build, it ends
up directly in the package, ready for dh_sphinxdoc. If I need to add
some variables (for example to fix reproducibility), I can easily do it.
I will be switching to the "python3 -m sphinx" style soon, though that's
unrelated.

Over the years, I found using this method a way better than using
"python{3,} setup.py build_sphinx". I'd suggest you try my way too.

Cheers,

Thomas Goirand (zigo)

Back to linux.debian.maint.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

providing sphinx3-* binaries Antoine Beaupré <anarcat@debian.org> - 2017-09-27 00:30 +0200
  Re: providing sphinx3-* binaries Dmitry Shachnev <mitya57@debian.org> - 2017-09-28 00:10 +0200
    Re: providing sphinx3-* binaries Simon McVittie <smcv@debian.org> - 2017-09-28 09:40 +0200
    Re: providing sphinx3-* binaries Antoine Beaupré <anarcat@debian.org> - 2017-09-28 14:30 +0200
      Re: providing sphinx3-* binaries Dmitry Shachnev <mitya57@debian.org> - 2017-09-28 19:00 +0200
        Re: providing sphinx3-* binaries Antoine Beaupré <anarcat@debian.org> - 2017-09-28 19:20 +0200
  Re: providing sphinx3-* binaries Thomas Goirand <zigo@debian.org> - 2017-09-29 13:00 +0200
    RE:providing sphinx3-* binaries PICCA Frederic-Emmanuel <frederic-emmanuel.picca@synchrotron-soleil.fr> - 2017-09-29 13:30 +0200
      Re: providing sphinx3-* binaries Ghislain Vaillant <ghisvail@gmail.com> - 2017-09-29 14:00 +0200
        RE:providing sphinx3-* binaries PICCA Frederic-Emmanuel <frederic-emmanuel.picca@synchrotron-soleil.fr> - 2017-09-29 14:20 +0200
      Re: providing sphinx3-* binaries Thomas Goirand <zigo@debian.org> - 2017-10-03 23:50 +0200
        Re: providing sphinx3-* binaries Ghislain Vaillant <ghisvail@gmail.com> - 2017-10-04 04:50 +0200
          Re: providing sphinx3-* binaries Thomas Goirand <zigo@debian.org> - 2017-10-04 11:50 +0200

csiph-web