Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
8bc37c2d
You need to sign in or sign up before continuing.
Commit
8bc37c2d
authored
May 14, 2010
by
Max Kanat-Alexander
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 372537: Improve CodeErrors: show the traceback (without function
arguments) r=LpSolit, a=LpSolit
parent
0d8aa275
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
0 deletions
+11
-0
Error.pm
Bugzilla/Error.pm
+8
-0
code-error.html.tmpl
template/en/default/global/code-error.html.tmpl
+3
-0
No files found.
Bugzilla/Error.pm
View file @
8bc37c2d
...
...
@@ -31,6 +31,8 @@ use base qw(Exporter);
use
Bugzilla::
Constants
;
use
Bugzilla::WebService::
Constants
;
use
Bugzilla::
Util
;
use
Carp
;
use
Date::
Format
;
# We cannot use $^S to detect if we are in an eval(), because mod_perl
...
...
@@ -50,6 +52,12 @@ sub _throw_error {
$vars
||=
{};
$vars
->
{
error
}
=
$error
;
# Don't show function arguments, in case they contain confidential data.
local
$
Carp::
MaxArgNums
=
-
1
;
# Don't show the error as coming from Bugzilla::Error, show it as coming
# from the caller.
local
$
Carp::
CarpInternal
{
'Bugzilla::Error'
}
=
1
;
$vars
->
{
traceback
}
=
Carp::
longmess
();
# Make sure any transaction is rolled back (if supported).
# If we are within an eval(), do not roll back transactions as we are
...
...
template/en/default/global/code-error.html.tmpl
View file @
8bc37c2d
...
...
@@ -539,6 +539,9 @@
</tr>
</table>
<p>Traceback:</p>
<pre>[% traceback FILTER html_linebreak %]</pre>
[% IF variables %]
<pre>
Variables:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment