Edgewall Software
Modify

Opened 8 years ago

Closed 8 years ago

#12761 closed defect (fixed)

Log reason for not rendering diff

Reported by: Ryan J Ollos Owned by: Ryan J Ollos
Priority: normal Milestone: 1.2.2
Component: version control Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:

Render message in place of diff when changeset is not rendered due to exceeding [changeset] max_diff_bytes or [changeset] max_diff_files.

API Changes:
Internal Changes:

Description

We could add some logging to make issues like gmessage:trac-users/-3XUG15vxcs/O4EvLXE_BAAJ easier to discover.

Attachments (4)

Screen Shot 2017-04-07 at 16.10.50.png (31.6 KB ) - added by Ryan J Ollos 8 years ago.
Screen Shot 2017-04-07 at 16.15.13.png (52.5 KB ) - added by Ryan J Ollos 8 years ago.
Screen Shot 2017-04-07 at 16.15.31.png (43.7 KB ) - added by Ryan J Ollos 8 years ago.
Screen Shot 2017-04-07 at 16.15.44.png (42.0 KB ) - added by Ryan J Ollos 8 years ago.

Download all attachments as: .zip

Change History (11)

comment:1 by Ryan J Ollos, 8 years ago

comment:2 by Peter Suter, 8 years ago

Good idea!

The line diff_bytes = diff_files = 0 could be moved inside the if self.max_diff_bytes or self.max_diff_files statement, right?

Maybe even nicer would be showing a message similar to the message that is displayed when the file content is omitted due to exceeding [mimeviewer] max_preview_size.

by Ryan J Ollos, 8 years ago

by Ryan J Ollos, 8 years ago

by Ryan J Ollos, 8 years ago

by Ryan J Ollos, 8 years ago

in reply to:  2 comment:3 by Ryan J Ollos, 8 years ago

Replying to Peter Suter:

Maybe even nicer would be showing a message similar to the message that is displayed when the file content is omitted due to exceeding [mimeviewer] max_preview_size.

That is a better idea.

I think we could improve the styling of the message, but I made it consistent with the message on the preview page:

Both messages are shown if both constraints are violated:

The 100 bytes is a link to TracIni#changeset-max_diff_bytes-option (if allowed by permission check).

The 2 files is a link to TracIni#changeset-max_diff_files-option (if allowed by permission check).

comment:4 by Ryan J Ollos, 8 years ago

Proposed changes in log:rjollos.git:t12761_max_size_warning. The changes are a bit complex because the py:strip can't be nested - the i18n:msg directive does not support nested directives.

Please note that i18n:msg directives do not support other nested directives. Directives commonly change the structure of the generated markup dynamically, which often would result in the structure of the text changing, thus making translation as a single message ineffective.

comment:5 by Ryan J Ollos, 8 years ago

Release Notes: modified (diff)

comment:6 by Ryan J Ollos, 8 years ago

Committed to 1.2-stable in r15787.

Proposed changes for trunk in [e1b40cb1/rjollos.git].

comment:7 by Ryan J Ollos, 8 years ago

Resolution: fixed
Status: assignedclosed

Committed to trunk in r15797.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Ryan J Ollos to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.