Page MenuHomePhabricator

Provisioning the math role results in an "unmet dependencies" dpkg error
Closed, ResolvedPublic

Description

Puppet output of failed provision

Provisioning the math role on a fresh mediawiki-vagrant VM results in an "unmet dependencies" dpkg error (attached is the full puppet output, below just the failed resource):

err: /Stage[main]/Packages::Mediawiki_math/Package[mediawiki-math]/ensure: change from purged to present failed: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install mediawiki-math' returned 100: Reading package lists...
Building dependency tree...
Reading state information...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
mediawiki-math : Depends: mediawiki-extensions-math but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Removing the packages::mediawiki_math resource from the math role avoids the package dependency error and compilation of texvc and texvccheck succeeds. Can we remove this dependency on the package altogether, or is there some utility included in the package that's required for Math to function?


Version: unspecified
Severity: normal
See Also:
https://bugzilla.wikimedia.org/show_bug.cgi?id=61090

Attached:

Details

Reference
bz66807

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:23 AM
bzimport set Reference to bz66807.

(In reply to Dan Duvall from comment #0)

Removing the packages::mediawiki_math resource from the math role avoids
the package dependency error and compilation of texvc and texvccheck
succeeds. Can we remove this dependency on the package altogether, or is
there some utility included in the package that's required for Math to
function?

I honestly don't remember why the deb package was needed or if I just threw it in their based on cut-n-paste. Maybe Physikerwelt can tell us if it actually needed or not. I've added him as a CC.

physik wrote:

If you use the PNG output mode, a latex installation is required.
The required latex related stuff is installed via the mediawiki_math package.
If you are using the MathML+SVG rendering mode the package is not needed.

It looks like it's trying to install the version from apt.wikimedia.org:

vagrant@mediawiki-vagrant:~$ apt-cache policy mediawiki-math
mediawiki-math:

Installed: (none)
Candidate: 2:1.0+git20140526-1
Version table:
   2:1.0+git20140526-1 0
      500 http://apt.wikimedia.org/wikimedia/ precise-wikimedia/main amd64 Packages
   1:1.15.5-7 0
      500 http://archive.ubuntu.com/ubuntu/ precise/universe amd64 Packages

That then apparently depends on mediawiki-extensions-math:

vagrant@mediawiki-vagrant:~$ apt-cache depends mediawiki-math
mediawiki-math

Depends: mediawiki-extensions-math
Conflicts: mediawiki-math:i386

It's not clear why mediawiki-extensions-math won't install, but I don't think it would make sense if it did.

vagrant@mediawiki-vagrant:~$ apt-cache depends mediawiki-extensions-math
mediawiki-extensions-math

Depends: mediawiki
Depends: mediawiki-math-texvc
Recommends: mediawiki-extensions-base

We don't want to use Mediawiki from an Ubuntu package.

MediaWiki-Vagrant should probably depend on the required packages. I.E. it should install everything http://packages.ubuntu.com/precise/mediawiki-math depends on, but not mediawiki-math itself, which is apparently just texvc (http://packages.ubuntu.com/precise/amd64/mediawiki-math/filelist) (not confirmed since that's Ubuntu's list, not the list from our own deb repo)

I think it should build texvc, since that's still part of the Math repo (https://git.wikimedia.org/blob/mediawiki%2Fextensions%2FMath.git/877a0b447ba661ef0a3618bf3c7c5620f25eac59/math%2Ftexvc.ml), and MWV is primarily a tool for development.

In the meantime, it's installing texlive-latex-extra-doc, which in Trusty is 309 MB (http://packages.ubuntu.com/trusty/texlive-latex-extra-doc).

I can't figure out exactly how this is being depended on. I would have thought it would only be a recommends.

This shouldn't be installed (people can find it online or install it manually).

(In reply to Matthew Flaschen from comment #4)

In the meantime, it's installing texlive-latex-extra-doc, which in Trusty is
309 MB (http://packages.ubuntu.com/trusty/texlive-latex-extra-doc).

I can't figure out exactly how this is being depended on. I would have
thought it would only be a recommends.

Apparently puppet installs recommended packages when it uses apt [0]. Untested, but it may be possible to pass install_options => ['--no-install-recommends'], in the package description to stop this.

[0]: http://serverfault.com/questions/513588/no-apt-recommends-with-puppet

Change 147874 had a related patch set uploaded by BryanDavis:
Remove Package[mediawiki-math] from role::math

https://gerrit.wikimedia.org/r/147874

physik wrote:

I think that should be synchronized with the math packages that should be used in production (for the PNG rendering mode)
https://gerrit.wikimedia.org/r/#/c/115133/7/modules/mediawiki/manifests/packages/math.pp

(In reply to physikerwelt from comment #7)

I think that should be synchronized with the math packages that should be
used in production (for the PNG rendering mode)
https://gerrit.wikimedia.org/r/#/c/115133/7/modules/mediawiki/manifests/
packages/math.pp

{{done}}

Change 147874 merged by jenkins-bot:
Remove Package[mediawiki-math] from role::math

https://gerrit.wikimedia.org/r/147874