Fix a regression with matching repository and review group conditions.

Review Request #10435 — Created Feb. 26, 2019 and submitted

chipx86
Review Board
release-3.0.x
reviewboard

The recent access controls added for repository and review group choices
for conditions resulted in a regression when matching these. Both of
these implemented queryset logic that assumed access to an
HttpRequest, but this wasn't the case during matching. The attempts
caused a KeyError, which was getting caught at the wrong level and
transformed into an entirely different form of error.

This fixes the regression by changing the querysets yet again. Now, if
we're in a condition matching mode (as indicated by a new matching
state set for the choices), we revert back to a simpler query that
just filters on the Local Site.

Verified the failure in new unit tests, and that the issue is now
fixed.

Summary
Fix a regression with matching repository and review group conditions.
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-3.0.x (0baa0ea)
Loading...