# Musicoin full chain dump (public verification dataset)

A complete extraction of the dead Musicoin chain (MUSIC, network id 7762959) —
**every block, transaction, event log, and contract** — dumped from a local full
node into plain CSV. Load it into PostgreSQL and anyone can browse transactions,
trace fund flows, analyze miners, and verify balance history — including every
input that backs the MoryToken airdrop eligibility and exclusion decisions.

Published so the community does not have to take our word for anything:
the airdrop's eligibility pipeline, the mining-operator exclusions, and the
Merkle root can all be reproduced from this dataset with the open-source
airdrop kit.

## Scale (extracted 2026-06-24)

| Table | Rows |
|---|---|
| blocks | 6,357,618 (genesis → block 6,357,617, up to 2021-10-13) |
| transactions | 43,524,188 |
| logs | 9,252,115 |
| contracts | 122,515 |
| distinct mining wallets | 1,121 |

Roughly 20 GB uncompressed. Extraction integrity: zero errors across all
passes; the transaction count matches the pre-measured total exactly.

## Download artifacts

| Artifact | Contents |
|---|---|
| `musicoin-chain-blocks.tar.gz` | `blocks-0.csv` … `blocks-19.csv` (20 shards) |
| `musicoin-chain-transactions.tar.gz` | `transactions-0.csv` … `transactions-19.csv` (20 shards) |
| `contracts.csv.gz` | all 122,515 contracts (creator, deploy input, bytecode) |
| `logs-all.csv.gz` | all 9,252,115 event logs |
| `musicoin-chain-analysis.tar.gz` | mining-analysis CSVs, contract-creation lists, SQL schema + loaders, this README |
| `SHA256SUMS.txt` | SHA-256 of every artifact above |
| `MANIFEST.sha256` | SHA-256 of every **uncompressed** CSV, so you can verify after extraction |

Verify a download:

```bash
sha256sum -c SHA256SUMS.txt          # artifacts as downloaded
# after extracting everything into one directory:
sha256sum -c MANIFEST.sha256         # raw CSVs
```

## Files inside the analysis bundle

- `chain-schema.sql` — 4 chain tables (blocks / transactions / logs / contracts),
  human-friendly views (`transactions_v`, `blocks_v`), and the mining-analysis
  tables (pools, payouts, funders, address roles, operators).
- `load-chain.sql` — fast `\copy` bulk load + post-load indexes for the full chain.
- `load-mining.sql` — loads the pre-computed mining-analysis CSVs.
- `miner-leaderboard.csv` — blocks mined per miner (count, address).
- `mining-address-roles.csv` — per-address mining role labels (coinbase, payout
  recipient, pool funder) so any address can be checked.
- `pool-summary.csv`, `pool-payouts.csv`, `pool-funders.csv` — pool clustering.
- `operators.csv`, `coinbase-operator.csv` — coinbase wallets grouped into
  operators (one mining business can run many coinbases).
- `contract-creations-*.csv` — raw contract-creation transaction lists.

## Load into PostgreSQL

```bash
createdb musicoin
psql -d musicoin -f chain-schema.sql
# extract all CSVs into the current directory first
psql -d musicoin -f load-chain.sql     # COPY + indexes (large; takes minutes to tens of minutes)
psql -d musicoin -f load-mining.sql    # mining-analysis aggregates (small)
```

Conventions:

- Addresses / hashes: `0x` + lowercase hex. Amounts are kept in wei
  (`NUMERIC`); use the `transactions_v.value_music` view for MUSIC units.
- `to_address IS NULL` = contract-creation transaction (`creates_contract = 1`).
- Time: `timestamp` (unix seconds) or `*_v.block_time` (`TIMESTAMPTZ`).
- v1 limitation: transaction status (success/failure) and `gasUsed` are not
  included (that requires all 43.5M receipts — possible as a separate pass).

## Example queries

```sql
-- top miners
SELECT miner, COUNT(*) AS blocks FROM blocks GROUP BY miner ORDER BY 2 DESC LIMIT 20;

-- full history of one address
SELECT * FROM transactions_v
WHERE from_address = '0x..' OR to_address = '0x..'
ORDER BY block_number;

-- large transfers (fund-flow tracing)
SELECT block_time, from_address, to_address, value_music
FROM transactions_v WHERE value_music > 100000 ORDER BY value_music DESC;

-- event logs for a contract (tokens etc.)
SELECT * FROM logs WHERE address = '0x..' LIMIT 100;
```

## Reproduce the airdrop eligibility yourself

1. Load this dataset into PostgreSQL (above).
2. Download the open-source Morylen Airdrop Kit (linked from
   `morytoken.com/airdrop/source`) and run its SQL pipeline — you get the same
   eligible set and the same exclusions, each with on-chain evidence.
3. Run the kit's Merkle builder — you get the same Merkle root that backs the
   airdrop.

## Notes

- This dataset contains **on-chain public data only**: addresses, hashes,
  amounts, bytecode. No personal data, no keys, no off-chain records.
- Provided as-is, for verification and research. The Musicoin chain is dead
  (last block 2021-10-13); this dump is final and will not change.
