comparison libervia/backend/tools/sat_defer.py @ 4270:0d7bb4df2343

Reformatted code base using black.
author Goffi <goffi@goffi.org>
date Wed, 19 Jun 2024 18:44:57 +0200
parents 4b842c1fb686
children
comparison
equal deleted inserted replaced
4269:64a85ce8be70 4270:0d7bb4df2343
36 36
37 37
38 def stanza_2_not_found(failure_): 38 def stanza_2_not_found(failure_):
39 """Convert item-not-found StanzaError to exceptions.NotFound""" 39 """Convert item-not-found StanzaError to exceptions.NotFound"""
40 failure_.trap(jabber_error.StanzaError) 40 failure_.trap(jabber_error.StanzaError)
41 if failure_.value.condition == 'item-not-found': 41 if failure_.value.condition == "item-not-found":
42 raise exceptions.NotFound(failure_.value.text or failure_.value.condition) 42 raise exceptions.NotFound(failure_.value.text or failure_.value.condition)
43 return failure_ 43 return failure_
44 44
45 45
46 class DelayedDeferred(object): 46 class DelayedDeferred(object):