Debian Bug report logs - #693066
python-sphinx: sphinx fails to parse c++11 "static constexpr" declarations

version graph

Package: python-sphinx; Maintainer for python-sphinx is Debian Python Modules Team <python-modules-team@lists.alioth.debian.org>; Source for python-sphinx is src:sphinx.

Reported by: Alexandre Duret-Lutz <adl@lrde.epita.fr>

Date: Mon, 12 Nov 2012 15:51:02 UTC

Severity: normal

Tags: confirmed, fixed-upstream, patch, upstream

Found in version sphinx/1.1.3+dfsg-4

Fixed in version sphinx/1.2~b1+dfsg-1

Done: Jakub Wilk <jwilk@debian.org>

Bug is archived. No further changes may be made.

Forwarded to https://bitbucket.org/birkenfeld/sphinx/issue/1038

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Jakub Wilk <jwilk@debian.org>:
Bug#693066; Package python-sphinx. (Mon, 12 Nov 2012 15:51:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Alexandre Duret-Lutz <adl@lrde.epita.fr>:
New Bug report received and forwarded. Copy sent to Jakub Wilk <jwilk@debian.org>. (Mon, 12 Nov 2012 15:51:04 GMT) Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Alexandre Duret-Lutz <adl@lrde.epita.fr>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: python-sphinx: sphinx fails to parse c++11 "static constexpr" declarations
Date: Mon, 12 Nov 2012 16:07:14 +0100
Package: python-sphinx
Version: 1.1.3+dfsg-4
Severity: normal
Tags: patch

Dear Maintainer,

The following three commands show that sphinx fails to parse a "static
constexpr" function declaration:

% cat >config.py <<EOF
source_suffix = '.rst'
master_doc = 'index'
EOF
% cat >index.rst <<EOF
... default-domain:: cpp

... function:: static constexpr bool foo()

   bar

EOF
% sphinx-build -a . out
Running Sphinx v1.1.3
loading pickled environment... done
No builder selected, using default: html
building [html]: all source files
updating environment: 0 added, 1 changed, 0 removed
reading sources... [100%] index
/home/adl/tmp/index.rst:3: WARNING: Invalid definition: expected parentheses for function [error at 22]
  static constexpr bool foo()
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
preparing documents... done
writing output... [100%] index
writing additional files... genindex search
copying static files... done
dumping search index... done
dumping object inventory... done
build succeeded, 1 warning.


domains/cpp.py has all the bits required to parse "static" or
"constexpr" function declarations, but it fails to parse the two together.
Apparently, this is because the space after "static" is not removed.

I patched my system as follows:

% diff -u /usr/share/pyshared/sphinx/domains/cpp.py{.old,}
--- /usr/share/pyshared/sphinx/domains/cpp.py.old       2012-11-12 15:19:46.325645389 +0100
+++ /usr/share/pyshared/sphinx/domains/cpp.py   2012-11-12 15:21:04.090030981 +0100
@@ -836,7 +836,7 @@
         visibility = 'public'
         if self.match(_visibility_re):
             visibility = self.matched_text
-        static = self.skip_word('static')
+        static = self.skip_word_and_ws('static')
         return visibility, static

     def parse_type(self):

-- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (1, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 3.2.0-3-686-pae (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages python-sphinx depends on:
ii  python           2.7.3-3
ii  python-docutils  0.8.1-8
ii  python-jinja2    2.6-1
ii  python-pygments  1.5+dfsg-1
ii  python-support   1.0.15
ii  sphinx-common    1.1.3+dfsg-4

Versions of packages python-sphinx recommends:
ii  python             2.7.3-3
ii  python-imaging     1.1.7-4
ii  python-simplejson  2.6.2-1
pn  sphinx-doc         <none>

Versions of packages python-sphinx suggests:
ii  jsmath                     3.6c-1.1
pn  libjs-mathjax              <none>
ii  texlive-fonts-recommended  2012.20120611-5
ii  texlive-latex-extra        2012.20120611-2
ii  texlive-latex-recommended  2012.20120611-5

-- no debconf information



Set Bug forwarded-to-address to 'https://bitbucket.org/birkenfeld/sphinx/issue/1038'. Request was from Jakub Wilk <jwilk@debian.org> to control@bugs.debian.org. (Tue, 13 Nov 2012 09:57:06 GMT) Full text and rfc822 format available.

Added tag(s) upstream and confirmed. Request was from Jakub Wilk <jwilk@debian.org> to control@bugs.debian.org. (Tue, 13 Nov 2012 09:57:07 GMT) Full text and rfc822 format available.

Added tag(s) fixed-upstream. Request was from bts-link-upstream@lists.alioth.debian.org to control@bugs.debian.org. (Thu, 29 Nov 2012 16:45:30 GMT) Full text and rfc822 format available.

Added tag(s) pending. Request was from Jakub Wilk <jwilk@debian.org> to control@bugs.debian.org. (Wed, 10 Apr 2013 11:15:09 GMT) Full text and rfc822 format available.

Reply sent to Jakub Wilk <jwilk@debian.org>:
You have taken responsibility. (Mon, 29 Apr 2013 22:21:04 GMT) Full text and rfc822 format available.

Notification sent to Alexandre Duret-Lutz <adl@lrde.epita.fr>:
Bug acknowledged by developer. (Mon, 29 Apr 2013 22:21:04 GMT) Full text and rfc822 format available.

Message #18 received at 693066-close@bugs.debian.org (full text, mbox):

From: Jakub Wilk <jwilk@debian.org>
To: 693066-close@bugs.debian.org
Subject: Bug#693066: fixed in sphinx 1.2~b1+dfsg-1
Date: Mon, 29 Apr 2013 22:17:47 +0000
Source: sphinx
Source-Version: 1.2~b1+dfsg-1

We believe that the bug you reported is fixed in the latest version of
sphinx, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 693066@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Jakub Wilk <jwilk@debian.org> (supplier of updated sphinx package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Mon, 29 Apr 2013 23:37:06 +0200
Source: sphinx
Binary: python-sphinx python3-sphinx sphinx-common sphinx-doc libjs-sphinxdoc
Architecture: source all
Version: 1.2~b1+dfsg-1
Distribution: experimental
Urgency: low
Maintainer: Jakub Wilk <jwilk@debian.org>
Changed-By: Jakub Wilk <jwilk@debian.org>
Description: 
 libjs-sphinxdoc - JavaScript support for Sphinx documentation
 python-sphinx - documentation generator for Python projects (implemented in Pytho
 python3-sphinx - documentation generator for Python projects (implemented in Pytho
 sphinx-common - documentation generator for Python projects - common data
 sphinx-doc - documentation generator for Python projects - documentation
Closes: 693066
Changes: 
 sphinx (1.2~b1+dfsg-1) experimental; urgency=low
 .
   * New upstream beta release.
     + Drop fix_nepali_po.diff; applied upstream.
     + Drop fix_shorthandoff.diff; different fix applied upstream.
     + Drop l10n_fixes.diff; applied upstream.
     + Drop manpage_writer_docutils_0.10_api.diff; applied upstream.
     + Drop pygments_byte_strings.diff; different fix applied upstream.
     + Drop show_more_stack_frames.diff; an option to show full traceback (-T)
       is now available.
     + Drop sort_stopwords.diff; applied upstream.
     + Drop support_python_3.3.diff; applied upstream.
     + Drop test_build_html_rb.diff; applied upstream.
     + Refresh other patches.
     + Update integration tests for the JavaScript code.
     + Update debian/copyright.
     + Update debian/*.docs to take into account that README was renamed as
       REAMDE.rst.
     + Update version in sphinx-autogen manpage.
     + This release fixes parsing C++11 “static constexpr” declarations
       (closes: #693066). Thanks to Alexandre Duret-Lutz for the bug report and
       the patch.
   * Run tests under LC_ALL=C.UTF-8 to work around test failures.
   * Make it impossible to accidentally build the source package with an
     .orig.tar that includes jquery.js or underscore.js.
   * Refactor debian/rules.
   * When building our own documentation, run sphinx-build with the -T option.
   * Use a dedicated script to extract JavaScript code for libjs-sphinxdoc.
   * Add no_external_css.diff: don't use CSS files hosted on external sites.
Checksums-Sha1: 
 85f3c63176ba5483beacb040252c0ae929ef62b5 2790 sphinx_1.2~b1+dfsg-1.dsc
 0311532809090cdf69393e0eb17dca31768db4ed 2967991 sphinx_1.2~b1+dfsg.orig.tar.gz
 4d6192d3ca971c2cdecd6a53e3594df51f7d2b0e 26739 sphinx_1.2~b1+dfsg-1.debian.tar.gz
 3a9284f6a7d831e4696438b1baf7223de6d7eab2 317340 python-sphinx_1.2~b1+dfsg-1_all.deb
 e08ec7d8e5c05afe4ed3a3c7fe05332486bd83d9 315698 python3-sphinx_1.2~b1+dfsg-1_all.deb
 387be107f5af5051f8589a6f7c09444cdc5934cf 429516 sphinx-common_1.2~b1+dfsg-1_all.deb
 abad6e74524258d1020a9ad07e3375537c3b77ed 1094642 sphinx-doc_1.2~b1+dfsg-1_all.deb
 e5ede9935844182841095e23b36d99807d37a77c 35886 libjs-sphinxdoc_1.2~b1+dfsg-1_all.deb
Checksums-Sha256: 
 b70eb88522d82e454967f85262e4c45b61e839125c77d38b980f84e7ffff0619 2790 sphinx_1.2~b1+dfsg-1.dsc
 b8c87e07cfc3f11138565deeee74883ec590cebc82012b85df782f02a0b562de 2967991 sphinx_1.2~b1+dfsg.orig.tar.gz
 e3ab870e050dd9a57b7160f3c1b24668ab43b50d3ef4c61023394c250eb1d532 26739 sphinx_1.2~b1+dfsg-1.debian.tar.gz
 d8cf7944e55ce09912e32c1755a5f3545a88fb705538e63abeef921fb9e5df44 317340 python-sphinx_1.2~b1+dfsg-1_all.deb
 dfb9a60fa6d64e8f5e00738519a841268d1a8cb8c5bd3789805b3c8b052128b0 315698 python3-sphinx_1.2~b1+dfsg-1_all.deb
 90fe1d67d61960018303f0a4225769c0488844807e319c59d2b6e9db6f939569 429516 sphinx-common_1.2~b1+dfsg-1_all.deb
 cf9a406a0d7bedd12a5979e0c713ad8c5e9e33f2e1c16987ca729285bb487af7 1094642 sphinx-doc_1.2~b1+dfsg-1_all.deb
 c203828d06bc7b088ec40184a7b54d7738c4f73684a9cb7296f74c2869d0adc3 35886 libjs-sphinxdoc_1.2~b1+dfsg-1_all.deb
Files: 
 b8ae023759f89e47955d0429c0573760 2790 python optional sphinx_1.2~b1+dfsg-1.dsc
 fd7a5eaa9f3471e3706a69db77166d6d 2967991 python optional sphinx_1.2~b1+dfsg.orig.tar.gz
 b936eaa2f6e9e785d89091a58b592103 26739 python optional sphinx_1.2~b1+dfsg-1.debian.tar.gz
 3deda547f84496df19cab33b7a0f3477 317340 python optional python-sphinx_1.2~b1+dfsg-1_all.deb
 d6f5642851ef684204f3b38887806769 315698 python optional python3-sphinx_1.2~b1+dfsg-1_all.deb
 04af259f4bc374f84c2add19045f4f26 429516 python optional sphinx-common_1.2~b1+dfsg-1_all.deb
 256b5f2bd7056d71ff2a7eec28b86144 1094642 doc optional sphinx-doc_1.2~b1+dfsg-1_all.deb
 7c0005ec2d6090ebea76d0eb55f90103 35886 web optional libjs-sphinxdoc_1.2~b1+dfsg-1_all.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQIcBAEBCAAGBQJRfu4XAAoJEC1Os6YBVHX1v68QAKIdOMB8v6E9m7Lgp8Rw0EiQ
o2BNO6sqL82fQYbCfIREAvL0+ZSMBjH29CabxTvyvdqG/bLC5xPjElls6+CxtMAn
9K8n3jRx2j1Y81nl2YWOL0LYh0PA/O50a8YPsDrQvd2CmScTmjjvR/EvkXrgif9E
XEGr6cqPp7Unya2uZYV3MPQL6YvM5KmMYqiWI9/6rVawxjiA8kaPLqUIEoHWRlIm
nfcpd51mxxmr3BUgiOmJUO54i/IC/5RQvaa4EogbhC4eUfM0XkS18rlBJ9ELyOfx
6jZdI3ouHQb/yWmfax47hFDGuGu6weaYPuUkXxiybOeGfAlF/e3JT9kh581m3VYj
0GaM9v2tvlN+gjIMnrtz3elv9QyuU1mJBd0wNK0NReMOVd5PN1awDu2U01YVPQti
Z99JXm0GRwq8WoTbNhN585LYlCVC8rBcdSPl0Sv763d6W1zV47DWhTZ7Tejm13dQ
VEHPbbfTwtywaHZbKKoyfITF0kQem9BpHFEzDQ1tL1IGRdNXwX4E0KgAh/doyplW
M5aPfbETa+1CTwBQ3xyoSJTdDwj4MS64G7mQWDSVulehIqEUZwcTbzNCKzL5t+pC
odWm+6naVNL5CTz+ocIYaUdZYeoizYqcv6uknlHsqk87RI7BNo59rrd/UpVg+uTW
L0fXpbMTXQsNn5gIh9H0
=RWhQ
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sat, 25 Jan 2014 07:36:14 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Apr 23 18:40:05 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.