Skip to content

fix: empty ORLists now return false#1297

Merged
Computerdores merged 2 commits into
TagStudioDev:mainfrom
TheBobBobs:fix/empty_or
May 12, 2026
Merged

fix: empty ORLists now return false#1297
Computerdores merged 2 commits into
TagStudioDev:mainfrom
TheBobBobs:fix/empty_or

Conversation

@TheBobBobs
Copy link
Copy Markdown
Contributor

Summary

If an ORList has only invalid tags return False.

The default query is an empty ORList so return True if the ORList contained no elements before seperating tags.

fixes #1287

Tasks Completed

  • Platforms Tested:
    • Linux x86
  • Tested For:
    • Basic functionality

@TrigamDev TrigamDev added Status: Review Needed A review of this is needed TagStudio: Search The TagStudio search engine Type: Fix A fix for a bug, typo, or other issue Priority: Low Doesn't require immediate attention labels Jan 21, 2026
@Computerdores
Copy link
Copy Markdown
Collaborator

Computerdores commented Jan 21, 2026

While this might1 fix the specific symptom reported in #1287 this doesn't address the root cause of this issue, which is likely that __separate_tags incorrectly handles list of only incorrect tag names. And since __separate_tags is used elsewhere too from what I remember, it would be better to fix that method.

Footnotes

  1. I am not doubting that it does, I just didn't test it myself.

@CyanVoxel CyanVoxel added Status: Mergeable The code is ready to be merged and removed Status: Review Needed A review of this is needed labels May 11, 2026
@CyanVoxel CyanVoxel modified the milestone: Alpha v9.6.0 May 11, 2026
@CyanVoxel CyanVoxel moved this to 🍃 Pending Merge in TagStudio Development May 11, 2026
@Computerdores Computerdores merged commit e2394b7 into TagStudioDev:main May 12, 2026
6 checks passed
@github-project-automation github-project-automation Bot moved this from 🍃 Pending Merge to ✅ Done in TagStudio Development May 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Priority: Low Doesn't require immediate attention Status: Mergeable The code is ready to be merged TagStudio: Search The TagStudio search engine Type: Fix A fix for a bug, typo, or other issue

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

[Bug]: Search OR returns everything when no tag exists

4 participants