From 7f86d721179d151e138d9e76f3bad12a42d25dc2 Mon Sep 17 00:00:00 2001 From: Ansgar Burchardt Date: Tue, 10 Jul 2012 11:32:59 -0600 Subject: [PATCH] daklib/archive.py: handle unexpected names for byhand files --- daklib/archive.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/daklib/archive.py b/daklib/archive.py index d6f8f2f6..4a1be15c 100644 --- a/daklib/archive.py +++ b/daklib/archive.py @@ -899,7 +899,13 @@ class ArchiveUpload(object): remaining = [] for f in byhand: - package, version, archext = f.filename.split('_', 2) + parts = f.filename.split('_', 2) + if len(parts) != 3: + print "W: unexpected byhand filename {0}. No automatic processing.".format(f.filename) + remaining.append(f) + continue + + package, version, archext = parts arch, ext = archext.split('.', 1) rule = automatic_byhand_packages.get(package) -- 2.39.5