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
pyftsubset
gives missing glyphs exception when using single hyphens for CLI args
#2900
Comments
pyftsubset
gives missing glyphs exception when pyftsubset
gives missing glyphs exception when using single hyphens for CLI args
That's a bug in the docs. |
I don't know why the rendered docs come out that way. The sources are correct:
|
For some reason, some of the |
looks like options that has square brackets get treated as general text and use proportional font not monospaced one like the others. |
Yes, it feels like the square brackets are breaking a regex somewhere. Quickest fix, then, would be to make some simple edits to the docstring:
I squinted at the RST syntax for option lists but am still not sure if there is a more idiomatic method for showing optional values in RST. Another approach would be to disable “smart” processing for dashes altogether by setting the |
It's not just brackets, even ellipses and commas seem to break it, based on the documentation for option lists:
In the first form (which applies to the For the flag to display correctly, it could be re-written as |
The docs seem to indicate that some arguments (such as the
unicodes
argument, as well asglyphs
) should be given with one hyphen, and others with two hyphens.I spent a couple of days trying to figure out why I was getting exceptions for missing glyphs, such as below:
I finally stumbled on the fix, which was to use two hyphens for all arguments (so,
--glyphs
instead of-glyphs
), contra the docs.Can/should the documentation be updated to reflect this? I’ve been out of Python for a while, so I don’t know if there is some historical reason why some options were documented this way.
I’m using Python 3.10 under ZSH on Mac OS 12.6 (Monterey) on ARM64.
The text was updated successfully, but these errors were encountered: