Page MenuHomePhabricator

Clean up "Audit Authority" code, at least mostly
ClosedPublic

Authored by epriestley on Jan 25 2017, 7:51 PM.
Tags
None
Referenced Files
F12835739: D17251.id41493.diff
Thu, Mar 28, 3:22 PM
Unknown Object (File)
Mon, Mar 25, 4:24 AM
Unknown Object (File)
Sat, Mar 2, 9:33 AM
Unknown Object (File)
Feb 12 2024, 8:47 AM
Unknown Object (File)
Jan 28 2024, 12:39 PM
Unknown Object (File)
Jan 21 2024, 8:56 AM
Unknown Object (File)
Jan 16 2024, 11:13 AM
Unknown Object (File)
Dec 27 2023, 9:33 AM
Subscribers
None

Details

Summary

Ref T2393. We had three copies of this code ("which packages/projects can a user accept on behalf of?"). I removed one in D17250. This consolidates the other two.

This still isn't perfect and it should probably live in a Query or something some day, but there's some weird stuff going on with the viewer in the editor context, and at least the code handles the viewer correctly now and isn't living somewhere weird and totally unrelated to auditing, and the callsites don't need to do a bunch of extra work.

This also moves towards fixing the "re-accept if you've already accepted but then a new package you have authority over was added" bug, which we fixed recently in Differential. This should be less common in Audit, but should still be fixed.

Test Plan

Viewed and audited commits with a mixture of user, package, and project auditors. Saw actions apply to the expected set of auditors.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Jan 25 2017, 8:44 PM
This revision was automatically updated to reflect the committed changes.