Repository navigation
feat: filter chats by diff URL via the q search parameter #24970
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| DROP INDEX IF EXISTS idx_chat_diff_statuses_url_lower; |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| -- Index on LOWER(url) supports case-insensitive lookups when filtering | ||
| -- chats by their associated diff URL (e.g. a pull request URL). | ||
| CREATE INDEX idx_chat_diff_statuses_url_lower | ||
| ON chat_diff_statuses (LOWER(url)) | ||
| WHERE url IS NOT NULL AND url <> ''; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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.
P3 [DEREM-2] No E2E test for
archived+diff_urlcomposition at the SQL layer. The parser testDiffURLWithArchivedproves both fields populateGetChatsParams, but the SQL query has two independentAND CASEclauses whose interaction is never tested against the database. Every chat in theDiffURLFilterfixture is unarchived.If one chat were archived with a matching diff URL, the default query (
archived:false) should exclude it, andarchived:true diff_url:"..."should surface it. Neither path is tested. Sketch: archiverootWithPR, then assert the filter excludes it by default and includes it whenarchived:trueis explicit.(Bisky)
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.
Done in c182a93. Added an archived fixture chat with its own diff URL plus two subtests:
ArchivedFilteredOutconfirms the defaultarchived:falseexcludes it, andArchivedTrueComposesconfirmsarchived:true diff_url:"..."surfaces it.