mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-09-11 02:33:51 +08:00
mapd: bump version and fix missing folder (#994)
* fix mapd folder * not needed * unnecessary * Remove unused import from mapd_installer.py Deleted the unused import of Paths from openpilot.system.hardware.hw to clean up the code. * Undo changes * update: adjust `mapd` process to conditionally start based on readiness - Added `mapd_ready` function to check `mapd` readiness. - Modified `mapd` process to use this readiness condition. * update: bump mapd version to v1.10.0 and add readiness utility - Updated `VERSION` to v1.10.0 for `mapd_installer.py`. * update: integrate `MapdInstallManager` versioning into main thread - Added a call to `MapdInstallManager.update_installed_version` with `VERSION`. - Ensures version management for `mapd` is synchronized during runtime. * refactor: centralize `MAPD_PATH` and `MAPD_BIN_DIR` definitions in module init - Moved constants to `sunnypilot/mapd/__init__.py` for cleaner imports and reuse. - Updated references in `mapd_manager.py` and `mapd_installer.py`. * revert back the file permission * do this * no longer static --------- Co-authored-by: DevTekVE <devtekve@gmail.com> Co-authored-by: rav4kumar <meetkumardesai@gmail.com> Co-authored-by: James Vecellio-Grant <159560811+Discountchubbs@users.noreply.github.com> Co-authored-by: Jason Wen <haibin.wen3@gmail.com>
This commit is contained in:
@@ -88,6 +88,9 @@ def is_stock_model(started, params, CP: car.CarParams) -> bool:
|
||||
"""Check if the active model runner is stock."""
|
||||
return bool(get_active_model_runner(params, not started) == custom.ModelManagerSP.Runner.stock)
|
||||
|
||||
def mapd_ready(started: bool, params: Params, CP: car.CarParams) -> bool:
|
||||
return bool(os.path.exists(Paths.mapd_root()))
|
||||
|
||||
def or_(*fns):
|
||||
return lambda *args: operator.or_(*(fn(*args) for fn in fns))
|
||||
|
||||
@@ -162,7 +165,7 @@ procs += [
|
||||
PythonProcess("backup_manager", "sunnypilot.sunnylink.backups.manager", and_(only_offroad, sunnylink_ready_shim)),
|
||||
|
||||
# mapd
|
||||
NativeProcess("mapd", Paths.mapd_root(), [MAPD_PATH], always_run),
|
||||
NativeProcess("mapd", Paths.mapd_root(), [MAPD_PATH], mapd_ready),
|
||||
PythonProcess("mapd_manager", "sunnypilot.mapd.mapd_manager", always_run),
|
||||
]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user