-
Notifications
You must be signed in to change notification settings - Fork 490
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
csv parser: mark guessed account as calculated #2086
base: master
Are you sure you want to change the base?
Conversation
I'm not sure I see the advantage of this. Can you elaborate? Why not put the amount on both postings; but maybe some people don't like that |
When importing via csv you always get transactions with two postings. One is the posting on the real account the csv is about. The other one is guessed.
Putting the amount on both postings would be fine with me, but this would require a change to |
Ok, thanks for the clarification. I agree with your points; otoh, people might not like the negative numbers that the change will cause (even if they accurately represent the transaction). I think I'll leave this up for John to decide (but he has been busy). You may want to email the ledger mailing list about this and gather feedback from other users. |
I agree with this change 100%. I think users will often want to split their income/expenses and moving the posted amount to the bank account would facilitate this. Further, the CSV is likely provided by a source for one account, the bank/credit account, and it would logically make sense for |
can someone email the ledger mailing list to discuss this change and see what the feedback is. I think the arguments here are good, but since it's a change in behaviour I think it's better to discuss it more widely. |
Only received one comment, but it was from @jwiegley, so it may be worth more than one vote ;)
|
Could we add an option to do this flipping? It could change the workflow for many people. |
@madroach what do you think of John's suggest to make it an option. |
sure, that would be fine with me. |
@madroach Great, just let me know when that change is in! |
@madroach Mind merging the current state of master, which has seen some improvements regarding the checks run on PRs, to this PRs branch too? |
Friendly ping for @madroach |
mark the posting with the guessed account as calculated. This will change the output so that the amount is printed after the bucket account, not the guessed account. 2022/02/01* Blublub Expenses:Groceries 100,00 Accounts:Cache becomes 2022/02/01* Blublub Expenses:Groceries Accounts:Cache -100,00 This makes subclassifying a bit easier
I like the change, but it seems to break a few tests? Can you confirm that these tests need to be changed now, and if so, include those changes here in the PR until it passes CI? |
I took the liberty to address the breaking tests. The changes can be found here. I'm ot sure how to best update this PR with these changes as this PR's branch is on a fork, hence I created a PR madroach/ledger#1. @madroach would you be willing to accept that, so this PR's branch gets those changes and we can move forward with merging this PR? @jwiegley Are you okay with the fixes (see Fix DocTests and tests: Fix Baseline and Regression tests) and are any changes to the documentation necessary? |
merge updated test cases from afh/pr/2086
Merged. Thanks for the work. I couldn't find the time for it... |
Thanks for merging, @madroach, very much appreciated! No worries regarding not finding the time, often enough other obligations stand in the way of the fun stuff 🙂 |
I think this is set to go, it just still needs the option to flip the behavior, which should be relatively easy to add as a |
@madroach would you be okay with me taking over the work and adding the requested option as well as accompanying documentation and tests? If yes, I'd close this PR in favor of one I'd create in order to more easily push changes to it. You'd be credited with |
Yes, please do! I just won't find the time. |
This will change the output of the
convert
command so that the amount is printedon the bucket account, not the guessed account.
becomes
This makes subclassifying after conversion a bit easier