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

Fix macOS ARM64(m1) GHA issues #1129

Closed
1 task done
kesara opened this issue Jun 17, 2024 · 0 comments · Fixed by #1141
Closed
1 task done

Fix macOS ARM64(m1) GHA issues #1129

kesara opened this issue Jun 17, 2024 · 0 comments · Fixed by #1141
Labels
bug Something isn't working

Comments

@kesara
Copy link
Member

kesara commented Jun 17, 2024

Describe the issue

macos-latest GitHub runners run on arm64 (m1) architecture.
These runners fail to run tests with errors:

Traceback (most recent call last):
  File "/Users/runner/work/xml2rfc/xml2rfc/test.py", line 8, in <module>
    import xml2rfc

  File "/Users/runner/work/xml2rfc/xml2rfc/xml2rfc/__init__.py", line 38, in <module>
-----

    from weasyprint.text.ffi import pango
WeasyPrint could not import some external libraries. Please carefully follow the installation steps before reporting an issue:
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
https://doc.courtbouillon.org/weasyprint/stable/first_steps.html#installation
  File "<frozen importlib._bootstrap>", line 1322, in _find_and_load_unlocked
https://doc.courtbouillon.org/weasyprint/stable/first_steps.html#troubleshooting 
  File "<frozen importlib._bootstrap>", line 1262, in _find_spec

  File "<frozen importlib._bootstrap_external>", line 1528, in find_spec
-----
  File "<frozen importlib._bootstrap_external>", line 1497, in _get_spec

  File "<frozen importlib._bootstrap_external>", line 1368, in __iter__

  File "<frozen importlib._bootstrap_external>", line 1355, in _recalculate
-----
  File "<frozen importlib._bootstrap_external>", line 1351, in _get_parent_path

KeyError: 'weasyprint'
WeasyPrint could not import some external libraries. Please carefully follow the installation steps before reporting an issue:
https://doc.courtbouillon.org/weasyprint/stable/first_steps.html#installation
https://doc.courtbouillon.org/weasyprint/stable/first_steps.html#troubleshooting 

See https://github.com/ietf-tools/xml2rfc/actions/runs/9511526289/job/26217825833?pr=1124

A quick fix for this is to restrict to macos-12 so the tests will run on intel architecture.

The issue seems to be GitHub-related since I can't reproduce these errors locally on macOS 14.5 with arm64 (m1).

Code of Conduct

@kesara kesara added the bug Something isn't working label Jun 17, 2024
kesara added a commit to kesara/xml2rfc that referenced this issue Jun 17, 2024
kesara added a commit to kesara/xml2rfc that referenced this issue Jun 17, 2024
kesara added a commit that referenced this issue Jun 26, 2024
* ci: Use xml2rfc-fonts for tests

* ci: Bump up setup-python action to v5

* ci: Bump up checout action to v4

* ci: Restrict macOS testing to intel processor

See #1129

* fix: Fix text extraction issues with updated fonts

* build: Use xml2rfc-fonts in docker image

* fix: Use xml2rfc-fonts xml2rfc compatible version

* docs: Update documentation to use xml2rfc-fonts

* docs: Update font install instructions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant