googlefonts / googlefonts/glyphsLib

Round-tripping single UFO: no axes defined in designspace

Open
#423 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
201
Forks
56
Avg merge
17m
Merged PRs (30d)
1

Description

1. `git clone https://github.com/daltonmaag/ubuntu`
2. `ufo2glyphs ubuntu/source/Ubuntu-R.ufo`
3. `glyphs2ufo ubuntu/source/Ubuntu.glyphs`
4. `ufo2glyphs ubuntu/source/Ubuntu.designspace`
```
Traceback (most recent call last):
File "/Users/nikolaus/Entwicklung/glyphsLib/venv/bin/ufo2glyphs", line 11, in
load_entry_point('glyphsLib', 'console_scripts', 'ufo2glyphs')()
File "/Users/nikolaus/Entwicklung/glyphsLib/Lib/glyphsLib/cli.py", line 241, in _ufo2glyphs_entry_point
return main(args)
File "/Users/nikolaus/Entwicklung/glyphsLib/Lib/glyphsLib/cli.py", line 145, in main
return options.func(options)
File "/Users/nikolaus/Entwicklung/glyphsLib/Lib/glyphsLib/cli.py", line 197, in ufo2glyphs
designspace.read(designspace_file)
File "/Users/nikolaus/Entwicklung/glyphsLib/venv/lib/python3.7/site-packages/fontTools/designspaceLib/__init__.py", line 1031, in read
reader.read()
File "/Users/nikolaus/Entwicklung/glyphsLib/venv/lib/python3.7/site-packages/fontTools/designspaceLib/__init__.py", line 675, in read
self.readSources()
File "/Users/nikolaus/Entwicklung/glyphsLib/venv/lib/python3.7/site-packages/fontTools/designspaceLib/__init__.py", line 792, in readSources
sourceObject.location = self.locationFromElement(sourceElement)
File "/Users/nikolaus/Entwicklung/glyphsLib/venv/lib/python3.7/site-packages/fontTools/designspaceLib/__init__.py", line 824, in locationFromElement
elementLocation = self.readLocationElement(locationElement)
File "/Users/nikolaus/Entwicklung/glyphsLib/venv/lib/python3.7/site-packages/fontTools/designspaceLib/__init__.py", line 831, in readLocationElement
raise DesignSpaceDocumentError("No axes defined")
fontTools.designspaceLib.DesignSpaceDocumentError: No axes defined
```

Contributor guide

Open the contributing guide

Research direction

Reproduce the four-step round trip with the Ubuntu repository, then start in Lib/glyphsLib/cli.py and follow the designspace read path shown in the traceback into fontTools designspaceLib. Done means the single-UFO round trip no longer fails with “No axes defined” and produces the expected output.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.