Skip to content

Plex search - #138

Merged
pSpitzner merged 2 commits into
mainfrom
plex_search
Nov 20, 2026
Merged

pSpitzner merged 2 commits into
mainfrom
plex_search

Conversation

@pSpitzner

Copy link
Copy Markdown
Contributor

Implements find_by_info for plex.

I tried two implementations:

  • one uses the /all endpoint and manually filters. this is how plex python api does it. slow until we have a cache of all tracks locally on disk.
  • second uses /hubs/search. fast for simple track lookups. slow when combining tracks with artists, but okay when combining artists, albums, and tracks. reason: search only supports one central query, and returns matches as hubs. each hub has a type (artist, album, track). to get all tracks for a given artist, we have to first resolve all albums to then get all tracks. (ugly code by agent)

Not sure which one we prefer. Feel free to experiment

@pSpitzner
pSpitzner changed the base branch from main to seperate_config September 30, 2026 23:33
@pSpitzner
pSpitzner added this pull request to stack #133 September 30, 2026 23:33
@pSpitzner
pSpitzner requested a review from semohr September 30, 2026 23:33
@codecov

codecov Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 49.05660% with 27 lines in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
plistsync/services/plex/api.py 28.94% 25 Missing and 2 partials ⚠️

📢 Thoughts on this report? Let us know!

@semohr
semohr had a problem deploying to integration_tests October 1, 2026 12:09 — with GitHub Actions Failure
@semohr
semohr had a problem deploying to integration_tests October 1, 2026 12:09 — with GitHub Actions Failure
@semohr semohr mentioned this pull request Oct 11, 2026
@semohr
semohr removed this pull request from stack #133 October 12, 2026 16:30
@semohr
semohr changed the base branch from seperate_config to main October 12, 2026 16:31
@semohr

semohr commented Oct 17, 2026

Copy link
Copy Markdown
Contributor

I just enhanced the Plex search: it now asks Plex to filter tracks on the server using its documented media-query filters, instead of walking search hubs. A lookup by title/artist/album is typically a single request, with no hub expansion.

Feel free to test it too. Works pretty well for me :)

@semohr
semohr temporarily deployed to integration_tests November 9, 2026 18:42 — with GitHub Actions Inactive
@semohr
semohr temporarily deployed to integration_tests November 9, 2026 18:42 — with GitHub Actions Inactive
@semohr
semohr changed the base branch from main to docs_update November 9, 2026 18:44
@semohr
semohr self-requested a review November 9, 2026 18:49
@semohr
semohr changed the base branch from docs_update to main November 20, 2026 14:09
@pSpitzner
pSpitzner temporarily deployed to integration_tests November 20, 2026 14:15 — with GitHub Actions Inactive
@pSpitzner
pSpitzner temporarily deployed to integration_tests November 20, 2026 14:15 — with GitHub Actions Inactive
@pSpitzner
pSpitzner enabled auto-merge November 20, 2026 14:17
@pSpitzner
pSpitzner disabled auto-merge November 20, 2026 14:17
@pSpitzner
pSpitzner enabled auto-merge November 20, 2026 14:17
@pSpitzner
pSpitzner merged commit 28a7886 into main Nov 20, 2026
13 of 14 checks passed

This branch was previously deployed

1 inactive deployment
integration_tests — f0a30b62 Deployed Nov 20, 2026 by pSpitzner via integration-tests (spotify) #622
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.

2 participants