Skip to content
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

🐛 split amount must be positive #86

Merged
merged 1 commit into from
Jul 31, 2023
Merged

Conversation

ericzinnikas
Copy link
Contributor

Description

  • Prior to this fix, running lunchable plugins splitlunch splitlunch-import --tag-transactions --financial-partner-id 123 --financial-partner-group-id 456 failed with:
LunchMoneyHTTPError: ['Sums of split transaction do not add up to the original transaction amount!']
  • For SplitLunchImport tagged items, this failed to create the 2nd reimbursement split, as the financial_impact (and thus split amount) was negative

Has This Been Tested?

  • Ran lunchable plugins splitlunch splitlunch-import, see Splitwise transaction created, but Lunchmoney split failed
  • Add abs
  • Re-run, see Splitwise transaction and Lunchmoney split succeed

Checklist:

  • I've read the contributing guidelines of this project
  • I've installed and used .pre_commit on all my code
  • I have documented my code, particularly in hard-to-understand areas
  • I have made any necessary corresponding changes to the documentation

Copy link
Owner

@juftin juftin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm good with this. I'm no longer using splitwise so am unable to test myself 🙃

@juftin juftin merged commit ac6d717 into juftin:main Jul 31, 2023
8 checks passed
@juftin
Copy link
Owner

juftin commented Jul 31, 2023

🎉 This PR is included in version 0.8.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants