From: Joerg Jaspert Date: Mon, 12 May 2008 12:06:28 +0000 (+0200) Subject: Also replace dump X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=582d389e06828e7c2e73b957eb6ddef1e2f5e2d2;p=dak Also replace dump --- diff --git a/ChangeLog b/ChangeLog index 3b0d04f5..e3e784ab 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,7 @@ * 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 + And also do this for load. 2008-05-10 Stephen Gran * tools/debianqueued-0.9/debianqueued: First pass at a send_mail diff --git a/dak/transitions.py b/dak/transitions.py index e4b6d582..b7e50651 100755 --- a/dak/transitions.py +++ b/dak/transitions.py @@ -28,7 +28,6 @@ import apt_pkg from daklib import database from daklib import utils from daklib.dak_exceptions import TransitionsError -import syck import yaml # Globals @@ -106,10 +105,10 @@ def load_transitions(trans_file): sourcecontent = sourcefile.read() failure = False try: - trans = syck.load(sourcecontent) - except syck.error, msg: + trans = yaml.load(sourcecontent) + except yaml.YAMLError, exc: # Someone fucked it up - print "ERROR: %s" % (msg) + print "ERROR: %s" % (exc) return None # lets do further validation here