Bug 453115

Summary: When merging payees transactions are lost and balances are corrupted
Product: [Applications] kmymoney Reporter: Chris <developerchris>
Component: generalAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: REPORTED ---    
Severity: critical    
Priority: NOR    
Version: 5.0.8   
Target Milestone: ---   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Chris 2022-04-28 06:02:13 UTC
SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. Have a multiyear kmymoney file
2. Merge two payees

OBSERVED RESULT
Error is displayed saying "Cannot remove payee that is still referenced to a transaction" the transactions no longer appear in either payees (source nor destination) transaction list

Balances are corrupted as transactions are deleted for multiple years of the source payee.

Not sure what triggers the failed merge as other payees merge with no issue.
May be related to bug https://bugs.kde.org/show_bug.cgi?id=408205

EXPECTED RESULT
Merge to occur and balances to remain unchanged

SOFTWARE/OS VERSIONS
N/A Tried on win10 and ubuntu