[PR #4241] [MERGED] fix(#2495): fix GoCardless transaction ID to fallback to it's own generated ID on sync #35473

Closed
opened 2026-04-20 22:27:45 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/actualbudget/actual/pull/4241
Author: @NullScope
Created: 1/25/2025
Status: Merged
Merged: 2/5/2025
Merged by: @matt-fidd

Base: masterHead: fix-gocardless-import-id


📝 Commits (10+)

  • 249aab2 fix(#2495): fixed gocardless import ID
  • 16aab5c chore: added release note
  • 9a0b8b8 chore: updated release note
  • ec16c99 refactor: made condition more clear
  • fcbc906 Revert "refactor: made condition more clear"
  • 5eda09e fix: added edge case
  • bd066de Merge branch 'master' into fix-gocardless-import-id
  • 987a413 Merge branch 'master' into fix-gocardless-import-id
  • 3ff7429 Merge branch 'master' into fix-gocardless-import-id
  • aa69af4 Merge branch 'master' into fix-gocardless-import-id

📊 Changes

2 files changed (+13 additions, -1 deletions)

View changed files

📝 packages/loot-core/src/server/accounts/sync.ts (+7 -1)
upcoming-release-notes/4241.md (+6 -0)

📄 Description

Some bank accounts have no transactionId in GoCardless, meaning that any changes (e.g setting to 0 for duplicated transactions) to any such imported transaction will cause Actual to re-import the transaction instead of updating or ignoring it.

GoCardless has an internalTransactionId for cases like these as described here: https://bankaccountdata.zendesk.com/hc/en-gb/articles/11529646897820-internalTransactionId-a-unique-transaction-ID-now-generated-by-GoCardless

There are some caveats though:

  • It does NOT exist in pending transactions
  • It is ONLY guaranteed to be unique inside the same bank account

As such, this PR falls back to {acctId}-{internalTransactionId} in case transactionId does not exist AND the transaction has been cleared.

Fixes #2495


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/actualbudget/actual/pull/4241 **Author:** [@NullScope](https://github.com/NullScope) **Created:** 1/25/2025 **Status:** ✅ Merged **Merged:** 2/5/2025 **Merged by:** [@matt-fidd](https://github.com/matt-fidd) **Base:** `master` ← **Head:** `fix-gocardless-import-id` --- ### 📝 Commits (10+) - [`249aab2`](https://github.com/actualbudget/actual/commit/249aab274b5970b610048999223760824e5d1a60) fix(#2495): fixed gocardless import ID - [`16aab5c`](https://github.com/actualbudget/actual/commit/16aab5cefbbaa8727b1784bd7c6f6d23cdd5319f) chore: added release note - [`9a0b8b8`](https://github.com/actualbudget/actual/commit/9a0b8b82e65f18e3cf58c1657ad2222ba6e87077) chore: updated release note - [`ec16c99`](https://github.com/actualbudget/actual/commit/ec16c990417c4a28d275ff32f8b4474feed08e43) refactor: made condition more clear - [`fcbc906`](https://github.com/actualbudget/actual/commit/fcbc9067f47a3aecb67d0279ea0c97fc81e04e09) Revert "refactor: made condition more clear" - [`5eda09e`](https://github.com/actualbudget/actual/commit/5eda09e160d4b4b6c1cbc78450ac85328e742639) fix: added edge case - [`bd066de`](https://github.com/actualbudget/actual/commit/bd066de24e144c3d56aecd86bce63f2e3cb6902e) Merge branch 'master' into fix-gocardless-import-id - [`987a413`](https://github.com/actualbudget/actual/commit/987a413c76f737b4264d08d4926cc0adca9f776f) Merge branch 'master' into fix-gocardless-import-id - [`3ff7429`](https://github.com/actualbudget/actual/commit/3ff74290e5f11df6ee0de4b8701e8892ae169299) Merge branch 'master' into fix-gocardless-import-id - [`aa69af4`](https://github.com/actualbudget/actual/commit/aa69af4fa43f2a551f3ab941894a9d8708aeae23) Merge branch 'master' into fix-gocardless-import-id ### 📊 Changes **2 files changed** (+13 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `packages/loot-core/src/server/accounts/sync.ts` (+7 -1) ➕ `upcoming-release-notes/4241.md` (+6 -0) </details> ### 📄 Description Some bank accounts have no `transactionId` in GoCardless, meaning that any changes (e.g setting to 0 for duplicated transactions) to any such imported transaction will cause Actual to re-import the transaction instead of updating or ignoring it. GoCardless has an `internalTransactionId` for cases like these as described here: https://bankaccountdata.zendesk.com/hc/en-gb/articles/11529646897820-internalTransactionId-a-unique-transaction-ID-now-generated-by-GoCardless There are some caveats though: - It does NOT exist in pending transactions - It is ONLY guaranteed to be unique inside the same bank account As such, this PR falls back to `{acctId}-{internalTransactionId}` in case `transactionId` does not exist AND the transaction has been cleared. Fixes #2495 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-20 22:27:46 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#35473