FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Fix host memory detection on macOS by BrendanStork · Pull Request #71 · Algorithmiq/src-method · GitHub

Repository navigation

Fix host memory detection on macOS - #71

Open
BrendanStork wants to merge 1 commit into
Algorithmiq:mainfrom
BrendanStork:fix-macos-memory
Open

BrendanStork wants to merge 1 commit into
Algorithmiq:mainfrom
BrendanStork:fix-macos-memory

Conversation

Copy link
Copy Markdown

Summary

Fixes a macOS compatibility issue in host_memory_available(), where os.sysconf("SC_AVPHYS_PAGES") raises ValueError.

The change introduces a fallback to psutil.virtual_memory().available when the system call is unsupported, and adds psutil as a runtime dependency.

The existing Linux memory-detection logic is preserved.

Testing

  • python -m pytest tests/test_backend.py -v — 11 tests passed.
  • CPU MPO–MPO benchmark — completed successfully on macOS.

Fixes #70

This branch has not been deployed

No deployments
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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

Successfully merging this pull request may close these issues.

host_memory_available() raises ValueError on macOS

1 participant


Back | FazBrowse Home | New Git URL