Optimize: Reduce dependencies to minimal set for headless RFID client
REMOVED: - aiohttp, multidict, aiosignal, frozenlist, attrs, yarl, propcache (Flask async dependencies) - flask, chart (not needed for headless device) - selenium (web automation not needed) KEPT (7 core dependencies only): - rdm6300: RFID reader library - requests: HTTP communication to server - gpiozero: GPIO/system access - urllib3, certifi, charset_normalizer, idna: requests dependencies IMPROVEMENTS: - Skip trying to install wrong-architecture wheels (aarch64) - Let pip download correct ARM32/ARM64 version for device - Much faster startup on resource-constrained Raspberry Pi - Pure Python wheels installed from local repository - Removes 11+ unnecessary packages
This commit is contained in:
@@ -128,24 +128,16 @@ CONFIG_CARD_ID = 12886709 # Card used for configuration
|
||||
# DEPENDENCIES
|
||||
# ============================================================================
|
||||
|
||||
# Required Python packages and their wheel files
|
||||
# Required Python packages - MINIMAL for headless RFID client
|
||||
# Flask and aiohttp dependencies removed since we're now a headless collector
|
||||
REQUIRED_PACKAGES = {
|
||||
'rdm6300': 'rdm6300-0.1.1-py3-none-any.whl',
|
||||
'gpiozero': None, # System package
|
||||
'requests': 'requests-2.32.3-py3-none-any.whl',
|
||||
'aiohttp': 'aiohttp-3.11.18-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl',
|
||||
'flask': None, # Will try pip install if needed
|
||||
'urllib3': 'urllib3-2.3.0-py3-none-any.whl',
|
||||
'certifi': 'certifi-2025.1.31-py3-none-any.whl',
|
||||
'charset_normalizer': 'charset_normalizer-3.4.1-py3-none-any.whl',
|
||||
'idna': 'idna-3.10-py3-none-any.whl',
|
||||
'multidict': 'multidict-6.4.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl',
|
||||
'aiosignal': 'aiosignal-1.3.2-py2.py3-none-any.whl',
|
||||
'frozenlist': 'frozenlist-1.6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl',
|
||||
'attrs': 'attrs-25.3.0-py3-none-any.whl',
|
||||
'yarl': 'yarl-1.20.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl',
|
||||
'aiohappyeyeballs': 'aiohappyeyeballs-2.6.1-py3-none-any.whl',
|
||||
'propcache': 'propcache-0.3.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl'
|
||||
'rdm6300': 'rdm6300-0.1.1-py3-none-any.whl', # RFID reader library
|
||||
'requests': 'requests-2.32.3-py3-none-any.whl', # HTTP requests to server
|
||||
'gpiozero': None, # GPIO/system interaction (apt package)
|
||||
'urllib3': 'urllib3-2.3.0-py3-none-any.whl', # Requests dependency
|
||||
'certifi': 'certifi-2025.1.31-py3-none-any.whl', # SSL certificates
|
||||
'charset_normalizer': 'charset_normalizer-3.4.1-py3-none-any.whl', # Requests dependency
|
||||
'idna': 'idna-3.10-py3-none-any.whl' # Requests dependency
|
||||
}
|
||||
|
||||
REPOSITORY_PATH = FILES_DIR / "reposytory"
|
||||
|
||||
Reference in New Issue
Block a user