googlefonts / roboto-2

The Roboto family of fonts
Apache License 2.0
3.85k stars 309 forks source link

Roboto's woff2 from fonts.google.com no longer loads in Firefox #263

Open louisremi opened 7 years ago

louisremi commented 7 years ago

I'm not sure when things went bad, but I'm unable to get Firefox Nightly to display Roboto. Here are the error I get in the devtools:

downloadable font: Layout: DFLT script doesn't satisfy the spec. DefaultLangSys is NULL (font-family: "Roboto" style:normal weight:normal stretch:normal src index:2) source: http://fonts.gstatic.com/s/roboto/v16/CWB0XYA8bzo0kSThX0UTuA.woff2
css:57:12
downloadable font: Layout: Failed to parse script table 0 (font-family: "Roboto" style:normal weight:normal stretch:normal src index:2) source: http://fonts.gstatic.com/s/roboto/v16/CWB0XYA8bzo0kSThX0UTuA.woff2
css:57:12
downloadable font: GSUB: Failed to parse script list table (font-family: "Roboto" style:normal weight:normal stretch:normal src index:2) source: http://fonts.gstatic.com/s/roboto/v16/CWB0XYA8bzo0kSThX0UTuA.woff2
css:57:12
downloadable font: GSUB: Failed to parse table (font-family: "Roboto" style:normal weight:normal stretch:normal src index:2) source: http://fonts.gstatic.com/s/roboto/v16/CWB0XYA8bzo0kSThX0UTuA.woff2
css:57:12
downloadable font: rejected by sanitizer (font-family: "Roboto" style:normal weight:normal stretch:normal src index:2) source: http://fonts.gstatic.com/s/roboto/v16/CWB0XYA8bzo0kSThX0UTuA.woff2
davelab6 commented 7 years ago

Mozilla needs to maintain ots.

khaledhosny commented 7 years ago

@dave this is different from the other DFLT related issue that got amended in the OT spec. The spec still requires DefaultLangSys to not be NULL (it would be interesting to see if any implementation really requires this).

Anyway, AFAIK this only affects nightly Firefox, both Chrome and release/beta Firefox disable OTL sanitization since the fonts will always go through HarfBuzz.

davelab6 commented 7 years ago

Maybe OTS should just not bother, then?

khaledhosny commented 7 years ago

I wanted to do that a while ago, but there was a push back to follow the spec here. The spec update eliminated one of the limitations of DFLT script but not the other (in effect here). Since the two main OTS clients are not practically affected by this, I rather prefer to keep the check least there is a legitimate way this breaks some layout engine.

davelab6 commented 7 years ago

Perhaps comment out the code so that if we do find it breaks something it can very easily be added back?

khaledhosny commented 7 years ago

This was an issue with FontTools subsetter, so should be fixed now.

0gust1 commented 7 years ago

@louisremi If you disable gfx.downloadable_fonts.otl_validation in about:config screen of firefox, does it works ?

It's a nightly and mozilla team are heavily working on the rendering part of the browser, I bet it's temporary