glyphsLib fails to build UFOs from specific .glyphs file
See original GitHub issue- Get https://raw.githubusercontent.com/madig/cantarell-fonts/f17124d041e6ee370a9fcddcc084aa6cbf3d5500/src/Cantarell.glyphs
fontmake -g Cantarell.glyphs -o otf
INFO:fontmake.font_project:Building master UFOs and designspace from Glyphs source
INFO:glyphsLib.parser:Parsing .glyphs file
INFO:glyphsLib:Loading to UFOs
Traceback (most recent call last):
File "/home/nikolaus/.local/bin/fontmake", line 11, in <module>
sys.exit(main())
File "/home/nikolaus/.local/lib/python3.6/site-packages/fontmake/__main__.py", line 183, in main
project.run_from_glyphs(glyphs_path, **args)
File "/home/nikolaus/.local/lib/python3.6/site-packages/fontmake/font_project.py", line 376, in run_from_glyphs
glyphs_path, family_name, mti_source=mti_source)
File "/home/nikolaus/.local/lib/python3.6/site-packages/fontTools/misc/loggingTools.py", line 372, in wrapper
return func(*args, **kwds)
File "/home/nikolaus/.local/lib/python3.6/site-packages/fontmake/font_project.py", line 77, in build_master_ufos
family_name=family_name)
File "/home/nikolaus/.local/lib/python3.6/site-packages/glyphsLib/__init__.py", line 81, in build_masters
propagate_anchors=propagate_anchors)
File "/home/nikolaus/.local/lib/python3.6/site-packages/glyphsLib/__init__.py", line 59, in load_to_ufos
propagate_anchors=propagate_anchors)
File "/home/nikolaus/.local/lib/python3.6/site-packages/glyphsLib/builder/__init__.py", line 43, in to_ufos
result = list(builder.masters)
File "/home/nikolaus/.local/lib/python3.6/site-packages/glyphsLib/builder/builders.py", line 137, in masters
ufo_font = self._ufos[layer_id]
KeyError: ''
The same happens with
import glyphsLib
ufos = glyphsLib.build_instances('Cantarell.glyphs', "masters", "instances")
Issue Analytics
- State:
- Created 6 years ago
- Comments:9 (3 by maintainers)
Top Results From Across the Web
error when exporting to UFO and duplicate layers contain ...
When we export from .glyphs to UFO we need to make their name unique if we want to be able to store them....
Read more >Glyphs should clean-up or prune phantom layers when ...
I copied the glyph "verticallineabovecomb" from NotoSans-MM.glyphs over ... Issue: glyphsLib fails to build UFOs from specific .glyphs file.
Read more >fontmake - compile fonts from UFO or Glyphs to OTF/TTF
--no-production-names --subset Subset font using export flags set by glyphsLib --no-subset -s, --subroutinize Optimize CFF table using compreffor (default) ...
Read more >SIL Font Development Notes: Modifying Font Sources
Open the .glyphs file in Glyphs, make changes, and save. Run ./preflightg from the individual project folder. This reads the .glyphs file and ......
Read more >fontmake — Debian testing
NAME¶. fontmake - compile fonts from UFO or Glyphs to OTF/TTF ... --subset: Subset font using export flags set by glyphsLib. --no-subset.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I had the same problem. It is because I copied some glyphs from another font with more masters and the extra layers got preserved. It is not just layers without names, but also others which should not be there.
This Glyphs.app script helps to clean things up. (Run it multiple times. That’s because I am lazy to figure out how to delete all phantom layer systematically in one run.)
should be fixed by #291