Skip to content

Fix the blank entry in the Custom exclusion#2268

Merged
m3nu merged 2 commits intoborgbase:masterfrom
VandalByte:fix-blank-entry
Aug 19, 2025
Merged

Fix the blank entry in the Custom exclusion#2268
m3nu merged 2 commits intoborgbase:masterfrom
VandalByte:fix-blank-entry

Conversation

@VandalByte
Copy link
Collaborator

@VandalByte VandalByte commented Aug 19, 2025

Description

This PR fixes the blank item that was getting added in the Custom tab of the Exclusion dialog. Even though the blank entry was getting discarded in GUI, it stayed when reopening the dialog. The reason being, the item was added to the database as a blank entry right when it was created.

A condition check was added to check if the entry is not blank before adding to the database.

Related Issue

Fixes #2267
Fixes #2134 (Unrelated bug fix)

How Has This Been Tested?

The fix has been tested with the GUI.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have read the CONTRIBUTING guide.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

I provide my contribution under the terms of the license of this repository and I affirm the Developer Certificate of Origin.

@VandalByte
Copy link
Collaborator Author

Also included a fix for the issue #2134

BUG: Does not exist error due to missing DB entry.

  • Added a check to determine if a value was returned from the DB using get_or_none().
  • If yes, then run the next block.
  • This fixes the error mentioned in the issue.

@m3nu m3nu merged commit c8ddd62 into borgbase:master Aug 19, 2025
7 checks passed
@VandalByte VandalByte deleted the fix-blank-entry branch August 19, 2025 17:25
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.

Blank entry for unchecked item in Custom pattern Exclusion tab IndexError-caused crash

2 participants