Interdiffs not displaying properly

51 views
Skip to first unread message

Teddy Saintvil

unread,
Apr 14, 2020, 4:49:44 PM4/14/20
to Review Board Community
Having issues with interdiffs displaying incorrectly in the diffviewer. I've attached screen shot of what gets displayed with a reproducer below.


original
// top of file

 
// comment
 
void foo();

// bottom of file

diff 1
// top of file

 
// comment
#if 0
 
void foo();
#endif

// bottom of file

diff 2
// top of file
#if 0
 
// comment
 
void foo();
#endif

// bottom of file


Screen Shot 2020-04-14 at 4.45.48 PM.png
Screen Shot 2020-04-14 at 4.47.05 PM.png

Christian Hammond

unread,
Apr 14, 2020, 9:30:10 PM4/14/20
to revie...@googlegroups.com
Hi Teddy,

We have a change we've been testing that fixes some corner cases like this. They tend to occur as a result of the interdiff algorithm's attempt at filtering out changes that aren't part of the uploaded diffs, based on metadata available in those diffs. The algorithm in 3.0.x has corner cases that tend to result at the very top or very bottom of files, as well as in some other more rare (but still seen in production) circumstances.

The new algorithm is being tested in the 4.0 work, and once we know it's stable, the plan is to backport to 3.0.x. It's a full rewrite designed to address these sorts of problems, but potentially could cause new ones, so we've been hesitant to make it available just yet. This will be in 4.0 beta 1, which we're nearing, and we'd love to get some testing on it when it's out.

Christian

--
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 reviewboard...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/reviewboard/a9fe52ca-4760-4fc4-a6b2-444df40c99e3%40googlegroups.com.


--
Christian Hammond
President/CEO of Beanbag
Makers of Review Board

Vlad S.

unread,
May 22, 2020, 4:55:36 AM5/22/20
to Review Board Community
huh, this bug is really annoying for .cc files.

вторник, 14 апреля 2020 г., 23:49:44 UTC+3 пользователь Teddy Saintvil написал:

Christian Hammond

unread,
May 22, 2020, 5:55:56 AM5/22/20
to revie...@googlegroups.com
I’ll look into doing an opt-in setting to enable the new behavior in an upcoming 3.x release.

Christian 


--
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 reviewboard...@googlegroups.com.
--

teds...@gmail.com

unread,
Mar 23, 2021, 9:48:21 AM3/23/21
to Review Board Community
Hello, our team recently upgraded to Reviewboard 3.0.20 and tried the opt-in setting to enable the new interdiff v2 algorithm by setting

ENABLED_FEATURES = { 'diffviewer.filter_interdiffs_v2': True, }

the above in conf/settings_local.py as instructed in the Reviewboard 3.0.19 release notes below.


using the same files in the reproducer in my initial message displays identical results with the issue we were facing.

We are using perforce as our repo of choice ( not sure if that makes any difference).

Did I miss something in enabling this new interdiff algorithim? Was it perhaps not available in Reviewboard 3.0.20?


Let us know if there is any other information we can provide to help.


- Teddy
Screen Shot 2021-03-23 at 9.43.04 AM.png
Screen Shot 2021-03-23 at 9.41.27 AM.png
Screen Shot 2021-03-23 at 9.40.35 AM.png

David Trowbridge

unread,
Mar 23, 2021, 1:27:44 PM3/23/21
to reviewboard
Teddy,

If you're viewing a diff that you had previously viewed before the upgrade, it's likely that old data may still be in cache. I'd suggest restarting your memcached service, clearing your browser cache, and then trying again.

David

teds...@gmail.com

unread,
Mar 26, 2021, 11:30:21 AM3/26/21
to Review Board Community
Thanks for the quick response.

Our instance of reviewboard is containerized so each time we spin up a new instance the cache should have been cleared. During our testing this issue we also spun a separate container without any data and uploaded the reproducer I submitted in initial message and it still displayed the same.
Reply all
Reply to author
Forward
0 new messages