Bull Bitcoin is a Canadian non-custodial bitcoin exchange. I used to be a customer, but abandoned the service because personal record-keeping and tax compliance is a pain β their data exports are garbage.
Bull Bitcoin offers a comically inflexible "Export my orders" button that gives you a so-called .csv
file that has intractable problems.
Bull Bitcoin support has declined written suggestions to make their data more interoperative.
This repo contains the code I use to transform their garbage data into a format I import into a spreadsheet. In other words, this repo takes shitty data and makes a usable .csv
file I can actually use.
In short,
-
It's not a
.csv
file according to the CSV, Comma Separated Values (RFC 4180) spec. -
It's not a
.csv
file that's anything like what you might expect. -
The Bull Bitcoin
.csv
file's timestamp columns aren't ISO 8601 compliant, so parsing dates from the data is a pain in the ass. A Bull Bitcoin timestamp value looks like this:Mon Dec 07 2020 09:31:21 GMT+0000 (UTC)
which appears to be from RFC 5322 which has no support in all desktop spreadsheets I've tried. Good luck with that. -
Basically the Bull Bitcoin
.csv
file is a minimum effort, give-zero-shits text dump from a database upon which they've slapped a.csv
file extension. If you're familiar with PostgreSQL, thinkpg_dump
β that's what they effectively give you, from whatever database Bull Bitcoin uses.
Therefore
- The Bull Bitcoin
.csv
file can't be directly imported to any standard spreadsheet or database, and everything about this raw data is a pain.
Still to do:
- A proper binary you can invoke conventionally from your MacOS, Linux, or Windows OS.
This is written in Rust. At this stage you can clone this repo and call it with cargo run
or with cargo build
and invoking the binary from the ./target/debug/
folder.
This presumes the so-called ".csv
" file is named bull-bitcoin-orders.csv
located in the local ~/Downloads
folder.
cargo run -- ~/Downloads/bull-bitcoin-orders.csv
This presumes the so-called ".csv
" file is named bull-bitcoin-orders.csv
located in the local ~/Downloads
folder.
./target/debug/bull-bitcoin-export-fix ~/Downloads/bull-bitcoin-orders.csv