Skip to content

Commit

Permalink
Merge branch 'main' into mac_style-none
Browse files Browse the repository at this point in the history
  • Loading branch information
khaledhosny authored Mar 4, 2024
2 parents e4e1981 + 0f619e7 commit bc06425
Show file tree
Hide file tree
Showing 30 changed files with 863 additions and 1,112 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/install_run.yml
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,9 @@ jobs:
|| exit 0
shell: bash

- name: Install `ufo-sources` extra
- name: Install `ufo_sources` extra
run: |
python -m pip install '.[ufo-sources]'
python -m pip install '.[ufo_sources]'
- name: Run UFO Sources checks
run: >-
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/lint_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -r requirements-tests.txt -r requirements-docs.txt
# For pytype we need everything
python -m pip install .[tests,docs]
python -m pip install glyphsLib
python -m pip install pytype # Not in requirements as it doesn't work on Windows
- name: Run black, pylint and pytype
Expand Down Expand Up @@ -70,7 +72,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt -r requirements-tests.txt -r requirements-docs.txt
python -m pip install .[tests,docs]
python -m pip freeze --all
- name: Install FontBakery
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,12 @@ A more detailed list of changes is available in the corresponding milestones for
- v0.12.0a2 (2024-Feb-21)

### Changes to existing checks
#### On the Universal profile
- **DISABLED - [com.google.fonts/check/legacy_accents]:** This is one of the checks that we probably should run on the sources instead of binaries. (https://github.com/fonttools/fontbakery/issues/3959#issuecomment-1822913547)

#### On the Open Type Profile
- **[com.google.fonts/check/layout_valid_feature_tags]:** Updated the check to allow valid private-use feature tags. (issue #4544)
- **[com.google.fonts/check/varfont/family_axis_ranges]:** Updated the check to skip fonts without fvar tables. (issue #4554)
- **[com.google.fonts/check/mac_style]:** Skip if font style can not be determined. (issue #4349)


Expand Down
8 changes: 4 additions & 4 deletions Lib/fontbakery/checkrunner.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,15 +113,15 @@ def get_iterarg(self, name, index):

def _get(self, name, iterargs, condition=False):
# Is this a property of the whole collection?
if hasattr(self.context, name):
if name in dir(self.context):
return getattr(self.context, name)
# Is it a property of the file we're testing?
for thing, index in iterargs:
specific_thing = self.context.testables_by_type[thing][index]
# Allow "font" to return the Font object itself
if name == thing:
return specific_thing
if not hasattr(specific_thing, name):
if name not in dir(specific_thing):
continue
return getattr(specific_thing, name)
if condition:
Expand Down Expand Up @@ -243,7 +243,7 @@ def order(self) -> Tuple[Identity, ...]:
):
continue
args = set(check.args)
context_args = set(arg for arg in args if hasattr(self.context, arg))
context_args = set(arg for arg in args if arg in dir(self.context))

# Either this is a check which runs on the whole collection
# (i.e. all of its arguments can be called as methods on the
Expand All @@ -257,7 +257,7 @@ def order(self) -> Tuple[Identity, ...]:
individual_args = args - context_args
if (
all(
hasattr(file, arg)
arg in dir(file)
for arg in individual_args
for file in files
)
Expand Down
1 change: 1 addition & 0 deletions Lib/fontbakery/checks/opentype/fvar.py
Original file line number Diff line number Diff line change
Expand Up @@ -673,6 +673,7 @@ def com_adobe_fonts_check_varfont_foundry_defined_tag_name(ttFont):
""",
proposal="https://github.com/fonttools/fontbakery/issues/4445",
experimental="Since 2024/Jan/30",
conditions=["VFs"],
)
def com_google_fonts_check_varfont_family_axis_ranges(ttFonts):
"""Check that family axis ranges are indentical"""
Expand Down
1 change: 1 addition & 0 deletions Lib/fontbakery/checks/universal/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -741,6 +741,7 @@ def com_google_fonts_check_whitespace_ink(ttFont):
yield PASS, "There is no whitespace glyph with ink."


@disable # https://github.com/fonttools/fontbakery/issues/3959#issuecomment-1822913547
@check(
id="com.google.fonts/check/legacy_accents",
proposal=[
Expand Down
Loading

0 comments on commit bc06425

Please sign in to comment.