From 566a84e58fc6d22755d8d10ec02a45b52792a532 Mon Sep 17 00:00:00 2001 From: Rigidity Date: Sun, 22 Dec 2024 13:01:42 -0500 Subject: [PATCH] prepare --- ...2709dfb80d6f2f9f1a6f5c4e786d1229ef71.json} | 12 +++- ...78d481723d70c83c4370f4c528a574a69e7eb.json | 32 +++++++++++ ...77848d185fe964f760a24dbddd7ac6d468a0.json} | 12 +++- ...da01d241729c617dcefb200e4490bafb75ef.json} | 6 +- ...18e235c5256e0100eed8abc271e26797b6b9.json} | 12 +++- ...6ce4643b69c232ce2b99e744d53389e624d93.json | 56 +++++++++++++++++++ ...b9eb07cdbb3db67577d60aaf68808189390c.json} | 12 +++- ...eb1005b78639b105df2a17d5ca836a6c01ae3.json | 20 +++++++ ...afe76649825fd9dd0ffa36178c49e1b50298.json} | 16 ++++-- ...7e14e2b00fa4c6e5391a43f0ddce9f4884f30.json | 20 ------- ...8fee9876a7631c78ef362f0db3cc14f604f7.json} | 12 +++- ...7e1ee3ff813f79d2b21f1361d74d443bdb4e.json} | 12 +++- ...69b3c660ef93675cfcaed6bc00ddd5f1cfccd.json | 56 +++++++++++++++++++ ...47d554f6a3e1a690562bf7c89a261124bcaf.json} | 16 ++++-- ...c12c762017109c6d108461dcca0b019a5e7bc.json | 12 ---- ...881b1a1e9aa555cdcd928375db425fd2e3f4.json} | 12 +++- ...712469e66b6c4f7661f81c44c278d8ef48841.json | 20 +++++++ ...4ea68e9fbe9caa5bf25c8873c3e82262ade5.json} | 6 +- ...ff370567e194f16fe55aae3059a98bccd28e3.json | 12 ++++ ...2564a3a205ff98d3229860a9779c90f87f51d.json | 32 ----------- ...620a087f4c146d0f18cc1789d1b605d2e38a.json} | 12 +++- 21 files changed, 296 insertions(+), 104 deletions(-) rename .sqlx/{query-b5347dfdb32bbb3981e9b61ff81353b362bd8da071e1c74335621d8795c73eec.json => query-045e6a0a8a35b38903a5286ffd642709dfb80d6f2f9f1a6f5c4e786d1229ef71.json} (60%) create mode 100644 .sqlx/query-1f02b69aed85e466920cf1890d478d481723d70c83c4370f4c528a574a69e7eb.json rename .sqlx/{query-e9e775311ede2d4f25dd266dfcb4791592228ce35a1fdd21ca2b4f1cf3d3f8bd.json => query-26dab9a39b882f9fe0e4a89ed48677848d185fe964f760a24dbddd7ac6d468a0.json} (61%) rename .sqlx/{query-c03961b6da91bf8a86937bf0789884632bb1e1040b87ae9a478645dd5497e3b8.json => query-26f35685c520800fcac9aa39af5eda01d241729c617dcefb200e4490bafb75ef.json} (54%) rename .sqlx/{query-47860ec7d51fb4a817cadd380db316dda2b562874ab963de6b38f6ae7ca3b63c.json => query-3455d57f87f09ff7427e217ec33a18e235c5256e0100eed8abc271e26797b6b9.json} (73%) create mode 100644 .sqlx/query-37be827023b07548be1086e56746ce4643b69c232ce2b99e744d53389e624d93.json rename .sqlx/{query-7ebdf54a81d6537f12c049814aba81d1335cd65af432f80c756411bb143adfb4.json => query-4011b9386f81df90337244a02f62b9eb07cdbb3db67577d60aaf68808189390c.json} (61%) create mode 100644 .sqlx/query-43fea9780be9a988b54b6eccadeeb1005b78639b105df2a17d5ca836a6c01ae3.json rename .sqlx/{query-0abd29e0cb343d6e2ff6f70ca82d8de7f92ce17c3eb4f8e37f9bc138eba5ea6f.json => query-6f0dc15ff563432245e377fdd3f5afe76649825fd9dd0ffa36178c49e1b50298.json} (67%) delete mode 100644 .sqlx/query-841892053a942af83d7da7987d07e14e2b00fa4c6e5391a43f0ddce9f4884f30.json rename .sqlx/{query-8af33efdac0becc2327e5d2d0b43668d6d374232c779a645b54dd8ff2ebeab93.json => query-8bc0f86f64bd3c1777698091cf638fee9876a7631c78ef362f0db3cc14f604f7.json} (64%) rename .sqlx/{query-5392fdc9a2639c97cc4499738c652585883f04923429fd3e2f2bdea33833d5c0.json => query-954b654c6c64953f1de0f848adbe7e1ee3ff813f79d2b21f1361d74d443bdb4e.json} (70%) create mode 100644 .sqlx/query-9cccce73aaab4fd808c931d06ab69b3c660ef93675cfcaed6bc00ddd5f1cfccd.json rename .sqlx/{query-ccf24ae534c77cdbfa1e6030ad4e275d7abafd101b48cbc32ecd53b76c8016cf.json => query-a46bf8e0626ebbf2dd33cbe01ffb47d554f6a3e1a690562bf7c89a261124bcaf.json} (70%) delete mode 100644 .sqlx/query-b8bafc13b117fa6214fee9d8860c12c762017109c6d108461dcca0b019a5e7bc.json rename .sqlx/{query-f60979af832a6d514b6249708dfdeb44da635c7ad061dd532bbc4066c164c162.json => query-c075300477ef8ced7f28ee8a8cce881b1a1e9aa555cdcd928375db425fd2e3f4.json} (72%) create mode 100644 .sqlx/query-c3eda0483d42cf1dc0ab7ea0fc8712469e66b6c4f7661f81c44c278d8ef48841.json rename .sqlx/{query-5c8780401ea7fd6853c75c07bdafed8b9f51bdb4fda19c73e2c8d8c48a7262ca.json => query-d2de3c63e1eb71899f0635182fe94ea68e9fbe9caa5bf25c8873c3e82262ade5.json} (50%) create mode 100644 .sqlx/query-ddb6fea0a5725460382c09bf61fff370567e194f16fe55aae3059a98bccd28e3.json delete mode 100644 .sqlx/query-e154315b64b14d911eddc57cdc52564a3a205ff98d3229860a9779c90f87f51d.json rename .sqlx/{query-f0fa54e43ced89c756b17cd2334c74110d4db62d8daf71c0890f63a176a204ea.json => query-f56eed783707ace0eea106e902c4620a087f4c146d0f18cc1789d1b605d2e38a.json} (66%) diff --git a/.sqlx/query-b5347dfdb32bbb3981e9b61ff81353b362bd8da071e1c74335621d8795c73eec.json b/.sqlx/query-045e6a0a8a35b38903a5286ffd642709dfb80d6f2f9f1a6f5c4e786d1229ef71.json similarity index 60% rename from .sqlx/query-b5347dfdb32bbb3981e9b61ff81353b362bd8da071e1c74335621d8795c73eec.json rename to .sqlx/query-045e6a0a8a35b38903a5286ffd642709dfb80d6f2f9f1a6f5c4e786d1229ef71.json index 76148566..e57901f7 100644 --- a/.sqlx/query-b5347dfdb32bbb3981e9b61ff81353b362bd8da071e1c74335621d8795c73eec.json +++ b/.sqlx/query-045e6a0a8a35b38903a5286ffd642709dfb80d6f2f9f1a6f5c4e786d1229ef71.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `coin_states`\n INNER JOIN `cat_coins` ON `coin_states`.coin_id = `cat_coins`.coin_id\n WHERE `asset_id` = ?\n AND `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `coin_states`\n INNER JOIN `cat_coins` ON `coin_states`.coin_id = `cat_coins`.coin_id\n WHERE `asset_id` = ?\n AND `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "b5347dfdb32bbb3981e9b61ff81353b362bd8da071e1c74335621d8795c73eec" + "hash": "045e6a0a8a35b38903a5286ffd642709dfb80d6f2f9f1a6f5c4e786d1229ef71" } diff --git a/.sqlx/query-1f02b69aed85e466920cf1890d478d481723d70c83c4370f4c528a574a69e7eb.json b/.sqlx/query-1f02b69aed85e466920cf1890d478d481723d70c83c4370f4c528a574a69e7eb.json new file mode 100644 index 00000000..1bc7e5be --- /dev/null +++ b/.sqlx/query-1f02b69aed85e466920cf1890d478d481723d70c83c4370f4c528a574a69e7eb.json @@ -0,0 +1,32 @@ +{ + "db_name": "SQLite", + "query": "\n SELECT `coin_states`.`parent_coin_id`, `coin_states`.`puzzle_hash`, `coin_states`.`amount` FROM `coin_states`\n LEFT JOIN `transaction_spends` ON `coin_states`.`coin_id` = `transaction_spends`.`coin_id`\n LEFT JOIN `offered_coins` ON `coin_states`.`coin_id` = `offered_coins`.`coin_id`\n LEFT JOIN `offers` ON `offered_coins`.`offer_id` = `offers`.`offer_id`\n WHERE `coin_states`.`spent_height` IS NULL\n AND `transaction_spends`.`coin_id` IS NULL\n AND (`offered_coins`.`coin_id` IS NULL OR `offers`.`status` > 0)\n AND `coin_states`.`transaction_id` IS NULL\n AND `kind` = 1\n ", + "describe": { + "columns": [ + { + "name": "parent_coin_id", + "ordinal": 0, + "type_info": "Blob" + }, + { + "name": "puzzle_hash", + "ordinal": 1, + "type_info": "Blob" + }, + { + "name": "amount", + "ordinal": 2, + "type_info": "Blob" + } + ], + "parameters": { + "Right": 0 + }, + "nullable": [ + false, + false, + false + ] + }, + "hash": "1f02b69aed85e466920cf1890d478d481723d70c83c4370f4c528a574a69e7eb" +} diff --git a/.sqlx/query-e9e775311ede2d4f25dd266dfcb4791592228ce35a1fdd21ca2b4f1cf3d3f8bd.json b/.sqlx/query-26dab9a39b882f9fe0e4a89ed48677848d185fe964f760a24dbddd7ac6d468a0.json similarity index 61% rename from .sqlx/query-e9e775311ede2d4f25dd266dfcb4791592228ce35a1fdd21ca2b4f1cf3d3f8bd.json rename to .sqlx/query-26dab9a39b882f9fe0e4a89ed48677848d185fe964f760a24dbddd7ac6d468a0.json index e302d53c..1bcd68a0 100644 --- a/.sqlx/query-e9e775311ede2d4f25dd266dfcb4791592228ce35a1fdd21ca2b4f1cf3d3f8bd.json +++ b/.sqlx/query-26dab9a39b882f9fe0e4a89ed48677848d185fe964f760a24dbddd7ac6d468a0.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `coin_states`\n INNER JOIN `p2_coins` ON `coin_states`.`coin_id` = `p2_coins`.`coin_id`\n WHERE `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `coin_states`\n INNER JOIN `did_coins` ON `coin_states`.coin_id = `did_coins`.coin_id\n WHERE `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "e9e775311ede2d4f25dd266dfcb4791592228ce35a1fdd21ca2b4f1cf3d3f8bd" + "hash": "26dab9a39b882f9fe0e4a89ed48677848d185fe964f760a24dbddd7ac6d468a0" } diff --git a/.sqlx/query-c03961b6da91bf8a86937bf0789884632bb1e1040b87ae9a478645dd5497e3b8.json b/.sqlx/query-26f35685c520800fcac9aa39af5eda01d241729c617dcefb200e4490bafb75ef.json similarity index 54% rename from .sqlx/query-c03961b6da91bf8a86937bf0789884632bb1e1040b87ae9a478645dd5497e3b8.json rename to .sqlx/query-26f35685c520800fcac9aa39af5eda01d241729c617dcefb200e4490bafb75ef.json index 13f1c0c2..300d3fbe 100644 --- a/.sqlx/query-c03961b6da91bf8a86937bf0789884632bb1e1040b87ae9a478645dd5497e3b8.json +++ b/.sqlx/query-26f35685c520800fcac9aa39af5eda01d241729c617dcefb200e4490bafb75ef.json @@ -1,12 +1,12 @@ { "db_name": "SQLite", - "query": "\n UPDATE `coin_states` SET `synced` = 1, `hint` = ? WHERE `coin_id` = ?\n ", + "query": "\n UPDATE `coin_states` SET `synced` = 1, `hint` = ?, `kind` = ? WHERE `coin_id` = ?\n ", "describe": { "columns": [], "parameters": { - "Right": 2 + "Right": 3 }, "nullable": [] }, - "hash": "c03961b6da91bf8a86937bf0789884632bb1e1040b87ae9a478645dd5497e3b8" + "hash": "26f35685c520800fcac9aa39af5eda01d241729c617dcefb200e4490bafb75ef" } diff --git a/.sqlx/query-47860ec7d51fb4a817cadd380db316dda2b562874ab963de6b38f6ae7ca3b63c.json b/.sqlx/query-3455d57f87f09ff7427e217ec33a18e235c5256e0100eed8abc271e26797b6b9.json similarity index 73% rename from .sqlx/query-47860ec7d51fb4a817cadd380db316dda2b562874ab963de6b38f6ae7ca3b63c.json rename to .sqlx/query-3455d57f87f09ff7427e217ec33a18e235c5256e0100eed8abc271e26797b6b9.json index 20e453f7..b0852c02 100644 --- a/.sqlx/query-47860ec7d51fb4a817cadd380db316dda2b562874ab963de6b38f6ae7ca3b63c.json +++ b/.sqlx/query-3455d57f87f09ff7427e217ec33a18e235c5256e0100eed8abc271e26797b6b9.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `coin_states`\n INNER JOIN `p2_coins` ON `coin_states`.`coin_id` = `p2_coins`.`coin_id`\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `coin_states` WHERE `kind` = 1\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "47860ec7d51fb4a817cadd380db316dda2b562874ab963de6b38f6ae7ca3b63c" + "hash": "3455d57f87f09ff7427e217ec33a18e235c5256e0100eed8abc271e26797b6b9" } diff --git a/.sqlx/query-37be827023b07548be1086e56746ce4643b69c232ce2b99e744d53389e624d93.json b/.sqlx/query-37be827023b07548be1086e56746ce4643b69c232ce2b99e744d53389e624d93.json new file mode 100644 index 00000000..de4ab9f2 --- /dev/null +++ b/.sqlx/query-37be827023b07548be1086e56746ce4643b69c232ce2b99e744d53389e624d93.json @@ -0,0 +1,56 @@ +{ + "db_name": "SQLite", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `coin_states`\n INNER JOIN `nft_coins` ON `coin_states`.coin_id = `nft_coins`.coin_id\n WHERE `launcher_id` = ?\n AND `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ", + "describe": { + "columns": [ + { + "name": "parent_coin_id", + "ordinal": 0, + "type_info": "Blob" + }, + { + "name": "puzzle_hash", + "ordinal": 1, + "type_info": "Blob" + }, + { + "name": "amount", + "ordinal": 2, + "type_info": "Blob" + }, + { + "name": "spent_height", + "ordinal": 3, + "type_info": "Integer" + }, + { + "name": "created_height", + "ordinal": 4, + "type_info": "Integer" + }, + { + "name": "transaction_id", + "ordinal": 5, + "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" + } + ], + "parameters": { + "Right": 1 + }, + "nullable": [ + false, + false, + false, + true, + true, + true, + false + ] + }, + "hash": "37be827023b07548be1086e56746ce4643b69c232ce2b99e744d53389e624d93" +} diff --git a/.sqlx/query-7ebdf54a81d6537f12c049814aba81d1335cd65af432f80c756411bb143adfb4.json b/.sqlx/query-4011b9386f81df90337244a02f62b9eb07cdbb3db67577d60aaf68808189390c.json similarity index 61% rename from .sqlx/query-7ebdf54a81d6537f12c049814aba81d1335cd65af432f80c756411bb143adfb4.json rename to .sqlx/query-4011b9386f81df90337244a02f62b9eb07cdbb3db67577d60aaf68808189390c.json index f3d2a2a6..ad18a4d2 100644 --- a/.sqlx/query-7ebdf54a81d6537f12c049814aba81d1335cd65af432f80c756411bb143adfb4.json +++ b/.sqlx/query-4011b9386f81df90337244a02f62b9eb07cdbb3db67577d60aaf68808189390c.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `coin_states`\n INNER JOIN `did_coins` ON `coin_states`.coin_id = `did_coins`.coin_id\n WHERE `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `coin_states`\n INNER JOIN `nft_coins` ON `coin_states`.coin_id = `nft_coins`.coin_id\n WHERE `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "7ebdf54a81d6537f12c049814aba81d1335cd65af432f80c756411bb143adfb4" + "hash": "4011b9386f81df90337244a02f62b9eb07cdbb3db67577d60aaf68808189390c" } diff --git a/.sqlx/query-43fea9780be9a988b54b6eccadeeb1005b78639b105df2a17d5ca836a6c01ae3.json b/.sqlx/query-43fea9780be9a988b54b6eccadeeb1005b78639b105df2a17d5ca836a6c01ae3.json new file mode 100644 index 00000000..bf657e58 --- /dev/null +++ b/.sqlx/query-43fea9780be9a988b54b6eccadeeb1005b78639b105df2a17d5ca836a6c01ae3.json @@ -0,0 +1,20 @@ +{ + "db_name": "SQLite", + "query": "\n SELECT DISTINCT height FROM (\n SELECT created_height as height FROM coin_states INDEXED BY `coin_created`\n WHERE created_height IS NOT NULL\n UNION ALL\n SELECT spent_height as height FROM coin_states INDEXED BY `coin_spent`\n WHERE spent_height IS NOT NULL\n )\n GROUP BY height\n ", + "describe": { + "columns": [ + { + "name": "height", + "ordinal": 0, + "type_info": "Integer" + } + ], + "parameters": { + "Right": 0 + }, + "nullable": [ + true + ] + }, + "hash": "43fea9780be9a988b54b6eccadeeb1005b78639b105df2a17d5ca836a6c01ae3" +} diff --git a/.sqlx/query-0abd29e0cb343d6e2ff6f70ca82d8de7f92ce17c3eb4f8e37f9bc138eba5ea6f.json b/.sqlx/query-6f0dc15ff563432245e377fdd3f5afe76649825fd9dd0ffa36178c49e1b50298.json similarity index 67% rename from .sqlx/query-0abd29e0cb343d6e2ff6f70ca82d8de7f92ce17c3eb4f8e37f9bc138eba5ea6f.json rename to .sqlx/query-6f0dc15ff563432245e377fdd3f5afe76649825fd9dd0ffa36178c49e1b50298.json index 5aac3f19..77ad767c 100644 --- a/.sqlx/query-0abd29e0cb343d6e2ff6f70ca82d8de7f92ce17c3eb4f8e37f9bc138eba5ea6f.json +++ b/.sqlx/query-6f0dc15ff563432245e377fdd3f5afe76649825fd9dd0ffa36178c49e1b50298.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `did_coins`\n INNER JOIN `coin_states` ON `coin_states`.coin_id = `did_coins`.coin_id\n WHERE `launcher_id` = ?\n AND `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `created_height`, `spent_height`, `transaction_id`, `kind`\n FROM `coin_states`\n WHERE `synced` = 0 AND `created_height` IS NOT NULL\n ORDER BY `spent_height` ASC\n LIMIT ?\n ", "describe": { "columns": [ { @@ -19,12 +19,12 @@ "type_info": "Blob" }, { - "name": "spent_height", + "name": "created_height", "ordinal": 3, "type_info": "Integer" }, { - "name": "created_height", + "name": "spent_height", "ordinal": 4, "type_info": "Integer" }, @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "0abd29e0cb343d6e2ff6f70ca82d8de7f92ce17c3eb4f8e37f9bc138eba5ea6f" + "hash": "6f0dc15ff563432245e377fdd3f5afe76649825fd9dd0ffa36178c49e1b50298" } diff --git a/.sqlx/query-841892053a942af83d7da7987d07e14e2b00fa4c6e5391a43f0ddce9f4884f30.json b/.sqlx/query-841892053a942af83d7da7987d07e14e2b00fa4c6e5391a43f0ddce9f4884f30.json deleted file mode 100644 index 73e97c71..00000000 --- a/.sqlx/query-841892053a942af83d7da7987d07e14e2b00fa4c6e5391a43f0ddce9f4884f30.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "db_name": "SQLite", - "query": "\n SELECT `coin_states`.`amount` FROM `coin_states` INDEXED BY `coin_spent`\n INNER JOIN `p2_coins` ON `coin_states`.`coin_id` = `p2_coins`.`coin_id`\n LEFT JOIN `transaction_spends` ON `coin_states`.`coin_id` = `transaction_spends`.`coin_id`\n WHERE `coin_states`.`spent_height` IS NULL\n AND `transaction_spends`.`coin_id` IS NULL\n ", - "describe": { - "columns": [ - { - "name": "amount", - "ordinal": 0, - "type_info": "Blob" - } - ], - "parameters": { - "Right": 0 - }, - "nullable": [ - false - ] - }, - "hash": "841892053a942af83d7da7987d07e14e2b00fa4c6e5391a43f0ddce9f4884f30" -} diff --git a/.sqlx/query-8af33efdac0becc2327e5d2d0b43668d6d374232c779a645b54dd8ff2ebeab93.json b/.sqlx/query-8bc0f86f64bd3c1777698091cf638fee9876a7631c78ef362f0db3cc14f604f7.json similarity index 64% rename from .sqlx/query-8af33efdac0becc2327e5d2d0b43668d6d374232c779a645b54dd8ff2ebeab93.json rename to .sqlx/query-8bc0f86f64bd3c1777698091cf638fee9876a7631c78ef362f0db3cc14f604f7.json index d6c4172e..56ce0ecb 100644 --- a/.sqlx/query-8af33efdac0becc2327e5d2d0b43668d6d374232c779a645b54dd8ff2ebeab93.json +++ b/.sqlx/query-8bc0f86f64bd3c1777698091cf638fee9876a7631c78ef362f0db3cc14f604f7.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `coin_states`\n INNER JOIN `nft_coins` ON `coin_states`.coin_id = `nft_coins`.coin_id\n WHERE `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `coin_states`\n WHERE `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n AND `kind` = 1\n ORDER BY `created_height`, `coin_states`.`coin_id` LIMIT ? OFFSET ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "8af33efdac0becc2327e5d2d0b43668d6d374232c779a645b54dd8ff2ebeab93" + "hash": "8bc0f86f64bd3c1777698091cf638fee9876a7631c78ef362f0db3cc14f604f7" } diff --git a/.sqlx/query-5392fdc9a2639c97cc4499738c652585883f04923429fd3e2f2bdea33833d5c0.json b/.sqlx/query-954b654c6c64953f1de0f848adbe7e1ee3ff813f79d2b21f1361d74d443bdb4e.json similarity index 70% rename from .sqlx/query-5392fdc9a2639c97cc4499738c652585883f04923429fd3e2f2bdea33833d5c0.json rename to .sqlx/query-954b654c6c64953f1de0f848adbe7e1ee3ff813f79d2b21f1361d74d443bdb4e.json index c3a3b2cb..cb585e3d 100644 --- a/.sqlx/query-5392fdc9a2639c97cc4499738c652585883f04923429fd3e2f2bdea33833d5c0.json +++ b/.sqlx/query-954b654c6c64953f1de0f848adbe7e1ee3ff813f79d2b21f1361d74d443bdb4e.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `created_height`, `spent_height`, `transaction_id`\n FROM `coin_states`\n WHERE `coin_id` = ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `created_height`, `spent_height`, `transaction_id`, `kind`\n FROM `coin_states` INDEXED BY `coin_spent`\n WHERE `spent_height` = ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "5392fdc9a2639c97cc4499738c652585883f04923429fd3e2f2bdea33833d5c0" + "hash": "954b654c6c64953f1de0f848adbe7e1ee3ff813f79d2b21f1361d74d443bdb4e" } diff --git a/.sqlx/query-9cccce73aaab4fd808c931d06ab69b3c660ef93675cfcaed6bc00ddd5f1cfccd.json b/.sqlx/query-9cccce73aaab4fd808c931d06ab69b3c660ef93675cfcaed6bc00ddd5f1cfccd.json new file mode 100644 index 00000000..cfa24e9b --- /dev/null +++ b/.sqlx/query-9cccce73aaab4fd808c931d06ab69b3c660ef93675cfcaed6bc00ddd5f1cfccd.json @@ -0,0 +1,56 @@ +{ + "db_name": "SQLite", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `did_coins`\n INNER JOIN `coin_states` ON `coin_states`.coin_id = `did_coins`.coin_id\n WHERE `launcher_id` = ?\n AND `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ", + "describe": { + "columns": [ + { + "name": "parent_coin_id", + "ordinal": 0, + "type_info": "Blob" + }, + { + "name": "puzzle_hash", + "ordinal": 1, + "type_info": "Blob" + }, + { + "name": "amount", + "ordinal": 2, + "type_info": "Blob" + }, + { + "name": "spent_height", + "ordinal": 3, + "type_info": "Integer" + }, + { + "name": "created_height", + "ordinal": 4, + "type_info": "Integer" + }, + { + "name": "transaction_id", + "ordinal": 5, + "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" + } + ], + "parameters": { + "Right": 1 + }, + "nullable": [ + false, + false, + false, + true, + true, + true, + false + ] + }, + "hash": "9cccce73aaab4fd808c931d06ab69b3c660ef93675cfcaed6bc00ddd5f1cfccd" +} diff --git a/.sqlx/query-ccf24ae534c77cdbfa1e6030ad4e275d7abafd101b48cbc32ecd53b76c8016cf.json b/.sqlx/query-a46bf8e0626ebbf2dd33cbe01ffb47d554f6a3e1a690562bf7c89a261124bcaf.json similarity index 70% rename from .sqlx/query-ccf24ae534c77cdbfa1e6030ad4e275d7abafd101b48cbc32ecd53b76c8016cf.json rename to .sqlx/query-a46bf8e0626ebbf2dd33cbe01ffb47d554f6a3e1a690562bf7c89a261124bcaf.json index 3dd6dcec..23d42697 100644 --- a/.sqlx/query-ccf24ae534c77cdbfa1e6030ad4e275d7abafd101b48cbc32ecd53b76c8016cf.json +++ b/.sqlx/query-a46bf8e0626ebbf2dd33cbe01ffb47d554f6a3e1a690562bf7c89a261124bcaf.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `cat_coins` INDEXED BY `cat_asset_id`\n INNER JOIN `coin_states` ON `coin_states`.coin_id = `cat_coins`.coin_id\n WHERE `asset_id` = ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `created_height`, `spent_height`, `transaction_id`, `kind`\n FROM `coin_states` INDEXED BY `coin_created`\n WHERE `created_height` = ?\n ", "describe": { "columns": [ { @@ -19,12 +19,12 @@ "type_info": "Blob" }, { - "name": "spent_height", + "name": "created_height", "ordinal": 3, "type_info": "Integer" }, { - "name": "created_height", + "name": "spent_height", "ordinal": 4, "type_info": "Integer" }, @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "ccf24ae534c77cdbfa1e6030ad4e275d7abafd101b48cbc32ecd53b76c8016cf" + "hash": "a46bf8e0626ebbf2dd33cbe01ffb47d554f6a3e1a690562bf7c89a261124bcaf" } diff --git a/.sqlx/query-b8bafc13b117fa6214fee9d8860c12c762017109c6d108461dcca0b019a5e7bc.json b/.sqlx/query-b8bafc13b117fa6214fee9d8860c12c762017109c6d108461dcca0b019a5e7bc.json deleted file mode 100644 index 9dfb7cd1..00000000 --- a/.sqlx/query-b8bafc13b117fa6214fee9d8860c12c762017109c6d108461dcca0b019a5e7bc.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "db_name": "SQLite", - "query": "\n REPLACE INTO `p2_coins` (`coin_id`) VALUES (?)\n ", - "describe": { - "columns": [], - "parameters": { - "Right": 1 - }, - "nullable": [] - }, - "hash": "b8bafc13b117fa6214fee9d8860c12c762017109c6d108461dcca0b019a5e7bc" -} diff --git a/.sqlx/query-f60979af832a6d514b6249708dfdeb44da635c7ad061dd532bbc4066c164c162.json b/.sqlx/query-c075300477ef8ced7f28ee8a8cce881b1a1e9aa555cdcd928375db425fd2e3f4.json similarity index 72% rename from .sqlx/query-f60979af832a6d514b6249708dfdeb44da635c7ad061dd532bbc4066c164c162.json rename to .sqlx/query-c075300477ef8ced7f28ee8a8cce881b1a1e9aa555cdcd928375db425fd2e3f4.json index 28c85851..420f5c77 100644 --- a/.sqlx/query-f60979af832a6d514b6249708dfdeb44da635c7ad061dd532bbc4066c164c162.json +++ b/.sqlx/query-c075300477ef8ced7f28ee8a8cce881b1a1e9aa555cdcd928375db425fd2e3f4.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `created_height`, `spent_height`, `transaction_id`\n FROM `coin_states`\n WHERE `synced` = 0 AND `created_height` IS NOT NULL\n ORDER BY `spent_height` ASC\n LIMIT ?\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `created_height`, `spent_height`, `transaction_id`, `kind`\n FROM `coin_states`\n WHERE `coin_id` = ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "f60979af832a6d514b6249708dfdeb44da635c7ad061dd532bbc4066c164c162" + "hash": "c075300477ef8ced7f28ee8a8cce881b1a1e9aa555cdcd928375db425fd2e3f4" } diff --git a/.sqlx/query-c3eda0483d42cf1dc0ab7ea0fc8712469e66b6c4f7661f81c44c278d8ef48841.json b/.sqlx/query-c3eda0483d42cf1dc0ab7ea0fc8712469e66b6c4f7661f81c44c278d8ef48841.json new file mode 100644 index 00000000..b87d7a5a --- /dev/null +++ b/.sqlx/query-c3eda0483d42cf1dc0ab7ea0fc8712469e66b6c4f7661f81c44c278d8ef48841.json @@ -0,0 +1,20 @@ +{ + "db_name": "SQLite", + "query": "\n SELECT `coin_states`.`amount` FROM `coin_states` INDEXED BY `coin_kind_spent`\n LEFT JOIN `transaction_spends` ON `coin_states`.`coin_id` = `transaction_spends`.`coin_id`\n WHERE `coin_states`.`spent_height` IS NULL\n AND `transaction_spends`.`coin_id` IS NULL\n AND `kind` = 1\n ", + "describe": { + "columns": [ + { + "name": "amount", + "ordinal": 0, + "type_info": "Blob" + } + ], + "parameters": { + "Right": 0 + }, + "nullable": [ + false + ] + }, + "hash": "c3eda0483d42cf1dc0ab7ea0fc8712469e66b6c4f7661f81c44c278d8ef48841" +} diff --git a/.sqlx/query-5c8780401ea7fd6853c75c07bdafed8b9f51bdb4fda19c73e2c8d8c48a7262ca.json b/.sqlx/query-d2de3c63e1eb71899f0635182fe94ea68e9fbe9caa5bf25c8873c3e82262ade5.json similarity index 50% rename from .sqlx/query-5c8780401ea7fd6853c75c07bdafed8b9f51bdb4fda19c73e2c8d8c48a7262ca.json rename to .sqlx/query-d2de3c63e1eb71899f0635182fe94ea68e9fbe9caa5bf25c8873c3e82262ade5.json index 7e4cec75..28ec57a7 100644 --- a/.sqlx/query-5c8780401ea7fd6853c75c07bdafed8b9f51bdb4fda19c73e2c8d8c48a7262ca.json +++ b/.sqlx/query-d2de3c63e1eb71899f0635182fe94ea68e9fbe9caa5bf25c8873c3e82262ade5.json @@ -1,10 +1,10 @@ { "db_name": "SQLite", - "query": "\n SELECT COUNT(*) AS `count`\n FROM `p2_coins`\n WHERE `coin_id` = ?\n ", + "query": "\n SELECT `kind`\n FROM `coin_states`\n WHERE `coin_id` = ?\n ", "describe": { "columns": [ { - "name": "count", + "name": "kind", "ordinal": 0, "type_info": "Integer" } @@ -16,5 +16,5 @@ false ] }, - "hash": "5c8780401ea7fd6853c75c07bdafed8b9f51bdb4fda19c73e2c8d8c48a7262ca" + "hash": "d2de3c63e1eb71899f0635182fe94ea68e9fbe9caa5bf25c8873c3e82262ade5" } diff --git a/.sqlx/query-ddb6fea0a5725460382c09bf61fff370567e194f16fe55aae3059a98bccd28e3.json b/.sqlx/query-ddb6fea0a5725460382c09bf61fff370567e194f16fe55aae3059a98bccd28e3.json new file mode 100644 index 00000000..594803ff --- /dev/null +++ b/.sqlx/query-ddb6fea0a5725460382c09bf61fff370567e194f16fe55aae3059a98bccd28e3.json @@ -0,0 +1,12 @@ +{ + "db_name": "SQLite", + "query": "\n UPDATE `coin_states` SET `kind` = 1 WHERE `coin_id` = ?\n ", + "describe": { + "columns": [], + "parameters": { + "Right": 1 + }, + "nullable": [] + }, + "hash": "ddb6fea0a5725460382c09bf61fff370567e194f16fe55aae3059a98bccd28e3" +} diff --git a/.sqlx/query-e154315b64b14d911eddc57cdc52564a3a205ff98d3229860a9779c90f87f51d.json b/.sqlx/query-e154315b64b14d911eddc57cdc52564a3a205ff98d3229860a9779c90f87f51d.json deleted file mode 100644 index 0fed4e27..00000000 --- a/.sqlx/query-e154315b64b14d911eddc57cdc52564a3a205ff98d3229860a9779c90f87f51d.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "db_name": "SQLite", - "query": "\n SELECT `coin_states`.`parent_coin_id`, `coin_states`.`puzzle_hash`, `coin_states`.`amount` FROM `coin_states`\n INNER JOIN `p2_coins` ON `coin_states`.`coin_id` = `p2_coins`.`coin_id`\n LEFT JOIN `transaction_spends` ON `coin_states`.`coin_id` = `transaction_spends`.`coin_id`\n LEFT JOIN `offered_coins` ON `coin_states`.`coin_id` = `offered_coins`.`coin_id`\n LEFT JOIN `offers` ON `offered_coins`.`offer_id` = `offers`.`offer_id`\n WHERE `coin_states`.`spent_height` IS NULL\n AND `transaction_spends`.`coin_id` IS NULL\n AND (`offered_coins`.`coin_id` IS NULL OR `offers`.`status` > 0)\n AND `coin_states`.`transaction_id` IS NULL\n ", - "describe": { - "columns": [ - { - "name": "parent_coin_id", - "ordinal": 0, - "type_info": "Blob" - }, - { - "name": "puzzle_hash", - "ordinal": 1, - "type_info": "Blob" - }, - { - "name": "amount", - "ordinal": 2, - "type_info": "Blob" - } - ], - "parameters": { - "Right": 0 - }, - "nullable": [ - false, - false, - false - ] - }, - "hash": "e154315b64b14d911eddc57cdc52564a3a205ff98d3229860a9779c90f87f51d" -} diff --git a/.sqlx/query-f0fa54e43ced89c756b17cd2334c74110d4db62d8daf71c0890f63a176a204ea.json b/.sqlx/query-f56eed783707ace0eea106e902c4620a087f4c146d0f18cc1789d1b605d2e38a.json similarity index 66% rename from .sqlx/query-f0fa54e43ced89c756b17cd2334c74110d4db62d8daf71c0890f63a176a204ea.json rename to .sqlx/query-f56eed783707ace0eea106e902c4620a087f4c146d0f18cc1789d1b605d2e38a.json index 8e97a9e8..bb75854e 100644 --- a/.sqlx/query-f0fa54e43ced89c756b17cd2334c74110d4db62d8daf71c0890f63a176a204ea.json +++ b/.sqlx/query-f56eed783707ace0eea106e902c4620a087f4c146d0f18cc1789d1b605d2e38a.json @@ -1,6 +1,6 @@ { "db_name": "SQLite", - "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`\n FROM `coin_states`\n INNER JOIN `nft_coins` ON `coin_states`.coin_id = `nft_coins`.coin_id\n WHERE `launcher_id` = ?\n AND `spent_height` IS NULL\n AND `created_height` IS NOT NULL\n ", + "query": "\n SELECT `parent_coin_id`, `puzzle_hash`, `amount`, `spent_height`, `created_height`, `transaction_id`, `kind`\n FROM `cat_coins` INDEXED BY `cat_asset_id`\n INNER JOIN `coin_states` ON `coin_states`.coin_id = `cat_coins`.coin_id\n WHERE `asset_id` = ?\n ", "describe": { "columns": [ { @@ -32,6 +32,11 @@ "name": "transaction_id", "ordinal": 5, "type_info": "Blob" + }, + { + "name": "kind", + "ordinal": 6, + "type_info": "Integer" } ], "parameters": { @@ -43,8 +48,9 @@ false, true, true, - true + true, + false ] }, - "hash": "f0fa54e43ced89c756b17cd2334c74110d4db62d8daf71c0890f63a176a204ea" + "hash": "f56eed783707ace0eea106e902c4620a087f4c146d0f18cc1789d1b605d2e38a" }