When you send a payment from an ilp-kit A 'user' account in Ledger A to the ilp-kit B connector's account in Ledger B there is an issue with the payment.
Ledger A believes the payment has failed (Transfer expired) while Ledger B has the payment as success.
This what I see in ilp-kit A:
[connector] 2016-12-11T16:40:12.385Z connector:route-builder info creating quote sourceAddress=es.eur.hola.mike sourceAmount=undefined destinationAddress=gb.gbp.milton.javi.de2085c0-170d-469d-9605-e37d61c9588b destinationAmount=0.93 destinationPrecisionAndScale=undefined slippage=undefined
[ledger] 2016-12-11T16:40:12.396Z ledger:koa info <-- POST /messages
[ledger] 2016-12-11T16:40:12.409Z ledger:koa info --> POST /messages 201 13ms 471B
[ledger] 2016-12-11T16:40:12.442Z ledger:koa info <-- PUT /transfers/b6f9f737-7ab7-49ff-8420-44e46219ceba
[ledger] 2016-12-11T16:40:12.573Z ledger:koa info --> PUT /transfers/b6f9f737-7ab7-49ff-8420-44e46219ceba 201 131ms 713B
[connector] 2016-12-11T16:40:12.586Z connector:route-builder info constructing destination transfer sourceLedger=es.eur.hola. sourceAmount=1.12 ilpHeader={"account":"gb.gbp.milton.javi.de2085c0-170d-469d-9605-e37d61c9588b","amount":"0.93","data":{"expires_at":"2016-12-11T16:40:42.316Z"}}
[api] 2016-12-11T16:40:22.423Z error-handler ERROR { Error: Transfer expired, money returned
[api] at Timeout.setTimeout (/home/javi/ilp-kit/node_modules/ilp/src/lib/sender.js:177:20)
[api] at ontimeout (timers.js:365:14)
[api] at tryOnTimeout (timers.js:237:5)
[api] at Timer.listOnTimeout (timers.js:207:5) headers: { 'Access-Control-Allow-Origin': '*' } }
[api] 2016-12-11T16:40:22.429Z error-handler ERROR Error: Transfer expired, money returned
[api] at Timeout.setTimeout (/home/javi/ilp-kit/node_modules/ilp/src/lib/sender.js:177:20)
[api] at ontimeout (timers.js:365:14)
[api] at tryOnTimeout (timers.js:237:5)
[api] at Timer.listOnTimeout (timers.js:207:5)
[api] 2016-12-11T16:40:22.430Z http INFO xxx PUT /payments/2b45e9fb-dfae-455e-b347-c9ffafb0dc70 500 10s -
[api]
[api] InternalServerError: Error: Transfer expired, money returned
[api] at Object.throw (/home/javi/ilp-kit/node_modules/koa.io/node_modules/koa/lib/context.js:90:23)
[api] at Object.handleError (/home/javi/ilp-kit/node_modules/five-bells-shared/middlewares/error-handler.js:18:19)
[api] at throw (native)
[api] at onRejected (/home/javi/ilp-kit/node_modules/koa.io/node_modules/co/index.js:77:24)
And this is ilp-kit B (see the AssetsNotTradedError):
[ledger] 2016-12-11T16:40:12.307Z ledger:rpcHandler info new ws subscriber for javi:*
[api] 2016-12-11T16:40:12.342Z sequelize DEBUG Executing (default): INSERT INTO "Payments" ("id","source_account","destination_user","destination_account","destination_amount","state","execution_condition","created_at","updated_at") VALUES ('28cfb53e-f6de-4d0a-924f-b4123ac33830','mike',2,'https://milton.ilp.network/ledger/accounts/javi',0.93,'pending','cc:0:3:tT0Ke0X3JpiFCQrPI89gbUn5EKlUaGLs0jcy5gkLjAU:32','2016-12-11 16:40:12.325 +00:00','2016-12-11 16:40:12.325 +00:00') RETURNING *;
[api] 2016-12-11T16:40:12.353Z http INFO --> POST /receivers/javi 200 98ms -
[ledger] 2016-12-11T16:40:12.612Z ledger:koa info <-- PUT /transfers/24dbf87d-996f-4182-81a0-48392df4acff
[ledger] 2016-12-11T16:40:12.793Z ledger:koa info --> PUT /transfers/24dbf87d-996f-4182-81a0-48392df4acff 201 182ms 829B
[connector] 2016-12-11T16:40:12.807Z connector:route-builder info constructing destination transfer sourceLedger=gb.gbp.milton. sourceAmount=0.93 ilpHeader={"account":"gb.gbp.milton.javi.de2085c0-170d-469d-9605-e37d61c9588b","amount":"0.93","data":{"expires_at":"2016-12-11T16:40:42.316Z"}}
[connector] 2016-12-11T16:40:12.813Z connector:subscriptions warn error processing notification: AssetsNotTradedError: This connector does not support the given asset pair
[ledger] 2016-12-11T16:40:12.835Z ledger:koa info <-- PUT /transfers/24dbf87d-996f-4182-81a0-48392df4acff/fulfillment
[ledger] 2016-12-11T16:40:12.981Z ledger:koa info --> PUT /transfers/24dbf87d-996f-4182-81a0-48392df4acff/fulfillment 201 146ms 48B
[api] 2016-12-11T16:40:12.985Z sequelize DEBUG Executing (default): SELECT "id", "source_user", "source_account", "source_amount", "source_name", "source_image_url", "destination_user", "destination_account", "destination_amount", "destination_name", "destination_image_url", "transfer", "state", "message", "execution_condition", "created_at", "completed_at", "updated_at" FROM "Payments" AS "Payment" WHERE "Payment"."execution_condition" = 'cc:0:3:tT0Ke0X3JpiFCQrPI89gbUn5EKlUaGLs0jcy5gkLjAU:32' LIMIT 1;
[api] 2016-12-11T16:40:13.027Z sequelize DEBUG Executing (default): UPDATE "Payments" SET "state"='success',"updated_at"='2016-12-11 16:40:13.013 +00:00' WHERE "id" = '28cfb53e-f6de-4d0a-924f-b4123ac33830'
What I am doing is sending from mike to connectorB in the diagram below:
If you send the payment to any other account it behaves as expected I think.
This over three months old, a lot happened since it was reported. AFAIK this is not currently an issue, but please reopen if this is still reproducable.
When you send a payment from an
ilp-kit A
'user' account in Ledger A to theilp-kit B
connector's account in Ledger B there is an issue with the payment.Ledger A believes the payment has failed (Transfer expired) while Ledger B has the payment as success.
This what I see in
ilp-kit A
:And this is
ilp-kit B
(see theAssetsNotTradedError
):What I am doing is sending from
mike
toconnectorB
in the diagram below:If you send the payment to any other account it behaves as expected I think.