Calling luadata.unserialize('nil') raises an exception (expected behavior: return None). serialize() works going in the other direction, but unserialize() does this:
>>> luadata.serialize(None)
'nil'
>>> luadata.unserialize('nil')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/chris/.local/lib/python3.10/site-packages/luadata/serializer/unserialize.py", line 354, in unserialize
raise Exception(
Exception: Unserialize luadata failed on pos 3:
nil
^
unexpected empty value.
The same thing also happens when nil occurs within a table, e.g., {1,2,nil,4,5}.
Calling
luadata.unserialize('nil')raises an exception (expected behavior: return None).serialize()works going in the other direction, butunserialize()does this:The same thing also happens when nil occurs within a table, e.g.,
{1,2,nil,4,5}.