Indexing Revamp#77
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c0acb08ac8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| warn_legacy_search_once() | ||
| return self.legacy_search(query=query, **kwargs) | ||
|
|
||
| return self._new_search(query=query, **kwargs) |
There was a problem hiding this comment.
Preserve playback helpers for default searches
When an existing call uses the common default form video.search("..."), it now reaches this branch and returns a SearchResponse instead of the previous SearchResult. For shot responses the wrapper only exposes get_shots/iteration and does not delegate compile(), play(), or get_embed_code(), so code that compiles or plays default search results now fails with AttributeError. Either keep shot searches returning a SearchResult-compatible object or add those passthrough helpers to SearchResponse.
Useful? React with 👍 / 👎.
| for name, value in zip(legacy_arg_names, args): | ||
| kwargs.setdefault(name, value) | ||
|
|
||
| has_old = bool(args) or any(k in kwargs and kwargs[k] is not None for k in old_params) |
There was a problem hiding this comment.
Route legacy stitch searches to legacy_search
The legacy Video.search accepted extra endpoint flags through **kwargs, including stitch, but old_params does not include those legacy-only keys. A call such as video.search("...", stitch=True) therefore no longer goes through legacy_search; it is posted to /video/{id}/search/v2, so the legacy endpoint never receives the flag. Add the legacy passthrough flags to the detection set, or otherwise route them before falling through to the v2 search.
Useful? React with 👍 / 👎.
…deodb-python into feat/add-indexing-v2
No description provided.