radicle: Fix patch COB `review` action
When two review actions were posted by the same author, for the same
revision, an error was returned, cancelling evaluation for that author.
This caused certain patches to for eg. lose their merge status.
To remedy this, we allow multiple review actions per revision, but
simply take the last one as the “current” review. Since this makes the
review.edit action redundant, we remove that action completely. This
is safe, as none of the tools created review edits.
1 file changed
+55
-106
8922388c
→
757483f3
modified radicle/src/cob/patch.rs
@@ -1,6 +1,5 @@
|
|
|
|
| - | |
|
|
|
|
|
@@ -186,14 +185,6 @@ pub enum Action {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
|
|
|
|
|
@@ -658,15 +649,6 @@ impl Patch {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
|
|
|
|
|
@@ -804,29 +786,6 @@ impl Patch {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
|
|
|
|
|
@@ -891,30 +850,25 @@ impl Patch {
|
|
|
|
|
|
| - | |
| + | |
| + | |
|
|
|
|
|
|
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -1005,12 +959,13 @@ impl Patch {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| + | |
| + | |
| + | |
|
|
| - | |
| - | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -1293,10 +1248,13 @@ mod lookup {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -1322,10 +1280,10 @@ mod lookup {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -1360,8 +1318,8 @@ pub struct Revision {
|
|
|
|
|
|
| - | |
| - | |
| + | |
| + | |
|
|
|
|
|
@@ -1459,12 +1417,20 @@ impl Revision {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
|
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -1679,19 +1645,6 @@ impl<R: ReadRepository> store::Transaction<Patch, R> {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
|
|
|
|
|
@@ -1877,6 +1830,7 @@ impl<R: ReadRepository> store::Transaction<Patch, R> {
|
|
|
|
|
|
| + | |
|
|
|
|
|
@@ -2019,19 +1973,6 @@ where
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
|
|
|
|
|
@@ -3149,7 +3090,7 @@ mod test {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -3159,14 +3100,15 @@ mod test {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| + | |
| + | |
|
|
| + | |
| + | |
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -3239,11 +3181,17 @@ mod test {
|
|
|
|
|
|
| - | |
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -3251,6 +3199,7 @@ mod test {
|
|
|
|
|
|
| + | |
|
|
|
|
|