Skip to content

Apple M1 support #17

@hiatsu0

Description

@hiatsu0

A little unsure if this is really ialauncher's fault or something else related to the fact that Homebrew appears to have installed a bit newer version 3.9 of python3 under its folder in /opt/homebrew.

Previously I had ialauncher at ~/Library/Python/3.8/bin/ialauncher but after Homebrew installation as I tried to update it using pip3 install --upgrade ialauncher it went under /opt instead, and no longer starts due to some pygame/font.py issue below.

Maybe also worth noting, previously (due to issues getting Apple Silicon version of pygame) I used ialauncher via Rosetta x86 emulation and the previous version still runs just fine using Rosetta from `~/Library/Python/3.8/bin/ialauncher' but I'm no longer able to update/remove it using pip3. Now trying to run native Apple Silicon version of everything.

user@macbookair ~ % brew config
HOMEBREW_VERSION: 3.0.0
ORIGIN: https://github.com/Homebrew/brew
HEAD: ebc7cc36a0e029d58fac8cebd1b5ff583b3fd95b
Last commit: 9 hours ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 149d62524beea0231087f189a242fddc325adb3b
Core tap last commit: 42 minutes ago
Core tap branch: master
HOMEBREW_PREFIX: /opt/homebrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 8
Homebrew Ruby: 2.6.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby
CPU: octa-core 64-bit arm_firestorm_icestorm
Clang: 12.0 build 1200
Git: 2.24.3 => /Library/Developer/CommandLineTools/usr/bin/git
Curl: 7.64.1 => /usr/bin/curl
macOS: 11.2-arm64
CLT: 12.4.0.0.1.1610135815
Xcode: N/A
Rosetta 2: false

user@macbookair ~ % which pip3
/opt/homebrew/bin/pip3
user@macbookair ~ % which pip 
/usr/local/bin/pip

user@macbookair ~ % pip3 install ialauncher
Collecting ialauncher
  Using cached ialauncher-2.2.1-py3-none-any.whl
Collecting pygame
  Using cached pygame-2.0.1-cp39-cp39-macosx_11_0_arm64.whl
Installing collected packages: pygame, ialauncher
Successfully installed ialauncher-2.2.1 pygame-2.0.1
user@macbookair ~ % which ialauncher
/opt/homebrew/bin/ialauncher
user@macbookair ~ % which dosbox
/opt/homebrew/bin/dosbox

user@macbookair ~ % ialauncher
pygame 2.0.1 (SDL 2.0.14, Python 3.9.1)
Hello from the pygame community. https://www.pygame.org/contribute.html
/opt/homebrew/lib/python3.9/site-packages/ialauncher/engine.py:96: RuntimeWarning: use font: cannot import name 'Font' from partially initialized module 'pygame.font' (most likely due to a circular import) (/opt/homebrew/lib/python3.9/site-packages/pygame/font.py)
(ImportError: cannot import name 'Font' from partially initialized module 'pygame.font' (most likely due to a circular import) (/opt/homebrew/lib/python3.9/site-packages/pygame/font.py))
  self.font = pg.font.SysFont(font_family, font_size)
Traceback (most recent call last):
  File "/opt/homebrew/bin/ialauncher", line 8, in <module>
    sys.exit(main())
  File "/opt/homebrew/lib/python3.9/site-packages/ialauncher/__main__.py", line 20, in main
    Main(Loading(slurp_mode=args.slurp_mode), title='IA Launcher', fullscreen=options.fullscreen)
  File "/opt/homebrew/lib/python3.9/site-packages/ialauncher/engine.py", line 48, in __init__
    scene = scene.run(screen)
  File "/opt/homebrew/lib/python3.9/site-packages/ialauncher/engine.py", line 80, in run
    next_scene = self.update(screen)
  File "/opt/homebrew/lib/python3.9/site-packages/ialauncher/scenes.py", line 58, in update
    self.draw(screen, f'''
  File "/opt/homebrew/lib/python3.9/site-packages/ialauncher/engine.py", line 96, in draw
    self.font = pg.font.SysFont(font_family, font_size)
  File "/opt/homebrew/lib/python3.9/site-packages/pygame/__init__.py", line 59, in __getattr__
    raise NotImplementedError(missing_msg)
NotImplementedError: font module not available (ImportError: cannot import name 'Font' from partially initialized module 'pygame.font' (most likely due to a circular import) (/opt/homebrew/lib/python3.9/site-packages/pygame/font.py))
user@macbookair ~ %

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions