You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[AI] Honour the pending transactions setting in Enable Banking sync - #9549
…g sync
Pending transactions were imported even with the setting off, and as
cleared, for banks that do not flag them: everything without the PDNG
status counted as booked. Ask Enable Banking for booked transactions
only when importing pending ones is off, treat only BOOK as booked, and
leave cancelled and rejected transactions out.
A bank's rate limit or timeout could be reported as a lost
authorization, depending on the HTTP status it arrived with, which told
the user to link the bank again. Classify errors by Enable Banking's
error code first.
Co-Authored-By: Claude Fable 5.2 <[email protected]>
…atus
Classifying by error code dropped the message check that used to catch
WRONG_SESSION_STATUS, so that error lost its reauthorize prompt.
Co-Authored-By: Claude Fable 5.2 <[email protected]>
Keep the booked-only request and treat holds and scheduled payments as
pending. Leave transactions with other statuses booked as before, stop
dropping cancelled and rejected ones, and go back to the previous error
classification, keeping only two additions: a bank timeout is reported
as a timeout, and a session that no longer exists asks for a new login.
Co-Authored-By: Claude Fable 5.2 <[email protected]>
MatissJanis
changed the title
[AI] Honour the pending setting and bank rate limits in Enable Banking sync
[AI] Honour the pending transactions setting in Enable Banking sync
Nov 13, 2026
Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
Reviewing files that changed from the base of the PR and between 437b2ea and 437b2ea.
You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.
Use the checkbox below for a quick retry:
Trigger review
Note
.coderabbit.yaml has unrecognized properties
CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.
Parsing warnings: 1
Validation error: Unrecognized key: "enabled" at "reviews.pre_merge_checks.docstrings"
If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json
No actionable comments were generated in the recent review.
Walkthrough
Enable Banking sync now sends the pending-transaction preference to the server. Transaction status handling recognizes additional statuses. Error handling maps timeout conditions and session-related 404 responses to specific error codes.
The sync path sends importPending, defaulting a missing account preference to true. The route enables booked-only retrieval only when the value is explicitly false.
Transaction status handling packages/loot-core/src/types/models/enablebanking.ts, packages/sync-server/src/app-enablebanking/services/enablebanking-service.ts, packages/sync-server/src/app-enablebanking/services/tests/normalization.spec.ts
Transaction status types include additional values. HOLD and SCHD are marked not booked; tests also check OTHR.
Enable Banking error classification
Layer / File(s)
Summary
Timeout and session error mapping packages/sync-server/src/app-enablebanking/utils/errors.ts, packages/sync-server/src/app-enablebanking/utils/tests/errors.spec.ts
Status 408 and ASPSP_TIMEOUT map to TIMED_OUT. Session-related 404 errors map to INVALID_ACCESS_TOKEN; other 404 errors map to NOT_FOUND.
This change makes Enable Banking sync honour the pending-transactions setting and improves status and error handling. It is backward compatible with older clients, and no merge-blocking risk was identified.
Pre-merge checks: 4
Check name
Status
Explanation
Title check
The title names the main change: Enable Banking sync now respects the pending transactions setting. The changeset adds an importPending flag, a getImportPending helper, and bookedOnly filtering that f…
Description check
The description states that the PR fixes pending transactions and improves error handling for Enable Banking. The changeset matches both points: pending-transaction handling in sync and transaction fi…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title names the main change: Enable Banking sync now respects the pending transactions setting. The changeset adds an importPending flag, a getImportPending helper, and bookedOnly filtering that follow this setting. The title also carries an [AI] prefix, which does not affect relevance.
Full details: Description check
Explanation
The description states that the PR fixes pending transactions and improves error handling for Enable Banking. The changeset matches both points: pending-transaction handling in sync and transaction filtering, plus new error mappings for 404, 408, and ASPSP_TIMEOUT. It also links issue #7799 and includes release notes.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Some smaller fixes for EB: pending transactions + improved error handling.
Related issue(s)
Relates #7799
Testing
n/a
Checklist
Bundle Stats
View detailed bundle stats
desktop-client
Total
View detailed bundle breakdown
Added
No assets were added
Removed
No assets were removed
Bigger
No assets were bigger
Smaller
Unchanged
loot-core
Total
Changeset
home/runner/work/actual/actual/packages/loot-core/src/server/accounts/sync.tsView detailed bundle breakdown
Added
Removed
Bigger
No assets were bigger
Smaller
No assets were smaller
Unchanged
No assets were unchanged
api
Total
Changeset
home/runner/work/actual/actual/packages/loot-core/src/server/accounts/sync.tsView detailed bundle breakdown
Added
No assets were added
Removed
No assets were removed
Bigger
Smaller
No assets were smaller
Unchanged
cli
Total
View detailed bundle breakdown
Added
No assets were added
Removed
No assets were removed
Bigger
No assets were bigger
Smaller
No assets were smaller
Unchanged
crdt
Total
View detailed bundle breakdown
Added
No assets were added
Removed
No assets were removed
Bigger
No assets were bigger
Smaller
No assets were smaller
Unchanged