robertwb / bitcoin-taxes Goto Github PK
View Code? Open in Web Editor NEWCompute capital gains/losses based on your trades.
License: GNU General Public License v3.0
Compute capital gains/losses based on your trades.
License: GNU General Public License v3.0
At a quick glance at the Transaction
class, it is not immediately obvious whether the btc
and usd
attributes include or exclude the fee. It would be nice if there were a comment for this class's definition that clarifies this aspect of the API. (Based on looking at the BitcoindParser
class implementation, I am reasonably confident that it excludes the fee.)
When trying to merge two electrum wallets together, the "assert len(transactions) == 1" in merge asserts.
For example let's just say you created a segwit wallet after happily using the old style wallet. Then you moved your bitcoin from the old wallet to the new segwit wallet. When entering both wallet csvs on the command line, the above assertion will assert on the transaction that transfers the funds from the old wallet to the new wallet.
Adding the below to the ElectrumParser seems to fix the problem:
def merge_some(self, transactions):
return transactions
As a novice to taxes, I found the question "Is this a Sale, Purchase, Expense, or Transfer" confusing. Purchasing something is an expense, and constitutes selling my BTC for that product, which constitutes transferring my BTC to the person I bought it from. I realize that these all mean different things in tax terminology, but it would be more usable for novices if an example were provided for each answer along with this question prompt.
I was trying to take ALL my transactions from Coinbase Pro and generate my tax data. However, I bought/sold more than BTC on that account. I saw here that maybe you were planning on supporting other cryptocurrencies. I was wondering if you have made any progress on that? I might be interested in helping in that effort, but I'm not too familiar with Python. I could probably figure it out, but if you would like help it'd be great if you could give me some pointers on what would be needed to make this work. Thanks!
BitcoinAverage no longer allows gratis access to historical exchange rates. See spesmilo/electrum#5188 . For working historical exchange rate providers, grep https://github.com/spesmilo/electrum/blob/master/electrum/exchange_rate.py for history_ccys
.
If a Bitcoin Core wallet sent funds to multiple addresses in a single transaction, only one of the outputs will be counted.
Several transfers listed in a Coinbase csv file were not matched in the list of transactions derived from a list of public addresses. The result is that several transfers from Coinbase to my public address are incorrectly identified as external transactions.
It appears that the BTC amount reported by Coinbase and the amount actually transferred into my public address do not match exactly. For example, the Coinbase csv file reports one transfer of the amount -0.85301237 BTC, but the actual amount transferred to my public address was 0.8530 BTC. The Coinbase csv file reports the transaction hash in the last column which I can use to confirm the discrepancy between amounts. As a workaround, I have manually edited my Coinbase csv file to split each misidentified transaction into one amount which matches excactly the amount in the public bitcoin transaction, and one additional transaction for the remaining amount which will be categorized as an expense.
Coinbase must have changed the format of the .csv they make available; the rows are much different than as specified in the Coinbase parser and the entire parser will need to be updated.
Hello,
The code seems to have a problem with an internal transfer. I transferred btc from a bitcoin-qt wallet to an electrum wallet. I run the script as follows:
./bitcoin_gains.py --consolidate_bitcoind bitcoin-qt_2017.json electrum_2017.csv
The error I get look like this:
Traceback (most recent call last):
File "./bitcoin_gains.py", line 1354, in <module>
main(parsed_args)
File "./bitcoin_gains.py", line 1226, in main
lost_in_transfer -= lost.btc
AttributeError: 'NoneType' object has no attribute 'btc'
Please let me know if you need me to try a fix.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.