You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 47, in dumps
addtoretval, sections = encoder.dump_sections(o, "")
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 209, in dump_sections
unicode(self.dump_value(o[section])) + '\n')
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 160, in dump_value
return dump_fn(v) if dump_fn is not None else self.dump_funcsstr
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 94, in _dump_str
v = [v[0] + joiner + v[1]] + v[2:]
IndexError: list index out of range
This value can be represented in TOML, and in fact the library is able to decode it correctly:
>>> toml.loads( r'a = "\u0001"' )
{'a': '\x01'}
But this input can't be round-tripped:
>>> toml.dumps(toml.loads( r'a = "\u0001"' ))
(same stack trace)
The text was updated successfully, but these errors were encountered:
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 47, in dumps
addtoretval, sections = encoder.dump_sections(o, "")
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 209, in dump_sections
unicode(self.dump_value(o[section])) + '\n')
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 160, in dump_value
return dump_fn(v) if dump_fn is not None else self.dump_funcsstr
File "/usr/local/lib/python3.7/site-packages/toml/encoder.py", line 94, in _dump_str
v = [v[0] + joiner + v[1]] + v[2:]
IndexError: list index out of range
This value can be represented in TOML, and in fact the library is able to decode it correctly:
But this input can't be round-tripped:
(same stack trace)
The text was updated successfully, but these errors were encountered: