Closed Bug 1175644 Opened 9 years ago Closed 9 years ago

backport upstream bug 1174695 to bmo/master to improve cpanfile created by checksetup.pl

Categories

(bugzilla.mozilla.org :: General, defect)

Production
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: dkl, Assigned: emorley)

References

Details

Attachments

(1 file)

Bug 1143005 added a '--cpanfile' option to checksetup.pl which exports a cpanfile for use with utilities like cpanm.

The current exported file looks like:

"""
requires 'CGI', '3.51';
requires 'Digest::SHA';
requires 'Date::Format', '2.21';
...
feature 'graphical_reports', 'GD' => sub {
  recommends 'GD', '1.20';
};
feature 'new_charts', 'GD' => sub {
  recommends 'GD', '1.20';
};
feature 'old_charts', 'GD' => sub {
  recommends 'GD', '1.20';
};
feature 'new_charts', 'Chart' => sub {
  recommends 'Chart::Lines', '2.1.0';
};
...
"""

Unfortunately the duplicate features (ie: the two instances of feature 'new_charts' above; plus many more in the full file) confuse cpanm, causing it to only install the dependencies for the last definition of a feature.

This is why the docker project has to manually install a bunch of deps:


We should combine all of a particular feature's dependencies, and output them as one entry, eg:

feature 'new_charts', 'GD' => sub {
  recommends 'GD', '1.20';
  recommends 'Chart::Lines', '2.1.0';
};
Attached patch Patch for BMOSplinter Review
Attachment #8624245 - Flags: review?(dkl)
Comment on attachment 8624245 [details] [diff] [review]
Patch for BMO

Review of attachment 8624245 [details] [diff] [review]:
-----------------------------------------------------------------

Also looks good. r=dkl. Will commit once git.m.o is back up.
Attachment #8624245 - Flags: review?(dkl) → review+
To ssh://gitolite3@git.mozilla.org/webtools/bmo/bugzilla.git
   de934d2..655f762  master -> master
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Thank you :-)
Blocks: 1174967
You need to log in before you can comment on or make changes to this bug.