Opened 5 years ago

Closed 5 years ago

#30779 closed Cleanup/optimization (fixed)

technical_500.html: use filename:lineno format for exception location

Reported by: Daniel Hahler Owned by: Mariusz Felisiak <felisiak.mariusz@…>
Component: Error reporting Version: dev
Severity: Normal Keywords:
Cc: Hasan Ramezani Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Mariusz Felisiak)

Using

Exception Location: 	…/dj/views.py, line 28, in form_valid

instead of

Exception Location: 	…/dj/views.py in form_valid, line 28

would allow for easier copy'n'paste of the location for going there in an editor.

The format fname:lnum is usually handled there to go to the line number there directly.

By default this does not work as good as it could then, since browsers will not include the ":" on double-click (tested Firefox and qutebrowser), but the "text-select" CSS property can be used for this, which then selected it with a single click already. Ref: https://developer.mozilla.org/en-US/docs/Web/CSS/user-select

https://github.com/django/django/pull/11789

Change History (6)

comment:1 by Daniel Hahler, 5 years ago

Description: modified (diff)
Has patch: set
Patch needs improvement: set

comment:2 by Carlton Gibson, 5 years ago

Triage Stage: UnreviewedAccepted

Hey Daniel. Yes, sounds like a nice gain. I am certainly happy to review a PR on it. :) Thanks.

comment:3 by Daniel Hahler, 5 years ago

Thanks Carlton.

Please see https://github.com/django/django/pull/11789 then.
It probably only needs test adjustments, which I'd like to do only in the end.

comment:4 by Hasan Ramezani, 5 years ago

Cc: Hasan Ramezani added
Patch needs improvement: unset
Version 0, edited 5 years ago by Hasan Ramezani (next)

comment:5 by Mariusz Felisiak, 5 years ago

Description: modified (diff)

comment:6 by Mariusz Felisiak <felisiak.mariusz@…>, 5 years ago

Owner: set to Mariusz Felisiak <felisiak.mariusz@…>
Resolution: fixed
Status: newclosed

In 377018b6:

Fixed #30779 -- Improved selection of filenames in technical 500 debug page.

Note: See TracTickets for help on using tickets.
Back to Top