Menu

#165 Got TypeError in copying system_message node

None
closed-accepted
nobody
None
5
2021-04-03
2020-03-07
No

I got TypeError on copying system_message node.

Reproducible code:

from docutils.nodes import system_message
system_message().copy()

Error:

$ python test.py
system_message: children=()
Traceback (most recent call last):
  File "test.py", line 2, in <module>
    system_message().copy()
  File "/Users/tkomiya/.pyenv/versions/3.8.1/lib/python3.8/site-packages/docutils/nodes.py", line 1066, in copy
    obj = self.__class__(rawsource=self.rawsource, **self.attributes)
  File "/Users/tkomiya/.pyenv/versions/3.8.1/lib/python3.8/site-packages/docutils/nodes.py", line 1785, in __init__
    Element.__init__(self, rawsource, *children, **attributes)
TypeError: __init__() got multiple values for argument 'rawsource'

Discussion

  • Günter Milde

    Günter Milde - 2020-03-14
    • status: open --> open-fixed
     
  • Günter Milde

    Günter Milde - 2020-03-14

    Applied in r8501. Thank you for the patch.

     
  • Günter Milde

    Günter Milde - 2020-08-26
    • status: open-fixed --> open-accepted
     
  • Günter Milde

    Günter Milde - 2021-04-03
    • status: open-accepted --> closed-accepted
     
  • Günter Milde

    Günter Milde - 2021-04-03

    Fixed in Docutils 0.17.
    Thanks again for your contribution.

     

Log in to post a comment.