Only update stream filter when we have >0 URIs #2419

Merged
merged 1 commit into from Jul 31, 2015

Projects

None yet

4 participants

@nickstenning
Member

The backend code in h.streamer assumes that the arguments to "one_of"
are either a non-empty list or a single value. Passing an empty list
causes the generation of a bogus query.

So, don't update the stream filter until we have at least one URI to
stream for.

Fixes #2257.

I've considered fixing this in h.streamer and also writing tests for h.streamer or this code in WidgetController. I don't think costs of any of these options is justified by the benefits, given we already know h.streamer is a disaster and needs to die in a fire.

@nickstenning nickstenning Only update stream filter when we have >0 URIs
The backend code in `h.streamer` assumes that the arguments to "one_of"
are either a non-empty list or a single value. Passing an empty list
causes the generation of a bogus query.

So, don't update the stream filter until we have at least one URI to
stream from.

Fixes #2257.
cc70c56
@landscape-bot

Code Health
Code quality remained the same when pulling cc70c56 on hypothesis:fix-broken-uri-query into 3920527 on hypothesis:master.

@seanh seanh merged commit 8c7074f into master Jul 31, 2015

3 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
coverage/coveralls Coverage remained the same at 62.231%
Details
@seanh seanh deleted the fix-broken-uri-query branch Jul 31, 2015
@tilgovi
Contributor
tilgovi commented Jul 31, 2015

🍰

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment