-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Bug Description
Importing cachekit on Windows fails with:
AttributeError: module 'os' has no attribute 'uname'. Did you mean: 'name'?
Root Cause
src/cachekit/logging.py line 173 uses os.uname().nodename which doesn't exist on Windows:
self._hostname = os.uname().nodenameReproduction
# On Windows
pip install cachekit
python -c "from cachekit import cache"
# AttributeError: module 'os' has no attribute 'uname'Suggested Fix
Use platform-agnostic approach:
import platform
self._hostname = platform.node()Or with fallback:
try:
self._hostname = os.uname().nodename
except AttributeError:
self._hostname = platform.node()Environment
- cachekit version: 0.3.0
- Python: 3.13
- OS: Windows 11
Metadata
Metadata
Assignees
Labels
No labels