proycon / pynlpl

PyNLPl, pronounced as 'pineapple', is a Python library for Natural Language Processing. It contains various modules useful for common, and less common, NLP tasks. PyNLPl can be used for basic tasks such as the extraction of n-grams and frequency lists, and to build simple language model. There are also more complex data types and algorithms. Moreover, there are parsers for file formats common in NLP (e.g. FoLiA/Giza/Moses/ARPA/Timbl/CQL). There are also clients to interface with various NLP specific servers. PyNLPl most notably features a very extensive library for working with FoLiA XML (Format for Linguistic Annotation).
https://pypi.python.org/pypi/PyNLPl
GNU General Public License v3.0
479 stars 67 forks source link

Docs build: fix AttributeError tracebacks #21

Closed irushchyshyn closed 7 years ago

irushchyshyn commented 7 years ago

Fixes the following tracebacks when building docs:

/builddir/build/BUILD/pynlpl-1.0.9/docs/_autosummary/pynlpl.formats.folia.AllowTokenAnnotation.rst:42: WARNING: autodoc: failed to import method u'AllowTokenAnnotation.__iter__' from module u'pynlpl.formats.folia'; the following exception was raised:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/sphinx/ext/autodoc.py", line 526, in import_object
    obj = self.get_attr(obj, part)
  File "/usr/lib/python2.7/site-packages/sphinx/ext/autodoc.py", line 422, in get_attr
    return safe_getattr(obj, name, *defargs)
  File "/usr/lib/python2.7/site-packages/sphinx/util/inspect.py", line 125, in safe_getattr
    raise AttributeError(name)
AttributeError: __iter__
/builddir/build/BUILD/pynlpl-1.0.9/docs/_autosummary/pynlpl.formats.folia.AllowTokenAnnotation.rst:43: WARNING: autodoc: failed to import method u'AllowTokenAnnotation.__len__' from module u'pynlpl.formats.folia'; the following exception was raised:
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/sphinx/ext/autodoc.py", line 526, in import_object
    obj = self.get_attr(obj, part)
  File "/usr/lib/python2.7/site-packages/sphinx/ext/autodoc.py", line 422, in get_attr
    return safe_getattr(obj, name, *defargs)
  File "/usr/lib/python2.7/site-packages/sphinx/util/inspect.py", line 125, in safe_getattr
    raise AttributeError(name)
AttributeError: __len__