This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author flying sheep
Recipients dstufft, eric.araujo, flying sheep
Date 2017-08-28.13:57:45
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1503928665.81.0.590770692205.issue31292@psf.upfronthosting.co.za>
In-reply-to
Content
If I have a setup.py containing a include directive, and use the command in the title, I get


Traceback (most recent call last):
  [...]
  File "/usr/lib/python3.6/site-packages/docutils/parsers/rst/directives/misc.py", line 59, in run
    source_dir = os.path.dirname(os.path.abspath(source))
  File "/usr/lib/python3.6/posixpath.py", line 369, in abspath
    path = os.fspath(path)
TypeError: expected str, bytes or os.PathLike object, not _io.StringIO


The bug is in this method: distutils.command.check.check._check_rst_data

The first line already hints at it: `source_path = StringIO()`

StringIO instances aren’t paths, but at least the include directive (docutils.parsers.rst.directives.misc.Include) expects one.
History
Date User Action Args
2017-08-28 13:57:45flying sheepsetrecipients: + flying sheep, eric.araujo, dstufft
2017-08-28 13:57:45flying sheepsetmessageid: <1503928665.81.0.590770692205.issue31292@psf.upfronthosting.co.za>
2017-08-28 13:57:45flying sheeplinkissue31292 messages
2017-08-28 13:57:45flying sheepcreate