Page MenuHomePhabricator

Add Gujarati fonts to Wikimedia servers
Closed, ResolvedPublic

Description

During T122407 handling, it appears Gujarati fonts aren't installed on Wikimedia servers.

For example, the logo for this Wikimedia project uses the Rekha font, which is currently not rendered in PNG.

On Debian and Ubuntu, these fonts for Gujarati script, including Rekha, are provided by the fonts-gujr-extra package..

Event Timeline

Dereckson triaged this task as Medium priority.Mar 10 2016, 4:43 PM
Dereckson added projects: Puppet, Commons.
Dereckson added a subscriber: M0tty.

Change 276501 had a related patch set uploaded (by Dereckson):
Add Gujarati fonts to mediawiki::packages::fonts

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

Change 276501 merged by Dzahn:
Add Gujarati fonts to mediawiki::packages::fonts

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

This has been merged and i confirmed the fonts-gujr-extra gets installed now by puppet. This happens on the imagescalers but not on all appservers (as is the case with the other font packages in that list currently).

Breaks puppet in on some labs instances that still use precise, because that package doesn't exist in precise.

Change 276792 had a related patch set uploaded (by Dzahn):
mediawiki: do not install fonts-gujr-extra on precise

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

Change 276792 merged by Dzahn:
mediawiki: do not install fonts-gujr-extra on precise

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

from site.pp:

# mw1153-1160 are imagescalers (trusty)
#mw2086-mw2089 are imagescalers
#mw2148-mw2151 are imagescalers

unfortunately another issue with this:

it conflicts with ttf-gujarati-fonts . on every puppet run one will be removed and the other will be added back again

mw2089 and also mw1153:

$ apt-cache show fonts-gujr-extra | grep -e 'Break\|Replace'
Replaces: ttf-gujarati-fonts
Breaks: ttf-gujarati-fonts (<< 2:1.0)

Change 276812 had a related patch set uploaded (by Dzahn):
mediawiki: ttf-gujarati-fonts replaced by fonts-gujr-extra

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

Change 276812 merged by Dzahn:
mediawiki: ttf-gujarati-fonts replaced by fonts-gujr-extra

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

Dzahn set Security to None.

after this the next issue on tools-webgrid- :/ (trusty)

ttf-indic-fonts : Depends: ttf-gujarati-fonts (= 1:0.5.14ubuntu1)

*SIGH*

Change 276825 had a related patch set uploaded (by Dzahn):
mediawiki: revert adding fonts-gujr-extra

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

Change 276825 merged by Dzahn:
mediawiki: revert adding fonts-gujr-extra

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

for this to work on all distros, precise, trusty and jessie the entire fonts.pp needs to be restructured. (or we need to get rid of precise first to at least remove that part).

something like https://gerrit.wikimedia.org/r/#/c/218640/ and more is needed or we will always run into issues one way or the other when changing font packages

Change 284655 had a related patch set uploaded (by Muehlenhoff):
Add additional Gujarati fonts (Rekha) (fonts-gujr-extra)

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

I tried to do this ^ and ran into issues. but you are fixing those with https://gerrit.wikimedia.org/r/#/c/284653/ first , then it should be fine it looks

Change 284655 merged by Muehlenhoff:
Add additional Gujarati fonts (Rekha) (fonts-gujr-extra)

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

MoritzMuehlenhoff subscribed.

fonts-gujr-extra has been added to the package list and deployed.

hashar subscribed.

Since fonts-gujr-extra got installed via https://gerrit.wikimedia.org/r/#/c/284655/2/modules/mediawiki/manifests/packages/fonts.pp,cm on the beta cluster there is a conflict with rtf-gujarati-fonts causing puppet to uninstall/reinstall.

On deployment-tmh01.deployment-prep.eqiad.wmflabs (Trusty):

Notice: /Stage[main]/Mediawiki::Packages::Fonts/Package[fonts-gujr-extra]/ensure: created

Then

Notice: /Stage[main]/Packages::Ttf_gujarati_fonts/Package[ttf-gujarati-fonts]/ensure: ensure changed 'purged' to 'present'

etc

fonts-gujr-extra has:

Replaces: ttf-gujarati-fonts
Breaks: ttf-gujarati-fonts (<< 2:1.0)

So it looks like we want to drop ttf-gujarati-fonts from our puppet manifest.

Jessie does not have ttf-gujarati-fonts but does have fonts-gujr-extra.

Change 285621 had a related patch set uploaded (by Muehlenhoff):
Only install font-gujr-extra on jessie

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

Change 285621 merged by Dzahn:
Only install font-gujr-extra on jessie

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

On Jessie we now have: fonts-gujr, fonts-gujr-extra. Dropping all references of those packages and running puppet yields the correct:

Notice: /Stage[main]/Packages::Fonts_gujr/Package[fonts-gujr]/ensure: ensure changed 'purged' to 'present'

Which results in the following packages status:

fonts-gujrInstalled
fonts-gujr-extraInstalled
fonts-lohit-gujrInstalled
fonts-samyak-gujrInstalled
ttf-gujrati-fontsNot installed as expected
ttf-gujrati-fontsNot installed as expected

Jessie has some meta package fonts-indic which replaces ttf-indic-fonts. It does install fonts-gujr-extra.


On Trusty we have ttf-gujarati-fonts installed:

ttf-gujarati-fontsInstalled and part of meta package ttf-indic-fonts-core
fonts-gujr-extrasNot installed (conflict with above)
fonts-lohit-gujrNot installed, should it be?
fonts-samyaj-gujrNot installed, should it be?

ttf-gujarati-fonts on Trusty provides:

usr/share/fonts/truetype/ttf-gujarati-fonts/padmaa-Medium-0.5.ttf
/usr/share/fonts/truetype/ttf-gujarati-fonts/aakar-medium.ttf
/usr/share/fonts/truetype/ttf-gujarati-fonts/Samyak-Gujarati.ttf
/usr/share/fonts/truetype/ttf-gujarati-fonts/padmaa-Bold.1.1.ttf
/usr/share/fonts/truetype/ttf-gujarati-fonts/padmaa.ttf

While fonts-gujr-extra (not installed) ships Aakar, Padmaa and Rekha. Then ttf-indic-fonts installs ttf-indic-fonts-core which claims to install Rekha and indeed it has:

/usr/share/fonts/truetype/ttf-indic-fonts-core/Pothana2000.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/lohit_bn.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Meera_04.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/MuktiNarrow.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Kedage-b.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/utkal.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Kedage-n.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/lohit_hi.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Malige-b.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/lohit_ta.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Rachana_04.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/MuktiNarrowBold.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Vemana.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/gargi.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/lohit_gu.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Malige-n.ttf
/usr/share/fonts/truetype/ttf-indic-fonts-core/Rekha.ttf

So on Trusty maybe we can drop ttf-gujarati-fonts and use ttf-indic-fonts instead.


So looks like we would want to use the Distribution meta packages instead:

DistroPackage
Trustyttf-indic-fonts
Jessiefonts-indic

Note the puppet manifest for OCG uses (among others):

Trustyttf-indic-fonts-core
Jessiefonts-gujr-extra

@hashar : Are the fonts on image scalers relevant for CI? We now have eight image scalers running on Debian jessie (which have the Gujarati fonts) and the trusty ones will be depooled next week. If it's not needed for CI, I'd simply close this bug again.

CI does not rely on it AFAIK. The only reason I had that task filled was as part of having mediawiki::packages puppet class to apply properly on a Jessie system ( T95002 ) since that is how the various dependencies are shipped on the CI slaves.

So that looks all good to me now since production is phasing out the Trusty image scalers (kudos on that one).

Thx!