-
-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(SharedHubStrategy): exclude Meta and Misc hubs #3131
Merged
wescopeland
merged 7 commits into
RetroAchievements:master
from
wescopeland:shared-hub-strategy-exclude-some-kinds
Jan 29, 2025
Merged
Changes from 1 commit
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
772d5a0
fix(SharedHubStrategy): exclude Meta and Misc hubs
wescopeland 761caa8
fix: address feedback
wescopeland db40edf
fix: address feedback
wescopeland 7acb411
chore: revert some stuff
wescopeland 4b60090
Merge branch 'master' into shared-hub-strategy-exclude-some-kinds
wescopeland d49d9c0
fix: address pr feedback
wescopeland 54b02ad
Merge branch 'master' into shared-hub-strategy-exclude-some-kinds
wescopeland File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be
NOT LIKE "[Meta%"
or you'll exclude hubs like "[Series - Metal Gear]" and "[Series - Twisted Metal]".There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know that we can guarantee hubs will always be encased with square brackets. The problem you're describing definitely makes sense, but I think "%Meta - %" may be a more future-proofed target string.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
%Misc. -%
filter will work, but%Meta -%
will miss anything[Meta|QA -
,[Meta|Art -
, or[Meta|DevComp -
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, I forgot about those.
I have reservations about adding more "NOT LIKE" filters on the query. I've combined everything into a single:
which should be a bit more performant. Note that the square brackets in the pattern are not checking for the presence of square brackets in the title. They're defining character classes for conditionals in the pattern.
SQLite doesn't support
REGEXP
, so I needed to add some conditional logic for tests.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unless I made a typo, this is still matching the aforementioned series names.
I think it's the leading
^
. Doesn't that imply that theMeta
must start the string? And we know the strings all start with an open bracket.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No typo on your end, I messed up. I think I have things in a better place now in latest.