Menu

#156 Allow to inject set of directives and roles for parsing reST

None
open
nobody
None
5
2021-09-11
2019-06-09
No

This allows to inject set of directives and roles to RSTStateMachine on runtime. That allows custom reST parsers to switch own set of directives and roles on each parse.

1 Attachments

Discussion

  • Chris Sewell

    Chris Sewell - 2020-08-09

    This appears to be perhaps a partial solution to the issue I raised in https://sourceforge.net/p/docutils/bugs/401/, such that global variables should be removed in favour of passing them through the parsing chain.
    Is this patch being considered?

     
    • engelbert gruber

      things are speedier if there is documentation and tests (i assume you did
      test the patch so why not pass this on)
      in the patch.

      the real hard thing for me to check is ... is this safe ... loading
      directives into docutils

      any thoughts help ?

       

      Last edit: Günter Milde 2025-09-17
  • Chris Sewell

    Chris Sewell - 2020-08-10

    So I can think of any suitable tests, what would your definiton of safe be here?

     
    • engelbert gruber

      So I can think of any suitable tests, what would your definiton of safe be
      here?

      you should . there was a discussion on docutils lists recently (1y) on code
      injection

      some general unittests/functional tests are mandatory (was in aegis SCM)
      considerations remarks for the security documentation ?

       

      Last edit: Günter Milde 2025-09-17
  • Günter Milde

    Günter Milde - 2021-09-11

    Supersedes [patches:#17].

     

    Related

    Patches: #17


    Last edit: Günter Milde 2025-09-17

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.