[Bug]: Duplicate Transactions after Bank Sync #1012

Closed
opened 2026-02-28 19:28:20 -06:00 by GiteaMirror · 18 comments
Owner

Originally created by @Phil89a on GitHub (Mar 29, 2024).

Verified issue does not already exist?

  • I have searched and found no existing issue
  • I have checked my server logs and could not see any errors there
  • I will be attaching my server logs to this issue
  • I will be attaching my client-side (browser) logs to this issue
  • I understand that this issue will be automatically closed if insufficient information is provided

What happened?

I am not sure if this is a bug with Actual or GoCardLess or Open Banking, but since yesterday I am getting duplicate transactions imported when sync'ing with Barclays Bank. If I delete a duplicate, it comes back on the next sync. I have tried unlinking the account and creating a new account and linking that - no difference. I have also created a new file, linked the Bank Accounts and still I get duplicates (mostly duplicated twice, but sometimes 3 times)

This has been working fine for weeks now; just started yesterday.

Basically I can't use Actual as the duplicates can't be removed and throw my budgeting out.

Any ideas how to fix this - or track down the issue?

What error did you receive?

No error; just duplicated transactions (in my case about 100 of them)

Where are you hosting Actual?

Docker

What browsers are you seeing the problem on?

Safari

Operating System

Mac OSX

Originally created by @Phil89a on GitHub (Mar 29, 2024). ### Verified issue does not already exist? - [X] I have searched and found no existing issue ### Is this related to GoCardless, Simplefin or another bank-sync provider? - [X] I have checked my server logs and could not see any errors there - [ ] I will be attaching my server logs to this issue - [ ] I will be attaching my client-side (browser) logs to this issue - [X] I understand that this issue will be automatically closed if insufficient information is provided ### What happened? I am not sure if this is a bug with Actual or GoCardLess or Open Banking, but since yesterday I am getting duplicate transactions imported when sync'ing with Barclays Bank. If I delete a duplicate, it comes back on the next sync. I have tried unlinking the account and creating a new account and linking that - no difference. I have also created a new file, linked the Bank Accounts and still I get duplicates (mostly duplicated twice, but sometimes 3 times) This has been working fine for weeks now; just started yesterday. Basically I can't use Actual as the duplicates can't be removed and throw my budgeting out. Any ideas how to fix this - or track down the issue? ### What error did you receive? No error; just duplicated transactions (in my case about 100 of them) ### Where are you hosting Actual? Docker ### What browsers are you seeing the problem on? Safari ### Operating System Mac OSX
GiteaMirror added the needs infobug labels 2026-02-28 19:28:20 -06:00
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

Update - have ruled out that the problem is with Barclays' Open Banking side by linking the accounts via another service and sync'ing the accounts. No duplicates.

So it is either with GoCardLess or Actual. Anyway to get a better idea where ?

@Phil89a commented on GitHub (Mar 30, 2024): Update - have ruled out that the problem is with Barclays' Open Banking side by linking the accounts via another service and sync'ing the accounts. No duplicates. So it is either with GoCardLess or Actual. Anyway to get a better idea where ?
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

Further update - removed Actual completely and created a new Docker Container and database. Also, recreated my Secrets key with GoCardless and tried again. Still importing duplicates - I think this points to a problem with Actual talking to GoCardLess but I am no expert.

Actual is still unusable for me 🙁

@Phil89a commented on GitHub (Mar 30, 2024): Further update - removed Actual completely and created a new Docker Container and database. Also, recreated my Secrets key with GoCardless and tried again. Still importing duplicates - I think this points to a problem with Actual talking to GoCardLess but I am no expert. Actual is still unusable for me 🙁
Author
Owner

@MatissJanis commented on GitHub (Mar 30, 2024):

👋 Hi! Can you please provide a way to reproduce this issue? Without being able to reproduce there is very little we can do to help here.

@MatissJanis commented on GitHub (Mar 30, 2024): 👋 Hi! Can you please provide a way to reproduce this issue? Without being able to reproduce there is very little we can do to help here.
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

Not sure how I can provide a way to reproduce. I can recreate the problem for me just by sync'ing with the bank.

I am assuming something is wrong with the logic that is matching existing transactions with the transactions being imported and that is stopping it recognising the transaction is there, so creates it again.

Is there any data I could provide from the database that may help identify what might be happening?

I did look for an Ignore option that would ignore the erroneous transactions as that would enable me to ignore these.

Please let me know if I can provide anything as I really want to keep using Actual but with things "randomly" duplicating I can't 🙁

@Phil89a commented on GitHub (Mar 30, 2024): Not sure how I can provide a way to reproduce. I can recreate the problem for me just by sync'ing with the bank. I am assuming something is wrong with the logic that is matching existing transactions with the transactions being imported and that is stopping it recognising the transaction is there, so creates it again. Is there any data I could provide from the database that may help identify what might be happening? I did look for an Ignore option that would ignore the erroneous transactions as that would enable me to ignore these. Please let me know if I can provide anything as I really want to keep using Actual but with things "randomly" duplicating I can't 🙁
Author
Owner

@MatissJanis commented on GitHub (Mar 30, 2024):

  1. duplicate your budget
  2. delete all the transactions (except one that keeps on getting duplicated)
  3. export and upload the file here
  4. next click "sync" in the UI to trigger bank-sync
  5. open up the server logs; you will see a large JSON object there with the new transactions
  6. paste this JSON object here (feel free to truncate some private information as you see fit)

With those two artefacts I should be able to reproduce the issue.

@MatissJanis commented on GitHub (Mar 30, 2024): 1. duplicate your budget 2. delete all the transactions (except one that keeps on getting duplicated) 3. export and upload the file here 4. next click "sync" in the UI to trigger bank-sync 5. open up the server logs; you will see a large JSON object there with the new transactions 6. paste this JSON object here (feel free to truncate some private information as you see fit) With those two artefacts I should be able to reproduce the issue.
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

OK, will do this - can you point me how to get to the server logs?

@Phil89a commented on GitHub (Mar 30, 2024): OK, will do this - can you point me how to get to the server logs?
Author
Owner

@MatissJanis commented on GitHub (Mar 30, 2024):

That very much depends on how you are hosting Actual. Sadly I won't be able to help with that.

@MatissJanis commented on GitHub (Mar 30, 2024): That very much depends on how you are hosting Actual. Sadly I won't be able to help with that.
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

It’s okay - thought it was an Actual Server Log - but it is in the Docker Container’s Logs :-).

Will send it over in a few mins

On 30 Mar 2024, at 21:13, Matiss Janis Aboltins @.***> wrote:

That very much depends on how you are hosting Actual. Sadly I won't be able to help with that.


Reply to this email directly, view it on GitHub https://github.com/actualbudget/actual/issues/2519#issuecomment-2028470041, or unsubscribe https://github.com/notifications/unsubscribe-auth/APSCJX2NJ5NA554BNPXPV3TY24MHVAVCNFSM6AAAAABFO5BSPSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMRYGQ3TAMBUGE.
You are receiving this because you authored the thread.

@Phil89a commented on GitHub (Mar 30, 2024): It’s okay - thought it was an Actual Server Log - but it is in the Docker Container’s Logs :-). Will send it over in a few mins > On 30 Mar 2024, at 21:13, Matiss Janis Aboltins ***@***.***> wrote: > > > That very much depends on how you are hosting Actual. Sadly I won't be able to help with that. > > — > Reply to this email directly, view it on GitHub <https://github.com/actualbudget/actual/issues/2519#issuecomment-2028470041>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/APSCJX2NJ5NA554BNPXPV3TY24MHVAVCNFSM6AAAAABFO5BSPSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMRYGQ3TAMBUGE>. > You are receiving this because you authored the thread. >
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

OK - hopefully got the right files....

You will see in this extract it duplicates the transaction on the 2nd Jan - only duplicates it once. If I delete it it comes back; if I delete it and the original they both come back

Let me know if you need anything else

Thanks
Exported Budget.zip
Log File Extract.txt

@Phil89a commented on GitHub (Mar 30, 2024): OK - hopefully got the right files.... You will see in this extract it duplicates the transaction on the 2nd Jan - only duplicates it once. If I delete it it comes back; if I delete it and the original they both come back Let me know if you need anything else Thanks [Exported Budget.zip](https://github.com/actualbudget/actual/files/14813355/Exported.Budget.zip) [Log File Extract.txt](https://github.com/actualbudget/actual/files/14813356/Log.File.Extract.txt)
Author
Owner

@MatissJanis commented on GitHub (Mar 30, 2024):

So looking at the .txt file (server logs): you have two transactions on the 2nd of Jan. They are not duplicated. They are two unique transactions. Each has its own unique transaction ID.

{
        "bookingDate": "2024-02-01",
        "valueDate": "2024-02-01",
        "bookingDateTime": "2024-02-01T00:38:36Z",
        "valueDateTime": "2024-02-01T00:00:00.000Z",
        "transactionAmount": {
            "amount": "0.06",
            "currency": "GBP"
        },
        "remittanceInformationUnstructured": "INTEREST PAID GROSS  FOR PERIOD 2JAN/31JAN",
        "internalTransactionId": "9f38623478143f92fb8921ac635342f2",
        "date": "2024-02-01"
    },
    {
        "bookingDate": "2024-02-01",
        "valueDate": "2024-02-01",
        "bookingDateTime": "2024-02-01T00:00:00Z",
        "valueDateTime": "2024-02-01T00:38:36.530Z",
        "transactionAmount": {
            "amount": "0.06",
            "currency": "GBP"
        },
        "remittanceInformationUnstructured": "INTEREST PAID GROSS  FOR PERIOD 2JAN/31JAN",
        "internalTransactionId": "3e1aa309baa54d381315bcb857b9bee0",
        "date": "2024-02-01"
    },
@MatissJanis commented on GitHub (Mar 30, 2024): So looking at the `.txt` file (server logs): you have two transactions on the 2nd of Jan. They are not duplicated. They are two unique transactions. Each has its own unique transaction ID. ``` { "bookingDate": "2024-02-01", "valueDate": "2024-02-01", "bookingDateTime": "2024-02-01T00:38:36Z", "valueDateTime": "2024-02-01T00:00:00.000Z", "transactionAmount": { "amount": "0.06", "currency": "GBP" }, "remittanceInformationUnstructured": "INTEREST PAID GROSS FOR PERIOD 2JAN/31JAN", "internalTransactionId": "9f38623478143f92fb8921ac635342f2", "date": "2024-02-01" }, { "bookingDate": "2024-02-01", "valueDate": "2024-02-01", "bookingDateTime": "2024-02-01T00:00:00Z", "valueDateTime": "2024-02-01T00:38:36.530Z", "transactionAmount": { "amount": "0.06", "currency": "GBP" }, "remittanceInformationUnstructured": "INTEREST PAID GROSS FOR PERIOD 2JAN/31JAN", "internalTransactionId": "3e1aa309baa54d381315bcb857b9bee0", "date": "2024-02-01" }, ```
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

But there should only be one transaction for that date.  If I check the bank statement, there is only one credit for interest. So is duplicated from that point of view.   Somewhere a new transaction is being created between bank and Actual ??PhilOn 30 Mar 2024, at 21:26, Matiss Janis Aboltins @.***> wrote:
So looking at the .txt file (server logs): you have two transactions on the 2nd of Jan. They are not duplicated. They are two unique transactions. Each has its own unique transaction ID.
{
"bookingDate": "2024-02-01",
"valueDate": "2024-02-01",
"bookingDateTime": "2024-02-01T00:38:36Z",
"valueDateTime": "2024-02-01T00:00:00.000Z",
"transactionAmount": {
"amount": "0.06",
"currency": "GBP"
},
"remittanceInformationUnstructured": "INTEREST PAID GROSS FOR PERIOD 2JAN/31JAN",
"internalTransactionId": "9f38623478143f92fb8921ac635342f2",
"date": "2024-02-01"
},
{
"bookingDate": "2024-02-01",
"valueDate": "2024-02-01",
"bookingDateTime": "2024-02-01T00:00:00Z",
"valueDateTime": "2024-02-01T00:38:36.530Z",
"transactionAmount": {
"amount": "0.06",
"currency": "GBP"
},
"remittanceInformationUnstructured": "INTEREST PAID GROSS FOR PERIOD 2JAN/31JAN",
"internalTransactionId": "3e1aa309baa54d381315bcb857b9bee0",
"date": "2024-02-01"
},

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

@Phil89a commented on GitHub (Mar 30, 2024): But there should only be one transaction for that date.  If I check the bank statement, there is only one credit for interest. So is duplicated from that point of view.   Somewhere a new transaction is being created between bank and Actual ??PhilOn 30 Mar 2024, at 21:26, Matiss Janis Aboltins ***@***.***> wrote: So looking at the .txt file (server logs): you have two transactions on the 2nd of Jan. They are not duplicated. They are two unique transactions. Each has its own unique transaction ID. { "bookingDate": "2024-02-01", "valueDate": "2024-02-01", "bookingDateTime": "2024-02-01T00:38:36Z", "valueDateTime": "2024-02-01T00:00:00.000Z", "transactionAmount": { "amount": "0.06", "currency": "GBP" }, "remittanceInformationUnstructured": "INTEREST PAID GROSS FOR PERIOD 2JAN/31JAN", "internalTransactionId": "9f38623478143f92fb8921ac635342f2", "date": "2024-02-01" }, { "bookingDate": "2024-02-01", "valueDate": "2024-02-01", "bookingDateTime": "2024-02-01T00:00:00Z", "valueDateTime": "2024-02-01T00:38:36.530Z", "transactionAmount": { "amount": "0.06", "currency": "GBP" }, "remittanceInformationUnstructured": "INTEREST PAID GROSS FOR PERIOD 2JAN/31JAN", "internalTransactionId": "3e1aa309baa54d381315bcb857b9bee0", "date": "2024-02-01" }, —Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: ***@***.***>
Author
Owner

@MatissJanis commented on GitHub (Mar 30, 2024):

If GoCardless (and by extension your banks API) returns two transactions - we just take that and import it in Actual. The disconnect has to be somewhere between the bank and GoCardless, so I'd recommend reaching out to GoCardless first and see why they return an extra transaction that you're not seeing in your bank.

@MatissJanis commented on GitHub (Mar 30, 2024): If GoCardless (and by extension your banks API) returns two transactions - we just take that and import it in Actual. The disconnect has to be somewhere between the bank and GoCardless, so I'd recommend reaching out to GoCardless first and see why they return an extra transaction that you're not seeing in your bank.
Author
Owner

@Phil89a commented on GitHub (Mar 30, 2024):

Ok thanks - will doOn 30 Mar 2024, at 21:34, Matiss Janis Aboltins @.***> wrote:
If GoCardless (and by extension your banks API) returns two transactions - we just take that and import it in Actual. The disconnect has to be somewhere between the bank and GoCardless, so I'd recommend reaching out to GoCardless first and see why they return an extra transaction that you're not seeing in your bank.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

@Phil89a commented on GitHub (Mar 30, 2024): Ok thanks - will doOn 30 Mar 2024, at 21:34, Matiss Janis Aboltins ***@***.***> wrote: If GoCardless (and by extension your banks API) returns two transactions - we just take that and import it in Actual. The disconnect has to be somewhere between the bank and GoCardless, so I'd recommend reaching out to GoCardless first and see why they return an extra transaction that you're not seeing in your bank. —Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: ***@***.***>
Author
Owner

@londondev77 commented on GitHub (Apr 4, 2024):

I am having the exact same issues with Barclays. I delete the duplicate transactions and they reappear on the next sync. It also happens if I zero out the transaction. Regardless of whether GoCardless is returning duplicate transactions, shouldn't my manual overrides persist when syncing or does this mean GoCardless is returning different transactionIDs each time so Actual doesn't realise to keep my manual overrides?

I couldn't get the server log files to display my duplicate transactions however I went onto the GoCardless website and created a test account to view the data - this clearly showed the duplicate transactions, example below. Different internalTransactionIDs, bookingDateTime and valueDateTime values transposed between the two - exactly the same as in a comment above.

{
                "bookingDate": "2024-01-23",
                "valueDate": "2024-01-23",
                "bookingDateTime": "2024-01-23T17:49:12Z",
                "valueDateTime": "2024-01-23T00:00:00.000Z",
                "transactionAmount": {
                    "amount": "-250.00",
                    "currency": "GBP"
                },
                "remittanceInformationUnstructured": "CARDTRONICS UK LTD MFG - WHETSTONE 11 23JAN 17.49 ATM",
                "internalTransactionId": "c277a665323580ff3278efd224b43996"
            },
            {
                "bookingDate": "2024-01-23",
                "valueDate": "2024-01-23",
                "bookingDateTime": "2024-01-23T00:00:00Z",
                "valueDateTime": "2024-01-23T17:49:12.660Z",
                "transactionAmount": {
                    "amount": "-250.00",
                    "currency": "GBP"
                },
                "remittanceInformationUnstructured": "CARDTRONICS UK LTD MFG - WHETSTONE 11 23JAN 17.49 ATM",
                "internalTransactionId": "0308ef23c2f04a1f953ba2b081aa822b"
            }

@Phil89a - can you report back if you have any success with GoCardless? I'll also contact them and will report back if I have any success.

@londondev77 commented on GitHub (Apr 4, 2024): I am having the exact same issues with Barclays. I delete the duplicate transactions and they reappear on the next sync. It also happens if I zero out the transaction. Regardless of whether GoCardless is returning duplicate transactions, shouldn't my manual overrides persist when syncing or does this mean GoCardless is returning different transactionIDs each time so Actual doesn't realise to keep my manual overrides? I couldn't get the server log files to display my duplicate transactions however I went onto the GoCardless website and created a test account to view the data - this clearly showed the duplicate transactions, example below. Different internalTransactionIDs, bookingDateTime and valueDateTime values transposed between the two - exactly the same as in a comment above. ``` { "bookingDate": "2024-01-23", "valueDate": "2024-01-23", "bookingDateTime": "2024-01-23T17:49:12Z", "valueDateTime": "2024-01-23T00:00:00.000Z", "transactionAmount": { "amount": "-250.00", "currency": "GBP" }, "remittanceInformationUnstructured": "CARDTRONICS UK LTD MFG - WHETSTONE 11 23JAN 17.49 ATM", "internalTransactionId": "c277a665323580ff3278efd224b43996" }, { "bookingDate": "2024-01-23", "valueDate": "2024-01-23", "bookingDateTime": "2024-01-23T00:00:00Z", "valueDateTime": "2024-01-23T17:49:12.660Z", "transactionAmount": { "amount": "-250.00", "currency": "GBP" }, "remittanceInformationUnstructured": "CARDTRONICS UK LTD MFG - WHETSTONE 11 23JAN 17.49 ATM", "internalTransactionId": "0308ef23c2f04a1f953ba2b081aa822b" } ``` @Phil89a - can you report back if you have any success with GoCardless? I'll also contact them and will report back if I have any success.
Author
Owner

@Phil89a commented on GitHub (Apr 4, 2024):

@londondev77 Will do

@Phil89a commented on GitHub (Apr 4, 2024): @londondev77 Will do
Author
Owner

@londondev77 commented on GitHub (Apr 4, 2024):

Response from GoCardless

We do see that Barclays bank has started changing a parameter between their requests, we have reached out to them informing regarding this bug.

As soon as there will be any news or updates relating this, we will reach out to you.

@londondev77 commented on GitHub (Apr 4, 2024): Response from GoCardless > We do see that Barclays bank has started changing a parameter between their requests, we have reached out to them informing regarding this bug. > > As soon as there will be any news or updates relating this, we will reach out to you.
Author
Owner

@Phil89a commented on GitHub (Apr 12, 2024):

@londondev77 GoCardLess have just told me this is fixed. I have deleted my duplicated transactions, re-sync'ed and no duplicates appeared

@Phil89a commented on GitHub (Apr 12, 2024): @londondev77 GoCardLess have just told me this is fixed. I have deleted my duplicated transactions, re-sync'ed and no duplicates appeared
Author
Owner

@londondev77 commented on GitHub (Apr 12, 2024):

@Phil89a - thanks for the headsup. Looks like it's working correctly for me too.

@londondev77 commented on GitHub (Apr 12, 2024): @Phil89a - thanks for the headsup. Looks like it's working correctly for me too.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#1012