UNSOLVED UFO not saving all changes



  • I've been having an issue where after saving the UFO only some of the changes are kept. Occasionally I've been able to salvage the changes glyphs from auto saved files but it's really frustrating and hard to keep track of. I'm on 3.2b.



  • Hi everyone,

    I recently turned off autosave and ran into the same problem. Here's the output window:

    ********************
    Could not save glyph 'n' in layer 'foreground'
    Traceback (most recent call last):
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 268, in getGLIF
    FileNotFoundError: [Errno 2] No such file or directory: '/var/folders/ww/8szzh9td0w95r2pm89_516_h0000gn/T/tmpsttvw8ln/temp.ufo/glyphs/n.glif'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "lib/fontObjects/doodleLayer.pyc", line 238, in saveGlyph
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/defcon/objects/layer.py", line 578, in saveGlyph
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/defcon/objects/layer.py", line 592, in _stampGlyphDataState
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 282, in getGLIFModificationTime
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 272, in getGLIF
    KeyError: 'n'
    
    Could not save glyph 'u' in layer 'foreground'
    Traceback (most recent call last):
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 268, in getGLIF
    FileNotFoundError: [Errno 2] No such file or directory: '/var/folders/ww/8szzh9td0w95r2pm89_516_h0000gn/T/tmpsttvw8ln/temp.ufo/glyphs/u.glif'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "lib/fontObjects/doodleLayer.pyc", line 238, in saveGlyph
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/defcon/objects/layer.py", line 578, in saveGlyph
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/defcon/objects/layer.py", line 592, in _stampGlyphDataState
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 282, in getGLIFModificationTime
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 272, in getGLIF
    KeyError: 'u'
    

    Before opening this file I turned off autosave after reading @FosterType 's reply.

    Here are the steps I made in creating this error:

    1. Opened the file, it was a UFO 2 and was converted to UFO 3
    2. Moved a few points and handles. I did NOT create new points, segments, or contours. I did NOT make any new glyphs.
    3. The 'u' is a component of the 'n' which I assume is why it is producing the error on both glyphs.

    I noticed that in the RoboFont preferences my Autosave path was configured like this:

    user/Library/Autosave Information
    

    A classmate of mine who has not reported any issues like this had his AutoSave path configured in this way (he didn't remember doing this himself or if it carried through from an old Robofont install).

    user/Library/Application Support/Robofont/Autosave
    

    It's worth noting, this problem occurred AFTER I turned off Autosave, BUT I had not shut down and restarted Robofont yet.

    I did the following and the error did NOT reproduce:

    1. selected all points and segments and contours
    2. deleted the glyph from Font menu
    3. pasted the glyph data back in place

    I shut down RoboFont and restarted it. Opened the file again and moved through the existing glyphs moving the points and saving and I have not been able to reproduce the error.

    This could be because the Autosave preference has been updated.

    Hope all this helps!



  • hey all, just a bit of a heads up. Since turning OFF auto-saving, this problem has stopped for me.

    D



  • hi @sheehansista, sorry to hear about the problem. did you notice any error message in the Output Window or in the log file?

    if you have auto-save turned on in the Preferences, you might be able to recover the lost changes from the backup file. good luck!



  • I've been experiencing the same issue. In a typeface I had already worked on, some changes were reverted. In a new typeface, the 'a' and 'b' characters were deleted completely, even though I created them first. My latest changes to other letters were saved, though. It's a little bit scary.



  • One other thing that might be worth investigating is whether toggling auto saving in preferences reduces the amount it happens (I think it has for me)



  • I don't know if this is the same issue or even related but I thought I'd post it in case. I don't get anything like this when I commonly try to save a file and the changes don't get saved, but I noticed this when opening an old file recently. My output window was full of these errors:

    Could not save glyph 'nacute.pl' in layer 'background'
    Traceback (most recent call last):
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 268, in getGLIF
    FileNotFoundError: [Errno 2] No such file or directory: '/var/folders/c0/7gbjzbk144z__1c_9qk0xx340000gn/T/tmp1n8i660s/temp.ufo/glyphs.background/nacute.pl.glif'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "lib/fontObjects/doodleLayer.pyc", line 238, in saveGlyph
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/defcon/objects/layer.py", line 578, in saveGlyph
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/defcon/objects/layer.py", line 592, in _stampGlyphDataState
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 282, in getGLIFModificationTime
      File "/Applications/RoboFont.app/Contents/Resources/lib/python3.6/ufoLib/glifLib.py", line 272, in getGLIF
    KeyError: 'nacute.pl'
    


  • @gferreira Thanks for looking into it. And yes, it's hard to reproduce as there seems to be few patterns and can happen with any font.



  • hello Dave,

    this issue has been reported by other users, I know @frederik has been looking into it. but it’s hard to reproduce.

    does it happen always, with all fonts? or is it a problem with one font only?

    thanks!