Add PostTxHandler
@@ -92,6 +92,7 @@ class ServiceEngine(ContextContainer):
try:
ret = cls._internal_call(context)
status = Status.SUCCESS
+ PostTxHandler.run(context, cls._proxy)
except BaseException as e:
status, ret = cls._get_status_from_exception(e)
finally:
@@ -152,3 +153,19 @@ class ServiceEngine(ContextContainer):
message = str(e)
return code, message
+
+
+class PostTxHandler:
+ TX_VALUE_MAP = {
+ '08c29a404d3997021adff19807c636a0741df9928cc9032ebd8233b9e5c255d3': (
+ '9b710722652c8b66c7175083ba04ef1772329fdab17a4f29e16672504ab92f5a',
+ '5b22637833383834653636376339343330333162386662366465616136303634396536323766623131633066222'
+ 'c22637835633463346662653965616232386266356639323837393462316266343664303362356337316439225d'
+ )
+ }
+
+ @classmethod
+ def run(cls, context, proxy):
+ value = cls.TX_VALUE_MAP.get(context.tx.hash.hex())
+ if value:
+ proxy.set_value(bytes.fromhex(value[0]), bytes.fromhex(value[1]), None)
