Skip to content
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

Deprecate all pyfontaine tests #1537

Closed
m4rc1e opened this issue Aug 22, 2017 · 3 comments
Closed

Deprecate all pyfontaine tests #1537

m4rc1e opened this issue Aug 22, 2017 · 3 comments

Comments

@m4rc1e
Copy link
Collaborator

m4rc1e commented Aug 22, 2017

In check-ttf we had the --no-coverage flag to disable pyfontaine, #1345. This came about because the implementation was was too slow.

I don't want to disable pyfontaine, I just want cleaner output.

The current output is very bad for QAing families containing many styles.

>> com.google.fonts/test/132 with ((u'font[0]', '/Users/marc/Documents/googlefonts/fonts/ofl/somesans/SomeSans-Bold.ttf'),)
   Checking Cyrillic Historical glyph coverage.
 * FAIL: Pyfontaine output follows:

Fonts
  Font:
    Filename: SomeFont-Bold.ttf
    Common name: Some Font
    Sub family: Bold
    Weight: bold
    Fixed width: yes
    Fixed sizes: yes
    Copyright: Copyright 2017 Google Inc. All Rights Reserved.
    Version: Version 1.101
    Glyph count: 785
    Character count: 732
    Orthographies:
        Orthography:
          Glyphs in set: 446
          Glyphs in font: 407
          Percent coverage: 91
          Missing values: 
              U+0460  Ѡ  CYRILLIC CAPITAL LETTER OMEGA
              U+0461  ѡ  CYRILLIC SMALL LETTER OMEGA
              U+0464  Ѥ  CYRILLIC CAPITAL LETTER IOTIFIED E
              U+0465  ѥ  CYRILLIC SMALL LETTER IOTIFIED E
              U+0466  Ѧ  CYRILLIC CAPITAL LETTER LITTLE YUS
              U+0467  ѧ  CYRILLIC SMALL LETTER LITTLE YUS
              U+0468  Ѩ  CYRILLIC CAPITAL LETTER IOTIFIED LITTLE YUS
              U+0469  ѩ  CYRILLIC SMALL LETTER IOTIFIED LITTLE YUS
              U+046c  Ѭ  CYRILLIC CAPITAL LETTER IOTIFIED BIG YUS
              U+046d  ѭ  CYRILLIC SMALL LETTER IOTIFIED BIG YUS
              U+046e  Ѯ  CYRILLIC CAPITAL LETTER KSI
              U+046f  ѯ  CYRILLIC SMALL LETTER KSI
              U+0470  Ѱ  CYRILLIC CAPITAL LETTER PSI
              U+0471  ѱ  CYRILLIC SMALL LETTER PSI
              U+0476  Ѷ  CYRILLIC CAPITAL LETTER IZHITSA WITH DOUBLE GRAVE ACCENT
              U+0477  ѷ  CYRILLIC SMALL LETTER IZHITSA WITH DOUBLE GRAVE ACCENT
              U+0478  Ѹ  CYRILLIC CAPITAL LETTER UK
              U+0479  ѹ  CYRILLIC SMALL LETTER UK
              U+047a  Ѻ  CYRILLIC CAPITAL LETTER ROUND OMEGA
              U+047b  ѻ  CYRILLIC SMALL LETTER ROUND OMEGA
              U+047c  Ѽ  CYRILLIC CAPITAL LETTER OMEGA WITH TITLO
              U+047d  ѽ  CYRILLIC SMALL LETTER OMEGA WITH TITLO
              U+047e  Ѿ  CYRILLIC CAPITAL LETTER OT
              U+047f  ѿ  CYRILLIC SMALL LETTER OT
              U+0480  Ҁ  CYRILLIC CAPITAL LETTER KOPPA
              U+0481  ҁ  CYRILLIC SMALL LETTER KOPPA
              U+0482  ҂  CYRILLIC THOUSANDS SIGN
              U+0483  ҃  COMBINING CYRILLIC TITLO
              U+0484  ҄  COMBINING CYRILLIC PALATALIZATION
              U+0485  ҅  COMBINING CYRILLIC DASIA PNEUMATA
              U+0486  ҆  COMBINING CYRILLIC PSILI PNEUMATA
              U+0487  ҇  COMBINING CYRILLIC POKRYTIE
              U+0488  ҈  COMBINING CYRILLIC HUNDRED THOUSANDS SIGN
              U+0489  ҉  COMBINING CYRILLIC MILLIONS SIGN
              U+a64c  Ꙍ  CYRILLIC CAPITAL LETTER BROAD OMEGA
              U+a64d  ꙍ  CYRILLIC SMALL LETTER BROAD OMEGA
              U+e0ff  
              U+f000  
              U+effd  
          Common name: Google Fonts: Cyrillic Historical
          Support level: partial

   Result: FAIL

The check is run several times on each font for different codepages. If I save a log, pyfontaine error messages make up over 80%. It makes FB almost impossible to use.

@graphicore
Copy link
Collaborator

I had an idea recently to make this generally better:

  1. We should know which encodings are expected to be in a font. Can we use METADATA.pb subsets for this?
  2. if an encoding is expected and pyfontaine passes it's a PASS
  3. if an encoding is expected and pyfontaine fails it's a FAIL and the default error message is quite helpful.
  4. if an encoding is not expected and pyfontaine fails, we make it a PASS
  5. if an encoding is not expected and pyfontaine passes, we make it a FAIL. This requires to register the missing subset. Could be a WARN as well.

@graphicore
Copy link
Collaborator

To worst thing about the pyfontaine checks is that most of them fail by default. The above would regulate that. Also, once a font is released we should know which encodings are supported. The above adds a nice regression detection.

@davelab6
Copy link
Contributor

davelab6 commented Aug 22, 2017

I don't want to disable pyfontaine, I just want cleaner output.

I think we should turn pyfontaine off completely for now, it is a standalone tool and plugging into it quickly was just a stop gap.

The real need for now is to implement #1466

@davelab6 davelab6 modified the milestones: 0.3.2 - Further improvements on reliability of checks and fixers, 0.5.0 Code Is Well Organized Aug 22, 2017
@felipesanches felipesanches changed the title Better output for pyfontaine Deprecate all pyfontaine tests Aug 22, 2017
felipesanches added a commit to felipesanches/fontbakery that referenced this issue Aug 22, 2017
felipesanches added a commit to felipesanches/fontbakery that referenced this issue Aug 22, 2017
and remove all pyfontaine and pyicu from dependencies and documentation.
(issue fonttools#1537)
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