[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6GYTQ98AMTG5G6HFDPHTFFW":3,"skill-same:01M6GYTQ98AMTG5G6HFDPHTFFW":73},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":16,"sourceHtmlUrl":17,"categories":18,"keywords":19,"publishedAt":31,"linkOnly":32,"markdownContent":33,"markdownBody":34,"frontMatter":35,"refName":36,"commitSha":37,"skillDirectory":38,"forksCount":39,"repositoryHtmlUrl":40,"repositoryHomepageUrl":6,"ownerHtmlUrl":41,"ownerBlogUrl":42,"ownerDescription":43,"updatedAt":44,"install":45,"resources":58},"01M6GYTQ98AMTG5G6HFDPHTFFW","handle-a-payment-reorged-out",null,"Use when a credited crypto payment disappears from the canonical chain. Detects the reorg, halts fulfilment, and re-clears the payment only when it reappears with the right confirmations.","jiayaoqijia\u002Fcryptoskill","jiayaoqijia","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F1453879?v=4","01M6GMYTX7Q7S504VC6E756ENR","YQ","01M6GMYV1QKJ1CC75MTTGT9PR0",81,"MIT","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-handle-a-payment-reorged-out\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-handle-a-payment-reorged-out\u002FSKILL.md",[],[20,21,22,23,24,25,26,27,28,29,30],"payment","handle a payment reorged out","use","only","crypto","chain","it","with","re","canonical","when","2026-11-10 10:12:30",false,"---\nname: handle-a-payment-reorged-out\ndescription: Use when a credited crypto payment disappears from the canonical chain. Detects the reorg, halts fulfilment, and re-clears the payment only when it reappears with the right confirmations.\n---\n\n# Handle a payment that reorgs out\n\nA tx seen in a block is not a tx in the canonical chain. When the source tx vanishes from the head, any fulfilment already triggered is unbacked; detect it, freeze downstream actions, and re-clear on canonical evidence.\n\n## Procedure\n\n1. Watch the head each block: re-check that each credited tx hash is still in its block and that the block is still canonical.\n   `cast tx $TXHASH --rpc-url $RPC | grep -E \"blockNumber|blockHash\"`\n   Compare that `blockHash` with the block you credited against.\n2. On a mismatch, mark the payment `reorged` and stop any fulfilment that can still be stopped (shipping, further sends, entitlement grants).\n3. Re-derive the canonical chain and look for the tx in the new blocks:\n   `cast receipt $TXHASH --rpc-url $RPC` — a different `blockNumber` means the tx was re-included later; a null result means it is not on the canonical chain.\n4. Distinguish a re-inclusion (tx re-mined elsewhere) from a drop (tx gone, possibly replaced by a higher-fee tx or never valid).\n5. Re-clear the payment only when the tx is canonical and accumulated confirmations exceed the value-tiered threshold.\n6. If the tx never returns, void the credit and notify the counterparty with the hash and the block-hash mismatch as evidence.\n7. Log the head block hashes around the incident so the depth and cause are reconstructable.\n\n## Pitfalls\n\n- Crediting at first inclusion on a probabilistic chain with no reorg watch; the policy, not the incident, is the failure.\n- Assuming a disappeared tx is a double-spend attack when a natural 2-block reorg explains it.\n- Fulfilling instantly on soft-confirm and being unable to claw back a shipped good.\n- Re-crediting twice when the tx reappears: match on tx hash and suppress the duplicate.\n- Watching only your own tx and missing that the whole block was reorged, invalidating sibling payments too.\n- A tx can be re-included with a different effect if it was one of several in the block; re-check the whole batch, not one hash.\n- Re-clear logic that keys on amount can double-credit when two identical payments exist; key on tx hash.\n\n## Verification\n\n    cast tx $TXHASH --rpc-url $RPC | grep blockHash\n    # must equal the blockHash of the current canonical block at that height\n\nReport the tx hash, the block hash at credit time versus now, the reorg depth, and the payment's final status.\n","# Handle a payment that reorgs out\n\nA tx seen in a block is not a tx in the canonical chain. When the source tx vanishes from the head, any fulfilment already triggered is unbacked; detect it, freeze downstream actions, and re-clear on canonical evidence.\n\n## Procedure\n\n1. Watch the head each block: re-check that each credited tx hash is still in its block and that the block is still canonical.\n   `cast tx $TXHASH --rpc-url $RPC | grep -E \"blockNumber|blockHash\"`\n   Compare that `blockHash` with the block you credited against.\n2. On a mismatch, mark the payment `reorged` and stop any fulfilment that can still be stopped (shipping, further sends, entitlement grants).\n3. Re-derive the canonical chain and look for the tx in the new blocks:\n   `cast receipt $TXHASH --rpc-url $RPC` — a different `blockNumber` means the tx was re-included later; a null result means it is not on the canonical chain.\n4. Distinguish a re-inclusion (tx re-mined elsewhere) from a drop (tx gone, possibly replaced by a higher-fee tx or never valid).\n5. Re-clear the payment only when the tx is canonical and accumulated confirmations exceed the value-tiered threshold.\n6. If the tx never returns, void the credit and notify the counterparty with the hash and the block-hash mismatch as evidence.\n7. Log the head block hashes around the incident so the depth and cause are reconstructable.\n\n## Pitfalls\n\n- Crediting at first inclusion on a probabilistic chain with no reorg watch; the policy, not the incident, is the failure.\n- Assuming a disappeared tx is a double-spend attack when a natural 2-block reorg explains it.\n- Fulfilling instantly on soft-confirm and being unable to claw back a shipped good.\n- Re-crediting twice when the tx reappears: match on tx hash and suppress the duplicate.\n- Watching only your own tx and missing that the whole block was reorged, invalidating sibling payments too.\n- A tx can be re-included with a different effect if it was one of several in the block; re-check the whole batch, not one hash.\n- Re-clear logic that keys on amount can double-credit when two identical payments exist; key on tx hash.\n\n## Verification\n\n    cast tx $TXHASH --rpc-url $RPC | grep blockHash\n    # must equal the blockHash of the current canonical block at that height\n\nReport the tx hash, the block hash at credit time versus now, the reorg depth, and the payment's final status.\n",{"name":5,"description":7},"main","3df1d0d67b30ff15236561f8c0f9f06d33f42dfd","skills\u002Fpayments\u002F0xklen-handle-a-payment-reorged-out",17,"https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia","https:\u002F\u002Feth2030.com","Hardcore infra. Building @alt-research and applied cryptography.","2026-11-12 02:28:42",{"source":8,"skillName":5,"commands":46,"prompt":56,"zipAvailable":57},[47,50,53],{"tool":48,"command":49},"npx","npx skills add jiayaoqijia\u002Fcryptoskill --skill handle-a-payment-reorged-out",{"tool":51,"command":52},"bunx","bunx skills add jiayaoqijia\u002Fcryptoskill --skill handle-a-payment-reorged-out",{"tool":54,"command":55},"pnpm","pnpm dlx skills add jiayaoqijia\u002Fcryptoskill --skill handle-a-payment-reorged-out","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-handle-a-payment-reorged-out\u002FSKILL.md",true,[59,63,69],{"path":60,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":62,"sourceHtmlUrl":16},"LICENSE","许可证",1063,{"path":64,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":67,"sourceHtmlUrl":68},"SOURCE.md","REFERENCE","参考文档",354,"https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-handle-a-payment-reorged-out\u002FSOURCE.md",{"path":70,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":71,"sourceHtmlUrl":72},"TRUST.auto.yaml",2217,"https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-handle-a-payment-reorged-out\u002FTRUST.auto.yaml",[74,102,125,143,156,166],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":78,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":31},"01M712C436EQYE43342Q4E7GG1","recipe-performance","Diagnose a specific MetaMask user flow's real-app performance and Sentry critical-user-flow telemetry with deterministic mm-harness recipes. Use for CUF boundaries, cold\u002Fwarm\u002Fbackground-resume behavior, latency regressions, lifecycle tags, duplicate or blocking network requests, long tasks, layout\u002Fpaint cost, screen redraws, React rerenders, or browser trace analysis where tests alone cannot prove the real app.","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fwallets\u002Fmetamask-official-recipe-performance\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fwallets\u002Fmetamask-official-recipe-performance\u002FSKILL.md",[],[82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101],"performance","recipe performance","recipe","mm","sentry","harness","app","deterministic","recipes","flow","cold","critical","analysis","tasks","react","browser","layout","screen","network","metamask",{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":106,"licenseFileUrl":107,"sourceHtmlUrl":108,"categories":109,"keywords":110,"publishedAt":31},"01M70XT2F8A5CQZ81JBP98KSW3","mexc-spot-websocket","MEXC Spot WebSocket workflows for public streams, protobuf handling, depth maintenance, listen keys, and private streams without exposing API keys.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fexchanges\u002Fmncrftfrcnm-mexc-spot-websocket\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fexchanges\u002Fmncrftfrcnm-mexc-spot-websocket\u002FSKILL.md",[],[111,112,113,114,115,116,117,118,119,120,121,122,123,124],"mexc spot websocket","spot","websocket","api","workflows","public","listen","streams","depth","keys","for","api keys","maintenance","protobuf",{"skillNo":126,"name":127,"nameZh":6,"description":128,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":106,"licenseFileUrl":129,"sourceHtmlUrl":130,"categories":131,"keywords":132,"publishedAt":31},"01M70XT0MBXN3WZY1BKN0CPNKR","mexc-spot-rest","MEXC Spot REST workflows for public data, signed account requests, orders, wallet\u002Fadmin actions, and secure signing without exposing API keys.","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fexchanges\u002Fmncrftfrcnm-mexc-spot-rest\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fexchanges\u002Fmncrftfrcnm-mexc-spot-rest\u002FSKILL.md",[],[133,112,134,135,136,137,138,122,121,120,139,140,141,116,142,115,114],"mexc spot rest","REST","admin","signing","Wallet","requests","actions","secure","data","orders",{"skillNo":144,"name":145,"nameZh":6,"description":146,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":106,"licenseFileUrl":147,"sourceHtmlUrl":148,"categories":149,"keywords":150,"publishedAt":31},"01M70XSYSVZ2N0N91XCAR2CAK0","mexc-futures-websocket","MEXC Futures WebSocket workflows for public streams, private account\u002Forder\u002Fposition streams, ping\u002Fpong, subscriptions, and depth maintenance.","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fexchanges\u002Fmncrftfrcnm-mexc-futures-websocket\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fexchanges\u002Fmncrftfrcnm-mexc-futures-websocket\u002FSKILL.md",[],[151,152,113,153,154,123,121,155,119,118,116,115],"mexc futures websocket","futures","position","ping","subscriptions",{"skillNo":157,"name":158,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":159,"sourceHtmlUrl":160,"categories":161,"keywords":162,"publishedAt":31},"01M6H0ZWHVE5W04WG2DKQE2SQC","0xklen-version-and-refresh-sanctions-lists","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-version-and-refresh-sanctions-lists\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-version-and-refresh-sanctions-lists\u002FSKILL.md",[],[163,164,165],"refresh","0xklen version and refresh sanctions lists","version",{"skillNo":167,"name":168,"nameZh":6,"description":169,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":170,"sourceHtmlUrl":171,"categories":172,"keywords":173,"publishedAt":31},"01M6H0Z28Q3R8J0S799GJQWXM3","verify-tests-cover-changed-lines","Use when a PR adds code that the existing suite may not exercise. Measures patch coverage — the share of newly changed lines hit by tests — before approving.","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-verify-tests-cover-changed-lines\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Fjiayaoqijia\u002Fcryptoskill\u002Fblob\u002Fmain\u002Fskills\u002Fpayments\u002F0xklen-verify-tests-cover-changed-lines\u002FSKILL.md",[],[174,175,176,177,178,179,180,22,181,182,183],"tests","cover","verify tests cover changed lines","verify","coverage","pr","exercise","patch","code","share"]