Menu

#23 [doc] I can not build the documentation

Jan14
resolved
doc (1)
doc
bug
2014-02-04
2013-08-05
No

Here I put the information when I try to build the doc from the source directory
it failes when reading the tango part of sardana. the error seems to related to Boost.

So I am wondering if the problem is not in PyTango instead of sardana.
Is PyTango module pickable ?

some one already saw this before ?

thanks

Frederic

picca@mordor:~/Projets/sardana/sardana/doc/source$ sphinx-build . build
Running Sphinx v1.2b1
loading pickled environment... not yet created
No builder selected, using default: html
loading intersphinx inventory from http://pyqt.sourceforge.net/Docs/PyQt4/objects.inv...
loading intersphinx inventory from http://docs.scipy.org/doc/scipy/reference/objects.inv...
loading intersphinx inventory from http://ipython.org/ipython-doc/stable/objects.inv...
loading intersphinx inventory from http://packages.python.org/guiqwt/objects.inv...
loading intersphinx inventory from http://docs.scipy.org/doc/numpy/objects.inv...
loading intersphinx inventory from http://matplotlib.sourceforge.net/objects.inv...
loading intersphinx inventory from http://www.tango-controls.org/static/taurus/latest/doc/html/objects.inv...
loading intersphinx inventory from http://docs.python.org/dev/objects.inv...
loading intersphinx inventory from http://www.tango-controls.org/static/PyTango/latest/doc/html/objects.inv...
building [html]: targets for 136 source files that are out of date
updating environment: 136 added, 0 changed, 0 removed
reading sources... [ 51%] devel/api/sardana/tango/core/SardanaDevice
Exception occurred:
File "/usr/lib/pymodules/python2.7/sphinx/environment.py", line 677, in read_doc
pickle.dump(doctree, f, pickle.HIGHEST_PROTOCOL)
PicklingError: Can't pickle <type 'Boost.Python.instance'="">: import of module Boost.Python failed
The full traceback has been saved in /tmp/sphinx-err-YGkvnn.log, if you want to report the issue to the developers.
Please also report this if it was a user error, so that a better error message can be provided next time.
Either send bugs to the mailing list at http://groups.google.com/group/sphinx-users/,
or report them in the tracker at http://bitbucket.org/birkenfeld/sphinx/issues/. Thanks!

Discussion

  • Frédéric PICCA

    Here the log message

    Sphinx version: 1.2b1

    Python version: 2.7.5+

    Docutils version: 0.10 release

    Jinja2 version: 2.7

    Traceback (most recent call last):
    File "/usr/lib/pymodules/python2.7/sphinx/cmdline.py", line 247, in main
    app.build(force_all, filenames)
    File "/usr/lib/pymodules/python2.7/sphinx/application.py", line 211, in build
    self.builder.build_update()
    File "/usr/lib/pymodules/python2.7/sphinx/builders/init.py", line 211, in build_update
    'out of date' % len(to_build))
    File "/usr/lib/pymodules/python2.7/sphinx/builders/init.py", line 231, in build
    purple, length):
    File "/usr/lib/pymodules/python2.7/sphinx/builders/init.py", line 131, in status_iterator
    for item in iterable:
    File "/usr/lib/pymodules/python2.7/sphinx/environment.py", line 458, in update_generator
    self.read_doc(docname, app=app)
    File "/usr/lib/pymodules/python2.7/sphinx/environment.py", line 677, in read_doc
    pickle.dump(doctree, f, pickle.HIGHEST_PROTOCOL)
    PicklingError: Can't pickle <type 'Boost.Python.instance'="">: import of module Boost.Python failed

     
  • Carlos Pascual

    Carlos Pascual - 2013-08-13
    • Milestone: Jul13 --> Jan14
     
  • Carlos Pascual

    Carlos Pascual - 2013-08-13

    I cannot reproduce in my system...

     
  • Zbigniew Reszela

    • Category: --> doc
    • Type: --> bug
     
  • Frédéric PICCA

    the problem is still present on debian-unstable.

     
  • Frédéric PICCA

    Exception occurred while building, starting debugger:e/SardanaDevice
    Traceback (most recent call last):
    File "/usr/lib/python2.7/dist-packages/sphinx/cmdline.py", line 246, in main
    app.build(force_all, filenames)
    File "/usr/lib/python2.7/dist-packages/sphinx/application.py", line 210, in build
    self.builder.build_specific(filenames)
    File "/usr/lib/python2.7/dist-packages/sphinx/builders/init.py", line 203, in build_specific
    'line' % len(to_write))
    File "/usr/lib/python2.7/dist-packages/sphinx/builders/init.py", line 234, in build
    purple, length):
    File "/usr/lib/python2.7/dist-packages/sphinx/builders/init.py", line 134, in status_iterator
    for item in iterable:
    File "/usr/lib/python2.7/dist-packages/sphinx/environment.py", line 470, in update_generator
    self.read_doc(docname, app=app)
    File "/usr/lib/python2.7/dist-packages/sphinx/environment.py", line 689, in read_doc
    pickle.dump(doctree, f, pickle.HIGHEST_PROTOCOL)
    PicklingError: Can't pickle <type 'Boost.Python.instance'="">: import of module Boost.Python failed

    /usr/lib/python2.7/dist-packages/sphinx/environment.py(689)read_doc()
    -> pickle.dump(doctree, f, pickle.HIGHEST_PROTOCOL)

    (Pdb) pickle
    <module 'cPickle' (built-in)>
    (Pdb) f
    <closed file u'/home/picca/Debian/main/sardana/sardana  /doc/source/build/.doctrees/devel/api/sardana/tango/core/SardanaDevice.doctree', mode 'wb' at 0xe009ee8>
    (Pdb)
    
     

    Last edit: Frédéric PICCA 2014-01-19
  • Frédéric PICCA

    two file seems to trigger the problem

    sardana/tango/pool/Pool.py
    sardana/tango/core/SardanaDevice.py

     
  • Frédéric PICCA

    It seems that the inheritance-diagram cause the troubbles.
    If I comment this part sphinx no more complain.

    #.. inheritance-diagram:: SardanaDevice
    # :parts: 1

     
  • Frédéric PICCA

    If I remove the Device_4Impl from the base class of SardanaDevice.
    there is no complain.

     
  • Frédéric PICCA

    so the problem seems to be in the PyTango pickling of the Server part.

     
  • Frédéric PICCA

    Maybe the problem is with the inheritance extension of sphinx.
    A similar bug was already reported and fix in the 1.x series

     
  • Tiago Coutinho

    Tiago Coutinho - 2014-01-21

    The pickle exception comes from PyTango.

    I have a debian 6 with some private packages and I don't see the problem.

    Python 2.6.6
    PyTango 8.1.2
    sphinx 1.1.3
    jinja2 2.5.5
    docutils 0.7

    What version of PyTango do you have?

    I will try to update sphinx and see if the problem occurs

     
  • Frédéric PICCA

    Ok after sensing a bug to ths sphinx peoples. this was a bug in sphinx 1.2.0.

    I just checked with sophinx 1.2.1 and it works :)

    So do not compile the documentation with 1.2.0

     
  • Carlos Pascual

    Carlos Pascual - 2014-01-22
    • status: open --> closed
    • assigned_to: Carlos Pascual
     
  • Carlos Pascual

    Carlos Pascual - 2014-01-22

    Applied patch provided by picca in the devel list.
    Just decline to builld docs if sphinx version is 1.2.0

     
  • Zbigniew Reszela

    • status: closed --> resolved