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


Groups > comp.lang.python > #106420

How to make sphinx to recognize functools.partial?

From George Trojan <george.trojan@noaa.gov>
Newsgroups comp.lang.python
Subject How to make sphinx to recognize functools.partial?
Date 2016-04-04 00:26 +0000
Message-ID <mailman.421.1459729597.28225.python-list@python.org> (permalink)

Show all headers | View raw


Yet another sphinx question. I am a beginner here.

I can't make sphinx to recognize the following (abbreviated) code:

'''
module description

:func:`~pipe` and :func:`~spipe` read data passed by LDM's `pqact`.

'''

def _pipe(f, *args):
     '''doc string'''
      pass

def _get_msg_spipe():
     '''another doc'''
      pass

spipe = functools.partial(_pipe, _get_msg_spipe)
spipe._doc_ = '''
     Loop over data feed on `stdin` from LDM via SPIPE.
'''

The word spipe is rendered correctly in html, but the link is not created.

I did put a print statement in sphinx/util/inspect.py, it appears that 
spipe definition is not recognized. I am running sphinx 1.3.5, according 
to CHANGELOG functools.partial support was added in 1.2.1.

George

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

How to make sphinx to recognize functools.partial? George Trojan <george.trojan@noaa.gov> - 2016-04-04 00:26 +0000

csiph-web