question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

crash on using mutator to instantiate from a VF

See original GitHub issue

Hi. I am using a script @chrissimpkins wrote to instantiate statics from a VF. It looks like mutator/ttLib is crashing on the gvar table.

Traceback (most recent call last):
  File "/Users/stupakm/Documents/freelance/code_apps_etc/vf2s.py", line 170, in <module>
    main()
  File "/Users/stupakm/Documents/freelance/code_apps_etc/vf2s.py", line 118, in main
    instantiateVariableFont(font, instance_location, inplace=True)
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/varLib/mutator.py", line 178, in instantiateVariableFont
    gvar = varfont['gvar']
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/ttLib/ttFont.py", line 392, in __getitem__
    table.decompile(data, self)
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/ttLib/tables/_g_v_a_r.py", line 111, in decompile
    numPointsInGlyph, sharedCoords, axisTags, gvarData)
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/ttLib/tables/_g_v_a_r.py", line 227, in decompileGlyph_
    sharedTuples, data, 4, offsetToData)
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/ttLib/tables/TupleVariation.py", line 553, in decompileTupleVariationStore
    tableTag, axisTags, tupleData, pointDeltaData))
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/ttLib/tables/TupleVariation.py", line 596, in decompileTupleVariation_
    len(points), tupleData, pos)
  File "/Users/stupakm/venvs/type-tools-py3/lib/python3.7/site-packages/fontTools/ttLib/tables/TupleVariation.py", line 414, in decompileDeltas_
    runHeader = byteord(data[pos])
IndexError: index out of range

The file I’m using here is the Italic in my Open Sans repo. (The Roman works fine.)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:14 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
benkielcommented, Apr 8, 2019

@laerm0 Oh man, if it stopped doing that I’d be so happy. I doubt I’m on the latest, I pick VTT up every couple months, so I’m not frequently using it. Thank you for the tip!

1reaction
anthrotypecommented, Apr 8, 2019

oh I misunderstood. In any case, whatever tool you’re using to post-process OpenSans as fontTools varLib originally built it, that may be modifying the glyph point indexes in the glyf table, will inevitably break gvar.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Script to instantiate an object is crashing unity
This problem is because you are replicating the object itself at start() and at the instantiate moment the clone object, the clone that...
Read more >
Support brace and bracket layers · Issue #468
For every brace layer, make a new source entry with the ... crash on using mutator to instantiate from a VF fonttools/fonttools#1548.
Read more >
Crash when using GameObject.Instantiate
A public field or private with SerializeField attribute in a MonoBehaviour will make Unity crash if this field is from an abstract class...
Read more >
Address Translation and Storage Management for Persistent ...
protect against failures and crashes. Similar to the address translation strategy, Texas uses virtual memory protections to.
Read more >
Apache HBase ™ Reference Guide
This reference guide is marked up using AsciiDoc from which the finished ... For example, if an active master crashed and the a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found