]> git.decadent.org.uk Git - dak.git/commitdiff
Fix yaml dump bug in syck by using yaml instead
authorJoerg Jaspert <joerg@debian.org>
Mon, 12 May 2008 11:34:17 +0000 (13:34 +0200)
committerJoerg Jaspert <joerg@debian.org>
Mon, 12 May 2008 11:34:17 +0000 (13:34 +0200)
ChangeLog
dak/transitions.py

index bca99f633a58edc290a1b8813dead4a6e3c49962..3b0d04f5acc96bba3f21acac57fbd012a07c3837 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
+2008-05-12  Joerg Jaspert  <joerg@debian.org>
+
+       * dak/transitions.py: use yaml.dump instead of syck.dump, as syck
+       seems to have a bug in its dump(), causing it to write illegal entries
+
 2008-05-10  Stephen Gran   <sgran@debian.org>
-       * tools/debianqueued-0.9/debianqueued: First pass at a send_mail 
+       * tools/debianqueued-0.9/debianqueued: First pass at a send_mail
          implementation that sucks less
        * Update debian/control to reflect new perl dependency
 
index a37dbef9f1da7b8bb27ec3d388114af47b68a214..e4b6d582fbd8f40f5ea3b048210c46963feabc1d 100755 (executable)
@@ -29,6 +29,7 @@ from daklib import database
 from daklib import utils
 from daklib.dak_exceptions import TransitionsError
 import syck
+import yaml
 
 # Globals
 Cnf = None
@@ -219,7 +220,7 @@ def write_transitions(from_trans):
     temp_lock  = lock_file(trans_temp)
 
     destfile = file(trans_temp, 'w')
-    syck.dump(from_trans, destfile)
+    yaml.dump(from_trans, destfile, default_flow_style=False)
     destfile.close()
 
     os.rename(trans_temp, trans_file)
@@ -259,7 +260,7 @@ def temp_transitions_file(transitions):
     (fd, path) = tempfile.mkstemp("", "transitions", Cnf["Transitions::TempPath"])
     os.chmod(path, 0644)
     f = open(path, "w")
-    syck.dump(transitions, f)
+    yaml.dump(transitions, f, default_flow_style=False)
     return path
 
 ################################################################################