Updates
2025-10-09
Important bug fix – TOB potentially miscalculated for merged transactions
What was the bug?
On July 30th, tobcalc changed how it handled positive and negative transaction values when importing transactions (see commit).
Before this update, all transaction values were treated as positive (absolute values only).
After the change, the sign of each transaction was preserved.
This caused an issue when merging transactions: the merged value was calculated using the signed values instead of their absolute values.
For example:
If you merged two transactions with values 500 and -500, tobcalc summed them to 0, leading to a merged value and TOB of 0.
The correct behavior should have been |500| + |-500| = 1000, with TOB calculated on that total.
What is the fix?
The fix ensures that the absolute value of each transaction is used when merging.
Does this affect me?
You were affected if, between 2025-07-30 and 2025-10-09, you:
- Used the merge feature, and
- Merged transactions with different signs (e.g., a buy and a sell).
Note: Merging transactions with different signs is not an intended use case. If you did this, please double-check whether those merges were appropriate.
If all merged transactions had the same sign, you are not affected.
What should I do if this affected me?
We recommend recalculating the TOB for any affected transactions within the specified date range. If you discover a discrepancy, pay the difference to the tax authorities and inform them of the mistake.
Why shouldn’t transactions with different signs be merged?
The merge feature was designed for cases where an order was partially filled but should still be treated as a single transaction.
For example:
- You place an order to purchase 1,000 shares.
- Your broker fills it in parts: 500, then 300, then 200.
In this scenario, it makes sense to merge these partial fills into one transaction for tax purposes.
All fills are in the same direction (buys). It would be unusual or incorrect to merge transactions in opposite directions (e.g., buy and sell) as one order.
2025-10-08
- Fixed outdated endpoint for ECB exchange rate data (commit)
2025-01-09
- Added this website for docs and guides