8000 KeyError in varLib.cff.merge_PrivateDicts · Issue #1632 · fonttools/fonttools · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

KeyError in varLib.cff.merge_PrivateDicts #1632

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
miguelsousa opened this issue Jun 3, 2019 · 4 comments
Closed

KeyError in varLib.cff.merge_PrivateDicts #1632

miguelsousa opened this issue Jun 3, 2019 · 4 comments
Assignees

Comments

@miguelsousa
Copy link
Collaborator

Getting the error below while trying to build the fonts at https://github.com/adobe-fonts/adobe-blank-vf

Test case attached. The command was,

fonttools varLib --master-finder fonts/{stem}.otf AdobeBlankVF.designspace
Traceback (most recent call last):
  File "fonttools", line 10, in <module>
    sys.exit(main())
  File "fontTools/__main__.py", line 29, in main
    runpy.run_module(mod, run_name='__main__')
  File "runpy.py", line 208, in run_module
    return _run_code(code, {}, init_globals, run_name, mod_spec)
  File "runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "fontTools/varLib/__main__.py", line 7, in <module>
    sys.exit(main())
  File "fontTools/varLib/__init__.py", line 1064, in main
    optimize=options.optimize
  File "fontTools/varLib/__init__.py", line 924, in build
    _add_CFF2(vf, model, master_fonts)
  File "fontTools/varLib/__init__.py", line 767, in _add_CFF2
    merge_region_fonts(varFont, model, ordered_fonts_list, glyphOrder)
  File "fontTools/varLib/cff.py", line 310, in merge_region_fonts
    merge_PrivateDicts(top_dicts, cvData.vsindex_dict, model, fd_map)
  File "fontTools/varLib/cff.py", line 183, in merge_PrivateDicts
    sub_model, model_keys = vsindex_dict[vsindex]
KeyError: 0

AdobeBlankVF.zip

@kenlunde
Copy link
kenlunde commented Jun 3, 2019

I am sure that it has something to do with its blank glyphs, as the corresponding black VFs build successfully.

@readroberts
Copy link
Collaborator

I can reproduce this. Am looking at it now.

@readroberts
Copy link
Collaborator

varLib.cff.py didn't support building a variation font where none of the glyphs have any variation. I have a fix for this, will submit after more testing.

@anthrotype
Copy link
Member

Fixed by #1642

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants
0