text = """
This is the apache license text.
"""
import saneyaml
data = {"text": text}
yaml_string = saneyaml.dump(data, indent=4)
loaded_yaml = saneyaml.load(yaml_string)
assert text == loaded_yaml["text"]
And this fails with:
---------------------------------------------------------------------------
AssertionError Traceback (most recent call last)
Cell In[5], line 1
----> 1 assert text == loaded_yaml["text"]
AssertionError:
Consider the following example:
And this fails with: