Compare commits
No commits in common. "1538567b4651f9daddef534192723ff671693d35" and "2b55ab493596ff06de512dcaf2b052b1b601e061" have entirely different histories.
1538567b46
...
2b55ab4935
@ -18,14 +18,13 @@ pip install web3 tqdm
|
|||||||
The Ghost Preclaim Snapshot Tool provides a straightforward command-line interface for collecting NFT snapshot data across multiple blockchain networks. Before running the tool, ensure you have properly configured your environment with the necessary RPC endpoints and network access credentials.
|
The Ghost Preclaim Snapshot Tool provides a straightforward command-line interface for collecting NFT snapshot data across multiple blockchain networks. Before running the tool, ensure you have properly configured your environment with the necessary RPC endpoints and network access credentials.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
usage: finder.py [-h] --rpc RPC [--block BLOCK] [--bonus BONUS] [--delay DELAY]
|
usage: finder.py [-h] --rpc RPC [--bonus BONUS] [--delay DELAY]
|
||||||
|
|
||||||
EVM NFT Snapshot Collector for Ghostchain Preclaims
|
EVM NFT Snapshot Collector for Ghostchain Preclaims
|
||||||
|
|
||||||
options:
|
options:
|
||||||
-h, --help show this help message and exit
|
-h, --help show this help message and exit
|
||||||
--rpc RPC EVM JSON-RPC Node URL
|
--rpc RPC EVM JSON-RPC Node URL
|
||||||
--block BLOCK Target block number or 'latest' (default: latest)
|
|
||||||
--bonus BONUS Additional JML ownership amounton top of the collateral (default: 6.9 CSPR)
|
--bonus BONUS Additional JML ownership amounton top of the collateral (default: 6.9 CSPR)
|
||||||
--delay DELAY Delay between RPC requests in seconds (default: 0.3)
|
--delay DELAY Delay between RPC requests in seconds (default: 0.3)
|
||||||
```
|
```
|
||||||
|
|||||||
12
finder.py
12
finder.py
@ -12,8 +12,7 @@ GMV_ADDRESS = "0x7EF911f8ef130F73D166468c0068753932357B17"
|
|||||||
def parse_arguments():
|
def parse_arguments():
|
||||||
parser = argparse.ArgumentParser(description="EVM NFT Snapshot Collector for Ghostchain Preclaims")
|
parser = argparse.ArgumentParser(description="EVM NFT Snapshot Collector for Ghostchain Preclaims")
|
||||||
parser.add_argument("--rpc", required=True, help="EVM JSON-RPC Node URL")
|
parser.add_argument("--rpc", required=True, help="EVM JSON-RPC Node URL")
|
||||||
parser.add_argument("--block", default="latest", help="Target block number or 'latest' (default: latest)")
|
parser.add_argument("--bonus", default=6900000000000000000, help="Additional JML ownership amounton top of the collateral (default: 6.9 CSPR)")
|
||||||
parser.add_argument("--bonus", type=int, default=6900000000000000000, help="Additional JML ownership amounton top of the collateral (default: 6.9 CSPR)")
|
|
||||||
parser.add_argument("--delay", type=float, default=0.3, help="Delay between RPC requests in seconds (default: 0.3)")
|
parser.add_argument("--delay", type=float, default=0.3, help="Delay between RPC requests in seconds (default: 0.3)")
|
||||||
return parser.parse_args()
|
return parser.parse_args()
|
||||||
|
|
||||||
@ -76,11 +75,8 @@ def main():
|
|||||||
chain_id = w3.eth.chain_id
|
chain_id = w3.eth.chain_id
|
||||||
print(f"[+] Successfully connected to [{chain_id}] over {args.rpc}.")
|
print(f"[+] Successfully connected to [{chain_id}] over {args.rpc}.")
|
||||||
|
|
||||||
target_block = int(args.block) if args.block.isdigit() else args.block
|
|
||||||
print(f"[+] Snapshot target block: {target_block}")
|
|
||||||
|
|
||||||
contract = get_contract_instance(w3)
|
contract = get_contract_instance(w3)
|
||||||
total_supply = contract.functions.totalSupply().call(block_identifier=target_block)
|
total_supply = contract.functions.totalSupply().call()
|
||||||
print(f"[+] Current totalSupply: {total_supply}")
|
print(f"[+] Current totalSupply: {total_supply}")
|
||||||
time.sleep(args.delay)
|
time.sleep(args.delay)
|
||||||
|
|
||||||
@ -97,9 +93,9 @@ def main():
|
|||||||
current_index = len(snapshot)
|
current_index = len(snapshot)
|
||||||
for token_id in tqdm(range(start_token_id, total_supply), desc=f"Scanning {chain_id}"):
|
for token_id in tqdm(range(start_token_id, total_supply), desc=f"Scanning {chain_id}"):
|
||||||
try:
|
try:
|
||||||
owner = contract.functions.ownerOf(token_id).call(block_identifier=target_block)
|
owner = contract.functions.ownerOf(token_id).call()
|
||||||
time.sleep(args.delay)
|
time.sleep(args.delay)
|
||||||
shares = contract.functions.collateralBalances(token_id, GMV_ADDRESS).call(block_identifier=target_block)
|
shares = contract.functions.collateralBalances(token_id, GMV_ADDRESS).call()
|
||||||
time.sleep(args.delay)
|
time.sleep(args.delay)
|
||||||
|
|
||||||
snapshot.append({
|
snapshot.append({
|
||||||
|
|||||||
14114
snapshots/1.json
14114
snapshots/1.json
File diff suppressed because it is too large
Load Diff
45266
snapshots/10.json
45266
snapshots/10.json
File diff suppressed because it is too large
Load Diff
78320
snapshots/100.json
78320
snapshots/100.json
File diff suppressed because it is too large
Load Diff
2048
snapshots/1088.json
2048
snapshots/1088.json
File diff suppressed because it is too large
Load Diff
10040
snapshots/1284.json
10040
snapshots/1284.json
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
17648
snapshots/137.json
17648
snapshots/137.json
File diff suppressed because it is too large
Load Diff
58334
snapshots/250.json
58334
snapshots/250.json
File diff suppressed because it is too large
Load Diff
@ -1,326 +0,0 @@
|
|||||||
[
|
|
||||||
{
|
|
||||||
"index": 0,
|
|
||||||
"token_id": 1,
|
|
||||||
"address": "0x29c6D9e3c3981e4FcF2AC6B486e4E4210daeA1Ee",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 1,
|
|
||||||
"token_id": 2,
|
|
||||||
"address": "0xD500EFDef75E89Bf6caF5C98F7633575d0049a72",
|
|
||||||
"shares": 82000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 2,
|
|
||||||
"token_id": 3,
|
|
||||||
"address": "0x910b214B05889F337d7D9699C7fD6ef13E6a070e",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 3,
|
|
||||||
"token_id": 4,
|
|
||||||
"address": "0xC6332EBBBcC1a06f60bff25B99447BBB77b2598C",
|
|
||||||
"shares": 4000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 4,
|
|
||||||
"token_id": 5,
|
|
||||||
"address": "0x8C4b5cf540dB07114f63A432Bd8e0d0575d93337",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 5,
|
|
||||||
"token_id": 6,
|
|
||||||
"address": "0xf79bAC4615Fe8631685749Ca6B7ba22bA8c16A90",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 6,
|
|
||||||
"token_id": 7,
|
|
||||||
"address": "0xEe71538ae7677829676BD8dD18259Ed93E6B44e9",
|
|
||||||
"shares": 48000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 7,
|
|
||||||
"token_id": 8,
|
|
||||||
"address": "0x4e16c6D4aB2648b18F921ECF5ee2a8C2ebA78F31",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 8,
|
|
||||||
"token_id": 9,
|
|
||||||
"address": "0x8A506e114DC4fD1d09878336a12bc45749A56174",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 9,
|
|
||||||
"token_id": 10,
|
|
||||||
"address": "0x0B1608A9177F0AE5f03854593Cc1bbEf0435370F",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 10,
|
|
||||||
"token_id": 11,
|
|
||||||
"address": "0x07155E53A112e92dAE2b7D95F42E23264f2F426d",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 11,
|
|
||||||
"token_id": 12,
|
|
||||||
"address": "0xfcAE5296fC6f7D18D817f67d9f57C9233D85e7C2",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 12,
|
|
||||||
"token_id": 13,
|
|
||||||
"address": "0x5C5a38168517B610fe06b00c07a2D45BBB10c2e8",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 13,
|
|
||||||
"token_id": 14,
|
|
||||||
"address": "0xf98891Ec45E6A6E94A8795257Cad9f785bC6704e",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 14,
|
|
||||||
"token_id": 15,
|
|
||||||
"address": "0x6A00B6Fb59809e2515612af627Ea0757F622bebd",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 15,
|
|
||||||
"token_id": 16,
|
|
||||||
"address": "0x69a1C8BAf95EE4A36dCd6E9BCdaAE42B055D4e82",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 16,
|
|
||||||
"token_id": 17,
|
|
||||||
"address": "0xC73085eebfFbe1A6625958B57fa2d0164e7357D5",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 17,
|
|
||||||
"token_id": 18,
|
|
||||||
"address": "0xa4DCbA3e794895A336149646781167B49ECc89E3",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 18,
|
|
||||||
"token_id": 19,
|
|
||||||
"address": "0x7F0Ae078718435e57e70EDa96f1fEAD93BC083C9",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 19,
|
|
||||||
"token_id": 20,
|
|
||||||
"address": "0x609a5e3F532b82cA61550ac0eB5f580681576CF2",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 20,
|
|
||||||
"token_id": 21,
|
|
||||||
"address": "0xB26Cf3FEA043b9fd9a457B023238e5786fC626dD",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 21,
|
|
||||||
"token_id": 22,
|
|
||||||
"address": "0xF4F592540695793F5346088201AaeF4e04785D78",
|
|
||||||
"shares": 16000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 22,
|
|
||||||
"token_id": 23,
|
|
||||||
"address": "0xfB90fD86FBdfc974929a4BdB89f847D55bbeA95d",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 23,
|
|
||||||
"token_id": 24,
|
|
||||||
"address": "0xCd455865575B5095D785BC2BC8425830dc724E56",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 24,
|
|
||||||
"token_id": 25,
|
|
||||||
"address": "0x8BA4aEA65d34F0f5132c8a6371937D9226BaF891",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 25,
|
|
||||||
"token_id": 26,
|
|
||||||
"address": "0x851810716789015FcA0D9F0cab0138a21105eEe7",
|
|
||||||
"shares": 20000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 26,
|
|
||||||
"token_id": 27,
|
|
||||||
"address": "0x0021A7e3541F6C2f5C8593b42b84dd4f8181b00D",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 27,
|
|
||||||
"token_id": 28,
|
|
||||||
"address": "0xDbC90bb7719d146fc3620d53287Fd76dD16D6Eae",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 28,
|
|
||||||
"token_id": 29,
|
|
||||||
"address": "0x7AFe134BAd08E70f3143c5212955239Ade95364d",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 29,
|
|
||||||
"token_id": 30,
|
|
||||||
"address": "0xac6be2B90c939648B2980D048A0E20b61f3c7771",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 30,
|
|
||||||
"token_id": 31,
|
|
||||||
"address": "0xe80b2EC4965A0524ADA634f2D0484C808f43eBb3",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 31,
|
|
||||||
"token_id": 32,
|
|
||||||
"address": "0x47CB7B53db912402ef423DcD9aD7368C4e33E0E9",
|
|
||||||
"shares": 4000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 32,
|
|
||||||
"token_id": 33,
|
|
||||||
"address": "0xD478589b68e162B1D5B3e57323d0b280A96896Bf",
|
|
||||||
"shares": 4000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 33,
|
|
||||||
"token_id": 34,
|
|
||||||
"address": "0x37836D04CD7FEC3fE6d6Eaaa9586217e978E8949",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 34,
|
|
||||||
"token_id": 35,
|
|
||||||
"address": "0x13B745FC35b0BAC9bab9fD20B7C9f46668232607",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 35,
|
|
||||||
"token_id": 36,
|
|
||||||
"address": "0xf6e28c7097EF34FDD1104f222ed2212288fe96D2",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 36,
|
|
||||||
"token_id": 37,
|
|
||||||
"address": "0x03E6Cd9817f8705C213f724d16559f0394d536a3",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 37,
|
|
||||||
"token_id": 38,
|
|
||||||
"address": "0xc41CCfe76eC7f343f14e6E89635b0BcAb34122Eb",
|
|
||||||
"shares": 24000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 38,
|
|
||||||
"token_id": 39,
|
|
||||||
"address": "0xe2363dA723F13166587Fb22de7D74eb97193c3D4",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 39,
|
|
||||||
"token_id": 40,
|
|
||||||
"address": "0x46C02a4fE0829Ea8015344EA83085bE47262B0f9",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 40,
|
|
||||||
"token_id": 41,
|
|
||||||
"address": "0xAAc71bD8E5854C9462Be8b4927B240c04e6c9074",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 41,
|
|
||||||
"token_id": 42,
|
|
||||||
"address": "0x0C71E21Fd2F1d67e54d941E9d484CED63dDdA80D",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 42,
|
|
||||||
"token_id": 43,
|
|
||||||
"address": "0xea78360a4B868d2DB34bB52b019Dbf7BF86FDFBb",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 43,
|
|
||||||
"token_id": 44,
|
|
||||||
"address": "0xA05b6a4e2f422cA0D093befcB14dFeFFC43f5072",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 44,
|
|
||||||
"token_id": 45,
|
|
||||||
"address": "0x90f33568DC6C0289c4cB2cfA5b08b9F2C7adBe01",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 45,
|
|
||||||
"token_id": 46,
|
|
||||||
"address": "0x5204CF9234159bD998C48480898A8cf3B76e8A5a",
|
|
||||||
"shares": 4000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 46,
|
|
||||||
"token_id": 47,
|
|
||||||
"address": "0x5570318da915559586aDa92414084Cf165a8CB89",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 47,
|
|
||||||
"token_id": 48,
|
|
||||||
"address": "0xEF106dC8E339E16d92286c49e44724C7DCda7c48",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 48,
|
|
||||||
"token_id": 49,
|
|
||||||
"address": "0x36fAfaF048bEf5D754C2ffCba91423c4F26E20dD",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 49,
|
|
||||||
"token_id": 50,
|
|
||||||
"address": "0x8Bb46cBa3bC7E4f0c6d1100d0e54950739479107",
|
|
||||||
"shares": 12000000000000000000
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 50,
|
|
||||||
"token_id": 51,
|
|
||||||
"address": "0x9c2C639eE10Cd41AcFB08a68a828A0390d5B808C",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 51,
|
|
||||||
"token_id": 52,
|
|
||||||
"address": "0xdeB133E41BDE139091D4f7Ec4d0668A985904Fa4",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 52,
|
|
||||||
"token_id": 53,
|
|
||||||
"address": "0x56A6360498d566eb1f2D7F628cA932Ac98F45eF9",
|
|
||||||
"shares": 0
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"index": 53,
|
|
||||||
"token_id": 54,
|
|
||||||
"address": "0xE46272e6e86AFdEb5BE457771968914AA0a5FdeE",
|
|
||||||
"shares": 4000000000000000000
|
|
||||||
}
|
|
||||||
]
|
|
||||||
13502
snapshots/42161.json
13502
snapshots/42161.json
File diff suppressed because it is too large
Load Diff
28736
snapshots/43114.json
28736
snapshots/43114.json
File diff suppressed because it is too large
Load Diff
59270
snapshots/56.json
59270
snapshots/56.json
File diff suppressed because it is too large
Load Diff
38732
snapshots/59144.json
38732
snapshots/59144.json
File diff suppressed because it is too large
Load Diff
11492
snapshots/592.json
11492
snapshots/592.json
File diff suppressed because it is too large
Load Diff
5426
snapshots/61.json
5426
snapshots/61.json
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user