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
00ff4004
Commit
00ff4004
authored
Mar 28, 2013
by
Byron Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 850639: Set an upper limit on the number of nodes the dependency graph will display
r=LpSolit, a=LpSolit
parent
f5e0b805
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
3 deletions
+18
-3
Constants.pm
Bugzilla/Constants.pm
+4
-0
showdependencygraph.cgi
showdependencygraph.cgi
+9
-3
user-error.html.tmpl
template/en/default/global/user-error.html.tmpl
+5
-0
No files found.
Bugzilla/Constants.pm
View file @
00ff4004
...
@@ -167,6 +167,7 @@ use Memoize;
...
@@ -167,6 +167,7 @@ use Memoize;
MAX_POSSIBLE_DUPLICATES
MAX_POSSIBLE_DUPLICATES
MAX_ATTACH_FILENAME_LENGTH
MAX_ATTACH_FILENAME_LENGTH
MAX_QUIP_LENGTH
MAX_QUIP_LENGTH
MAX_WEBDOT_BUGS
PASSWORD_DIGEST_ALGORITHM
PASSWORD_DIGEST_ALGORITHM
PASSWORD_SALT_LENGTH
PASSWORD_SALT_LENGTH
...
@@ -570,6 +571,9 @@ use constant MAX_ATTACH_FILENAME_LENGTH => 255;
...
@@ -570,6 +571,9 @@ use constant MAX_ATTACH_FILENAME_LENGTH => 255;
# Maximum length of a quip.
# Maximum length of a quip.
use
constant
MAX_QUIP_LENGTH
=>
512
;
use
constant
MAX_QUIP_LENGTH
=>
512
;
# Maximum number of bugs to display in a dependency graph
use
constant
MAX_WEBDOT_BUGS
=>
2000
;
# This is the name of the algorithm used to hash passwords before storing
# This is the name of the algorithm used to hash passwords before storing
# them in the database. This can be any string that is valid to pass to
# them in the database. This can be any string that is valid to pass to
# Perl's "Digest" module. Note that if you change this, it won't take
# Perl's "Digest" module. Note that if you change this, it won't take
...
...
showdependencygraph.cgi
View file @
00ff4004
...
@@ -29,7 +29,7 @@ my $vars = {};
...
@@ -29,7 +29,7 @@ my $vars = {};
# performance.
# performance.
my
$dbh
=
Bugzilla
->
switch_to_shadow_db
();
my
$dbh
=
Bugzilla
->
switch_to_shadow_db
();
local
our
(
%
seen
,
%
edgesdone
,
%
bugtitles
);
our
(
%
seen
,
%
edgesdone
,
%
bugtitles
,
$bug_count
);
# CreateImagemap: This sub grabs a local filename as a parameter, reads the
# CreateImagemap: This sub grabs a local filename as a parameter, reads the
# dot-generated image map datafile residing in that file and turns it into
# dot-generated image map datafile residing in that file and turns it into
...
@@ -76,6 +76,7 @@ sub AddLink {
...
@@ -76,6 +76,7 @@ sub AddLink {
if
(
!
exists
$edgesdone
{
$key
})
{
if
(
!
exists
$edgesdone
{
$key
})
{
$edgesdone
{
$key
}
=
1
;
$edgesdone
{
$key
}
=
1
;
print
$fh
"$dependson -> $blocked\n"
;
print
$fh
"$dependson -> $blocked\n"
;
$bug_count
++
;
$seen
{
$blocked
}
=
1
;
$seen
{
$blocked
}
=
1
;
$seen
{
$dependson
}
=
1
;
$seen
{
$dependson
}
=
1
;
}
}
...
@@ -108,10 +109,10 @@ chmod Bugzilla::Install::Filesystem::CGI_WRITE, $filename
...
@@ -108,10 +109,10 @@ chmod Bugzilla::Install::Filesystem::CGI_WRITE, $filename
my
$urlbase
=
Bugzilla
->
params
->
{
'urlbase'
};
my
$urlbase
=
Bugzilla
->
params
->
{
'urlbase'
};
print
$fh
"digraph G {"
;
print
$fh
"digraph G {"
;
print
$fh
qq
{
print
$fh
qq
(
graph [URL="${urlbase}query.cgi", rankdir=$rankdir]
graph [URL="${urlbase}query.cgi", rankdir=$rankdir]
node [URL="${urlbase}show_bug.cgi?id=\\N", style=filled, color=lightgrey]
node [URL="${urlbase}show_bug.cgi?id=\\N", style=filled, color=lightgrey]
}
;
)
;
my
%
baselist
;
my
%
baselist
;
...
@@ -224,6 +225,11 @@ foreach my $k (@bug_ids) {
...
@@ -224,6 +225,11 @@ foreach my $k (@bug_ids) {
print
$fh
"}\n"
;
print
$fh
"}\n"
;
close
$fh
;
close
$fh
;
if
(
$bug_count
>
MAX_WEBDOT_BUGS
)
{
unlink
(
$filename
);
ThrowUserError
(
"webdot_too_large"
);
}
my
$webdotbase
=
Bugzilla
->
params
->
{
'webdotbase'
};
my
$webdotbase
=
Bugzilla
->
params
->
{
'webdotbase'
};
if
(
$webdotbase
=~
/^https?:/
)
{
if
(
$webdotbase
=~
/^https?:/
)
{
...
...
template/en/default/global/user-error.html.tmpl
View file @
00ff4004
...
@@ -1798,6 +1798,11 @@
...
@@ -1798,6 +1798,11 @@
Sorry, but you are not allowed to (un)mark comments or attachments
Sorry, but you are not allowed to (un)mark comments or attachments
as private.
as private.
[% ELSIF error == "webdot_too_large" %]
[% title = "Dependency Graph Too Large" %]
The dependency graph contains too many [% terms.bugs %] to display (more
than [% constants.MAX_WEBDOT_BUGS FILTER html %] [%+ terms.bugs %]).
[% ELSIF error == "wrong_token_for_cancelling_email_change" %]
[% ELSIF error == "wrong_token_for_cancelling_email_change" %]
[% title = "Wrong Token" %]
[% title = "Wrong Token" %]
That token cannot be used to cancel an email address change.
That token cannot be used to cancel an email address change.
...
...
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