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 jon.poler
Recipients docs@python, eric.araujo, ezio.melotti, jon.poler, ncoghlan
Date 2014-08-17.13:53:26
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1408283608.84.0.371003450877.issue22014@psf.upfronthosting.co.za>
In-reply-to
Content
Here's one way to accomplish this. Please see attached os_exceptions_table_V2.patch.

I wasn't having much luck trying to use ReST, so I took advantage of the fact that the Doc/conf.py file is executed every time sphinx-build is run. conf.py imports and calls the main function from Doc/tools/build_table.py. This script dynamically builds a table by scraping errno values corresponding to an OS exception and inserting them in the appropriate place. Doc/library/exceptions.rst just uses a literalinclude of the new table that gets built to Lib/test/os_exception_hierarchy.txt (the same directory that holds the original exceptions hierarchy).

Error catching is used so that, in the event of an error, a warning will be raised but the sphinx-build command will still succeed.
History
Date User Action Args
2014-08-17 13:53:29jon.polersetrecipients: + jon.poler, ncoghlan, ezio.melotti, eric.araujo, docs@python
2014-08-17 13:53:28jon.polersetmessageid: <1408283608.84.0.371003450877.issue22014@psf.upfronthosting.co.za>
2014-08-17 13:53:28jon.polerlinkissue22014 messages
2014-08-17 13:53:28jon.polercreate