From c79456e95803f3fe53fde125cc8a275b0fe2bf8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20P=C3=A9pin?= Date: Mon, 12 Sep 2016 23:24:18 +0200 Subject: [PATCH] Syntaxe py3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `except e1, e2:` n'est pas valide en python3, il faut des parenthèses. --- kfet/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kfet/views.py b/kfet/views.py index a08be40b..98c4760a 100644 --- a/kfet/views.py +++ b/kfet/views.py @@ -803,7 +803,7 @@ def kpsul(request): is_protected=False, valid_from__lte=timezone.now(), valid_to__gte=timezone.now()).get() initial['checkout'] = checkout - except Checkout.DoesNotExist, Checkout.MultipleObjectsReturned: + except (Checkout.DoesNotExist, Checkout.MultipleObjectsReturned): pass data['checkout_form'] = KPsulCheckoutForm(initial=initial) operation_formset = KPsulOperationFormSet(queryset=Operation.objects.none())