From 4f909d243950715e305b5dde8d28fa401a121858 Mon Sep 17 00:00:00 2001 From: Guido Günther Date: Wed, 31 May 2023 10:36:52 +0200 Subject: pq: Roll back on all errors Drop the pq branch on all exceptions not only on the ones gbp throws itself. This makes sure the result is consistent in such situations (no patches applied). --- gbp/scripts/pq.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gbp/scripts/pq.py b/gbp/scripts/pq.py index f4b699e5..de9b0e31 100755 --- a/gbp/scripts/pq.py +++ b/gbp/scripts/pq.py @@ -333,7 +333,7 @@ def import_quilt_patches(repo, branch, series, tries, force, pq_from, try: name = os.path.basename(patch.path) apply_and_commit_patch(repo, patch, maintainer, patch.topic, name) - except (GbpError, GitRepositoryError) as e: + except Exception as e: gbp.log.err("Failed to apply '%s': %s" % (patch.path, e)) repo.force_head('HEAD', hard=True) repo.set_branch(branch) -- cgit v1.2.3