From e4412977d8404a2a820c4c1c366604ab6cdc6427 Mon Sep 17 00:00:00 2001 From: Benjamin Schubert Date: Fri, 21 Jun 2019 09:21:02 +0100 Subject: _yaml: Remove useless calls to '_yaml.node_sanitize' Calling '_yaml.dump' will itself call '_yaml.node_sanitize', therefore we can remove all calls to it in places where we directly after call dump. --- src/buildstream/_artifact.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/buildstream/_artifact.py') diff --git a/src/buildstream/_artifact.py b/src/buildstream/_artifact.py index 90d25b4fe..ec80e6417 100644 --- a/src/buildstream/_artifact.py +++ b/src/buildstream/_artifact.py @@ -149,7 +149,7 @@ class Artifact(): # Store public data with tempfile.NamedTemporaryFile(dir=self._tmpdir) as tmp: - _yaml.dump(_yaml.node_sanitize(publicdata), tmp.name) + _yaml.dump(publicdata, tmp.name) public_data_digest = self._cas.add_object(path=tmp.name, link_directly=True) artifact.public_data.CopyFrom(public_data_digest) size += public_data_digest.size_bytes -- cgit v1.2.1