Hi Renan, Sorry for not replying to this before.
We've hit a few issues like that with Mercurial, and it partly has to do with how Mercurial represents file and revisions in their diffs. The standard Mercurial diff format has a lot of issues that make it difficult for us to extract meaningful revision history when generating a diff, particularly when dealing with ranges, and while the Git-like format is a bit better at this, it's not quite right either. We've done some work in the past couple releases of Review Board and RBTools to try to address this, at least for some cases. Can you verify whether these scenarios are still happening for you on Review Board 4.0.6 and RBTools 3? If you're still able to reproduce these, we'll need RBTools debug logs, the generated parent and main diffs, and some representation of the Mercurial tree showing the revisions and relations at the point when those logs were generated. Our long-term goal is to bypass the Mercurial diff formats and go with our DiffX format instead, which will give us greater control over how we're able to represent revision information for each file. Christian On Mon, Apr 11, 2022 at 12:48 PM Renan Moreira <[email protected]> wrote: > Any thoughts on this? > > Em quarta-feira, 9 de março de 2022 às 15:06:31 UTC-3, Renan Moreira > escreveu: > >> Hi, >> >> I have been trying to use the multi-commit feature from ReviewBoard 4.x >> and RBTools 2.x for quite a while now, but I eventually stumble on some >> errors while trying to post the review at some conditions. My setup is as >> follows: ReviewBoard 4.0.2, RBTools 2.0.1, Mercurial 4.5.3. >> >> It doesn't happen all the time, though. From what I could gather, it >> occurs in two scenarios: >> >> - Say you have two commits: A and B. If you change a certain file "X" >> from your repo at commit A, and then you proceed to changing a different >> file "Y" at commit B, the error pops up while trying to post commit B, >> telling that file Y wasn't found in the repository. If you post the >> commits >> separately, though, it works fine, so the file does exist after all. The >> error can be seen below: >> >> >> Validating commits... [0/2] Validating commits... >> ████████████████████████████████████████████████████ [2/2] Uploading >> commits... [0/2] Uploading commits... ██████████████████████████ [1/2] >> ERROR: Error uploading diff The file was not found in the repository. (HTTP >> 400, API Error 207) Your review request still exists, but the diff is not >> attached. >> >> - >> - There are some caveats, though: if, at commit A, you change both >> X and Y, and at commit B you change Y, it works. >> - If you have 3 or more commits, it will fail at the first one >> that changes a file which wasn't changed at the first commit. >> - On the other hand, if you just create files at different >> commits, it works fines (but this relates to the second scenario, I >> will >> discuss it below). >> - Say you have, for example, 3 commits - A, B, and C -, and you >> create a file X at commit A. At commit B, you don't change the file. At >> commit C, you change that file X you created in A. This pops up the error, >> but now at the validation stage. See below: >> >> Validating commits... >> [0/3] >> Validating commits... ██████████████████████████████████▋ >> [2/3] >> Validating commits... ██████████████████████████████████▋ >> [2/3] >> ERROR: Error validating diff >> >> file1.txt: The file was not found in the repository. (HTTP 400, API Error >> 207) >> >> - file1.txt is X in this context. >> - Also, there are caveats: if you keep changing the file at every >> single commit, the error doesn't appear. >> - From what I observed, it happens when there's at least one >> commit in-between that hasn't changed the said file. If you have 4 >> commits >> and create the file at the 1st and change it at the 4th, the error will >> appear at the 4th commit only. >> >> I have tried reinstalling RBTools and the error persists. Is there >> anything else that could be causing this? Or is it indeed a bug? >> >> Thanks! >> Renan >> > -- > Supercharge your Review Board with Power Pack: > https://www.reviewboard.org/powerpack/ > Want us to host Review Board for you? Check out RBCommons: > https://rbcommons.com/ > Happy user? Let us know! https://www.reviewboard.org/users/ > --- > You received this message because you are subscribed to the Google Groups > "Review Board Community" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/reviewboard/805d1029-dd1f-4d6d-8c30-a67ba8c811a8n%40googlegroups.com > <https://groups.google.com/d/msgid/reviewboard/805d1029-dd1f-4d6d-8c30-a67ba8c811a8n%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Christian Hammond President/CEO of Beanbag <https://www.beanbaginc.com/> Makers of Review Board <https://www.reviewboard.org/> -- Supercharge your Review Board with Power Pack: https://www.reviewboard.org/powerpack/ Want us to host Review Board for you? Check out RBCommons: https://rbcommons.com/ Happy user? Let us know! https://www.reviewboard.org/users/ --- You received this message because you are subscribed to the Google Groups "Review Board Community" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/reviewboard/CAE7Vnd%3DKp%2BG9vWNurB8vi45Gjf3ns_STKSq1pZ5MsCqvC%2Byo9A%40mail.gmail.com.
