`select:` for simple query doesn't stream
Created by: rvantonder
I think this should stream, but it doesn't. To investigate....
(parse(.|\n)*parameters)|(parameters(.|\n)*parse) file:\.go select:repo
The code this kind of query runs through out to be sending results as soon as it's deduped: https://sourcegraph.com/github.com/sourcegraph/sourcegraph/-/blob/internal/search/streaming/stream.go?L70&subtree=true
Locally it takes longer with select:repo
, and streams results without it, so there's definitely something up with the postprocessing.
I think it's because of this select:repo
optimization for zoekt, which doesn't stream: https://sourcegraph.com/github.com/sourcegraph/sourcegraph/-/blob/internal/search/zoekt/indexed_search.go?L401:22&subtree=true IT appears that way, because select:file
works just fine
Yeah it's because of this optimization, it's blocking and not sending results asap.
(parse(.|\n)*parameters)|(parameters(.|\n)*parse) file:\.go select:file
Branch
https://github.com/sourcegraph/sourcegraph/tree/rvt/debug-and-select