fontbakery icon indicating copy to clipboard operation
fontbakery copied to clipboard

Some checks result in an ERROR if Graphite tables are present in the font

Open devosb opened this issue 1 year ago • 1 comments

Observed behaviour

Font Bakery results in errors in some checks if the font has Graphite tables. At least this is the best I can determine with testing Padauk, Awami, and Dai Banna SIL.

More checks fail than what the test below is run on. Here are two tests, note that the traceback is slightly different in each one. type_error_dotted_circle and type_error_italic_angle

Expected behaviour

Checks run without errors.

Resources and steps needed to reproduce

The command used for testing with Padauk 5.001.

fontbakery check-googlefonts  -c dotted_circle Padauk-Regular.ttf

The errors happen with the latest Font Bakery (main branch from git), and also with v0.13.0a5. The errors do not happen with v0.12.10. The errors also do not happen, with any FB version, if there are no Graphite tables (Gloc, Glat, Silf, Sill).

Fonts with Graphite sometimes have other tables (Feat, Sile, Silt) but since these tables are not present in Padauk or Dai Banna SIL, I suspect the issue is with one or more of the the first four tables mentioned.

All of this is on Ubuntu 24.04 amd64 with Python 3.12.3.

devosb avatar Nov 25 '24 22:11 devosb

Most, if not all, of the tracebacks are from deepcopy() being used to make a copy of a TTFont object, but I don't get such if I do something simple, e.g.,:

 ❯ python3
Python 3.12.3 (main, Nov  6 2024, 18:32:19) [GCC 13.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from copy import deepcopy
>>> from fontTools.ttLib import TTFont
>>> font = TTFont('Padauk-Regular.ttf')
>>> font2 = deepcopy(font)
>>>

bobh0303 avatar Nov 25 '24 23:11 bobh0303