Files
hermes-agent/hermes_cli/psutil_android.py
ethernet 529050eab7 fix(update): stop retired installers and finish on fresh launch
Old updaters keep running after the checkout changes. Returning None
from their removed uv helpers enables a pip fallback against the new tree.
Keep the historical imports as inert shims and stop dependency entrypoints
with a relaunch message instead. Do not call PM or write recovery markers
from that mixed-version process.

Self-managed source launches use PM's successful input stamp to decide
when dependencies need a sync. Restart on the managed interpreter before
activating the selected generation. Preserve launcher forms and options,
and do not sync while a live updater owns the installation.

Targeted runtime batch: 225 passed, 8 platform skips. Real PM worker tests
build and publish disposable dependency generations, retain prior state on
failure, and exercise fresh-process relaunch before dependency activation.
The final launch guard test also passes. Full suite and native Windows
execution were not run locally.
2026-09-11 19:46:35 -04:00

25 lines
866 B
Python

"""Shims to stop the old updater doing work until relaunch, not Android support."""
from pathlib import Path
from typing import NoReturn
from hermes_cli._old_updater import stop_for_relaunch
# Frozen data for old imports, not a download performed by this module.
PSUTIL_URL = (
"https://files.pythonhosted.org/packages/aa/c6/"
"d1ddf4abb55e93cebc4f2ed8b5d6dbad109ecb8d63748dd2b20ab5e57ebe/"
"psutil-7.2.2.tar.gz"
)
def prepare_patched_psutil_sdist(archive: Path, destination: Path) -> NoReturn:
# Shim to stop the old updater doing work until relaunch. Extract nothing.
stop_for_relaunch()
# Shim to stop the old updater doing work until relaunch. Historical callers
# download PSUTIL_URL BEFORE calling prepare_patched_psutil_sdist, so waiting
# for that call is too late. Stop the import without offering a fake URL.
stop_for_relaunch()