You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by no...@apache.org on 2020/12/29 12:50:27 UTC

[buildstream] 01/01: Fixes #470: tracking modifies elements

This is an automated email from the ASF dual-hosted git repository.

not-in-ldap pushed a commit to branch Qinusty/470-bst-track-yaml-indent
in repository https://gitbox.apache.org/repos/asf/buildstream.git

commit 9e6838882cecfe8a3e5247a4905018e76db9fa44
Author: Josh Smith <jo...@codethink.co.uk>
AuthorDate: Tue Aug 7 16:44:14 2018 +0100

    Fixes #470: tracking modifies elements
    
    This fixes the issue by preventing the nodes being sorted within the
    toplevel node prior to being dumped to file.
    
    HOWEVER: This breaks the interaction with include functionality and storing
    refs inline.
---
 buildstream/source.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/buildstream/source.py b/buildstream/source.py
index d58bfe2..24acb68 100644
--- a/buildstream/source.py
+++ b/buildstream/source.py
@@ -752,7 +752,7 @@ class Source(Plugin):
                 # Save the ref in the originating file
                 #
                 try:
-                    _yaml.dump(_yaml.node_sanitize(provenance.toplevel), provenance.filename.name)
+                    _yaml.dump(provenance.toplevel, provenance.filename.name)
                 except OSError as e:
                     raise SourceError("{}: Error saving source reference to '{}': {}"
                                       .format(self, provenance.filename.name, e),