Skip to content
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

getDoc() can produce invalid ReST when value_type is present #76

Closed
jamadden opened this issue Sep 23, 2018 · 0 comments
Closed

getDoc() can produce invalid ReST when value_type is present #76

jamadden opened this issue Sep 23, 2018 · 0 comments

Comments

@jamadden
Copy link
Member

Noticed in zope.configuration:

>>> from zope.configuration import config
>>> print(config.IDirectiveInfo['schema'].getDoc())
Directive handler

The dotted name of the directive handler

:Implementation: :class:`zope.configuration.config.DirectiveSchema`
:Read Only: False
:Required: True
:Default Value: None
.. rubric:: Value Type

:Implementation: :class:`zope.schema.InterfaceField`
:Read Only: False
:Required: True
:Default Value: None

Which produces a warning: (though the documentation is still printed):

$ sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html
Running Sphinx v1.8.1
loading pickled environment... done
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 0 source files that are out of date
updating environment: [] 0 added, 2 changed, 0 removed
reading sources... [100%] api/zopeconfigure
docstring of zope.configuration.config.IDirectiveInfo.schema:9: WARNING: Field list ends without a blank line; unexpected unindent.
clrpackages pushed a commit to clearlinux-pkgs/zope.schema that referenced this issue Sep 25, 2018
…present

Jason Madden (11):
      Back to development: 4.8.1
      Document IFromBytes in Sphinx.
      Merge pull request #73 from zopefoundation/doc-IFromBytes
      Make NativeString[Line] into distinct types.
      Fix Field.getDoc() when value_type or key_type are present
      Merge pull request #75 from zopefoundation/issue74
      Merge pull request #77 from zopefoundation/issue76
      Make DottedName accept leading underscores.
      Add change note. [skip ci]
      Merge pull request #78 from zopefoundation/dottedname_allow_underscore
      Preparing release 4.9.0

4.9.0 (2018-09-24)
==================

- Make ``NativeString`` and ``NativeStringLine`` distinct types that
  implement the newly-distinct interfaces ``INativeString`` and
  ``INativeStringLine``. Previously these were just aliases for either
  ``Text`` (on Python 3) or ``Bytes`` (on Python 2).

- Fix ``Field.getDoc()`` when ``value_type`` or ``key_type`` is
  present. Previously it could produce ReST that generated Sphinx
  warnings. See `issue 76 <https://github.com/zopefoundation/zope.schema/issues/76>`_.

- Make ``DottedName`` accept leading underscores for each segment.

- Add ``PythonIdentifier``, which accepts one segment of a dotted

(NEWS truncated at 15 lines)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant