Expected glyph or class name (unhelpful error)

How can I find the feature code that’s causing this error? It just says the errors are in line 15 and 39, but not which feature these lines are in. I looked through all my features that have 39+ lines of code, but could not find any potential errors.

If I click “Show” next to the error, it just opens the Font Info > Features tab, but does not take me to the location of the error.

This is 3.1.2, by the way.

The problem is in the automatically generated kern or mark feature code. Probably a glyph name, kerning group or anchor name with illegal characters. You can check the full feature code in the temp folder.

Can you try the latest cutting edge version. We added more validation and improved the error messages. Maybe this is fixed already. If not, could you send me the .glyphs file?

It must be fixed, because it exports successfully with no errors in 3.2. I still need to be able to export with 3.1.2 for proofing while I’m working, so I’ll check my kerning groups – I was scripting some changes to them so maybe there’s an illegal character somewhere.

Update: why is dnk an illegal name for kerning groups?!

Lines 15 and 39 from features.fea in the Temp folder:

15  @MMK_L_dnk = [ordfeminine mu zero.tf one.tf …
39  @MMK_R_dnk = [ordfeminine mu zero.tf one.tf …

EDIT: Solved! The dnk name was not the problem. The problem was the NULL glyph is in this group. I found this thread where Tim mentioned a similar problem. My script was using dnk for everything that doesn’t need to be kerned, including things like zero-width and control characters.

The line numbers are relative to actual feature block, not the whole fea file.

1 Like

Since you mentioned you’re working on improving the error messages, here is another one that could be improved. This is on the latest cutting edge build 3246.

The message is fine, and I was able to find the problem (“Update Features” CP was enabled and 3.2 no longer generates the @CombiningNonTopAccents class for some reason). But nothing happens when I click the “Show” button. I would expect it to open Font Info > Features and take me to the exact feature that raised the error.