tiberiusteng / financisto1-holo

Financisto 1.6.8 with Holo theme and tweaks
GNU General Public License v2.0
24 stars 15 forks source link

Limited CSV Export History #35

Closed ls12styler closed 8 months ago

ls12styler commented 8 months ago

Possibly related to #22

Whenever I do a CSV export of my transactions across all my accounts, without any period filter, the earlierst transaction date is 2022-04-08. The earliest transaction in the app is back in 2013.

Somewhere between the 2024-01-05 and 2024-02-08 this seems to have broken. The export I did in January has the full history, but the February one doesn't.

Also, interestingly, when checking the number of records in each of my exports:

wc -l 2024* 
   13792 20240105_115216_604.csv
    3990 20240208_141110_499.csv
    4001 20240214_090450_095.csv
    4026 20240219_111301_340.csv
    4098 20240304_102707_808.csv
    4104 20240305_163659_561.csv
    4104 20240306_083523_376.csv
    3807 20240307_163545_479.csv

Between each exprt, there has only been transactions added, so I would expect the record count to only ever increase, but todays export shows less records, by almost 300. I have not deleted 300 transactions.

tiberiusteng commented 8 months ago

I haven't touched CSV export recently, but the date filter is probably causing issue (I think it'll reset to "This month" each time you go to the CSV export function). Since the CSV export is always sort by date descending, can you tail them and see if there are any patterns?

And try export again after clicking the "No filter" in the period filter (I tested on my data and it seems correctly exported all transactions).

ls12styler commented 8 months ago

Thanks for the speedy reply! And also thanks for taking over this project - I was gutted when the original was left stale.

For reference, I'm on a Pixel 6 and Android 14.

I've tried both removing the date filter completely and setting it to a range wider than I have transaction history for (start before first transaction and end after latest). Both result in the same export.

Screenshot_20240307-183339.png

Screenshot_20240307-164919.png

It's not like the accounts in the export have limited history either, they all have transactions earlier than 2022-04-08.

This seems very peculiar. Any suggestions for other things to check?

The second part of my original comment about the differing number of transactions can probably be ignored. I've removed the app data, uninstalled, reinstalled and restored the transactions and now it's just the limited history.

tiberiusteng commented 8 months ago

It's really strange ... and the current export code is difficult to pinpoint where the problem occurs. I'd like to make it actually dump crash log when it encounter something strange, but it will take some time, meanwhile you can try to look the last transaction exported, go to blotter, and check the next transaction earlier to it if there's anything strange (assuming it's crashed on that transaction and didn't progress further).

If you have Android development environment, please try enabling USB/Wifi debugging mode, do CSV export, and see if logcat has anything interesting in it (filtering with package tw.tib.financisto).

tiberiusteng commented 8 months ago

By the way, have you used any location/project entity in transactions?

ls12styler commented 8 months ago

Ok, so I think you're right about it bombing out during the export.

The transaction that immediately preceeds the last transaction in a bad expiry is a transfer - to a closed account.

In my preferences, I have closed accounts set to hidden.

If I display closed accounts and then perform the export, the entire history is in the export! 🎉

ls12styler commented 8 months ago

And no, I don't use locations or projects (although I may have in the long ago past)

tiberiusteng commented 8 months ago

Ahh great! That's good info, I'll check closed account handling.

ls12styler commented 8 months ago

App updated and issue has been resolved!

Thank you very much for fixing this @tiberiusteng!