Repository navigation
Add Bitcoin blockchain in BigQuery dataset - #86
Merged
Merged
Conversation
Dataset preview (1 changed entry)How these entries will read once merged, straight from the generator. Bitcoin blockchain in BigQuery
Links, in the order they will render:
Generated by |
0xB10C
reviewed
Nov 5, 2026
b10claude
force-pushed
the
add-bigquery-crypto-bitcoin
branch
from
November 5, 2026 19:50
de3a04e to
c86dd37
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
datasets/bigquery-crypto-bitcoin.toml.Sources
Every claim in the entry, and what backs it.
The dataset id, the tables and the views
bigquery-public-data.crypto_bitcoinis named in Google's own announcement,"Introducing six new cryptocurrencies in BigQuery Public Datasets—and how to
analyze them", by Allen Day (Google Cloud) and Evgeny Medvedev (author of
Blockchain ETL), 6 February 2019. The same post names
inputs,outputsandtransactions, and the "views that map all blockchain datasets to adouble-entry book data structure".
dags/resources/stages/enrich/schemas/blocks.jsonandtransactions.jsoninblockchain-etl/bitcoin-etl-airflow.blocks: hash, size, stripped_size, weight, number, version, merkle_root,timestamp, timestamp_month, nonce, bits, coinbase_param, transaction_count.
transactions: hash, size, virtual_size, version, lock_time, block_hash,block_number, block_timestamp, block_timestamp_month, input_count,
output_count, input_value, output_value, is_coinbase, fee, and repeated
inputsandoutputsrecords.spent_output_index, script_asm, script_hex, sequence,
required_signatures, type, repeated addresses and value; each output the
same minus the spend fields. That is what the entry means by "nested
alongside their addresses, script, type and value".
inputsandoutputsare views over the transactions table, not separatetables:
dags/bitcoinetl/build_load_dag.pycreates them withadd_create_view_tasks('inputs', ...)and('outputs', ...), while thetables it loads are
blocksandtransactions. Hence "two tables ... plusviews that flatten them".
Where it comes from
crypto_{chain},crypto_{chain}_rawandcrypto_{chain}_temp, socrypto_bitcoinis thepublished one.
blockchain-etl/bitcoin-etlis the extraction code, MIT per GitHub's licencedetection, and reads from a Bitcoin node's JSON-RPC interface. The Airflow
DAGs in
bitcoin-etl-airflowrun the export and load.Access and cost
https://docs.cloud.google.com/bigquery/public-data: a public dataset is"stored in BigQuery and made available to the general public through the
Google Cloud Public Dataset Program", Google pays the storage, the user pays
only for queries, and "the first 1 TB per month is free". That is the basis
for the caveat that querying needs a Google Cloud project.
Licence, and what I could not verify
announcement, not the 2018 "Bitcoin in BigQuery" post, not the public
datasets documentation. The Cloud Marketplace listing and the Kaggle mirror
both refuse automated requests, so I did not read either.
second-hand, so the entry does not state it. The licence field says
"Not specified" and names the MIT extraction code, matching how
btcnodes-io-snapshotshandles the same situation.the licence field with whatever Google states there.
Two judgement calls for the maintainer
format: the data is BigQuery tables, and none of the allowed values inFORMATSdescribes that. The entry listscsv,jsonlandparquet, whichare the formats BigQuery exports query results in (Avro too, which is not in
the enum). If you would rather add a value such as
bigqueryorsql-table,that is a separate change to
build.pyplus this one line, and I will openit.
downloadlink, because the dataset is not downloadable: it isqueried in place. The links give the Marketplace listing, the extraction
code, the schemas and the access terms instead.
Not verified
and field lists come from the loader repository that builds the public
dataset, which is the closest primary source available from here.
the tables are. The description states no cadence, per the timeless rule.
🤖 Generated with Claude Code
https://claude.ai/code/session_01EQFKPv3mB1J6LFakJnjNsd