Page MenuHomePhabricator

When a transaction adds more than 100 inline comments, include only the first 100 in email
ClosedPublic

Authored by epriestley on Sep 4 2018, 6:01 PM.
Tags
None
Referenced Files
F13273388: D19632.diff
Fri, May 31, 1:52 AM
F13233323: D19632.diff
Tue, May 21, 2:12 AM
F13211314: D19632.diff
Fri, May 17, 5:39 AM
F13195077: D19632.diff
Sun, May 12, 10:06 PM
F13177851: D19632.diff
Wed, May 8, 8:00 PM
Unknown Object (File)
Apr 25 2024, 12:51 AM
Unknown Object (File)
Apr 23 2024, 11:04 AM
Unknown Object (File)
Mar 17 2024, 5:23 PM
Subscribers
None

Details

Summary

Ref T13195. An install had a user apply a transaction which added about 1,000 inline comments. Rendering the email for this transaction took a very long time because the context section for each comment must be highlighted separately.

We can make the highlighting faster (in this case, by porting the lexer to PHP) but it's also sort of silly to include more than 100 inlines in an email. These emails are likely to be truncated by outbound size rules at some point anyway. Instead, limit inlines rendered directly into email to the first 100 per transaction group.

Test Plan

Set limit to 2, added 4 comments, viewed text and HTML emails:

Screen Shot 2018-09-04 at 10.40.37 AM.png (309×551 px, 24 KB)

Screen Shot 2018-09-04 at 10.41.03 AM.png (515×470 px, 57 KB)

Diff Detail

Repository
rP Phabricator
Branch
inlinelimit1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 20733
Build 28185: Run Core Tests
Build 28184: arc lint + arc unit