Decouple non-UI CLI startup from config_ui

Stop aman.py from importing the GTK settings module at module load so version, init, bench, diagnostics, and top-level help can start without pulling in the UI stack.\n\nPromote PyGObject and python-xlib into main project dependencies, switch the documented source install surface to plain uv/pip commands, and teach the portable, deb, and Arch packaging flows to install filtered runtime requirements before the Aman wheel so they still rely on distro-provided GTK/X11 packages.\n\nAdd regression coverage for importing aman with config_ui blocked and for the portable bundle's new requirements payload, then rerun the focused CLI/diagnostics/portable tests plus py_compile.
This commit is contained in:
Thales Maciel 2026-03-14 13:38:15 -03:00
parent b4a3d446fa
commit 721248ca26
No known key found for this signature in database
GPG key ID: 33112E6833C34679
15 changed files with 173 additions and 35 deletions

View file

@ -16,7 +16,7 @@ jobs:
run: | run: |
python -m pip install --upgrade pip python -m pip install --upgrade pip
python -m pip install uv build python -m pip install uv build
uv sync --extra x11 uv sync
- name: Prepare release candidate artifacts - name: Prepare release candidate artifacts
run: make release-prep run: make release-prep
- name: Upload packaging artifacts - name: Upload packaging artifacts

View file

@ -11,7 +11,7 @@
## Build, Test, and Development Commands ## Build, Test, and Development Commands
- Install deps (X11): `uv sync --extra x11`. - Install deps (X11): `uv sync`.
- Install deps (Wayland scaffold): `uv sync --extra wayland`. - Install deps (Wayland scaffold): `uv sync --extra wayland`.
- Run daemon: `uv run python3 src/aman.py --config ~/.config/aman/config.json`. - Run daemon: `uv run python3 src/aman.py --config ~/.config/aman/config.json`.

View file

@ -83,7 +83,7 @@ release-prep:
./scripts/prepare_release.sh ./scripts/prepare_release.sh
install-local: install-local:
$(PYTHON) -m pip install --user ".[x11]" $(PYTHON) -m pip install --user .
install-service: install-service:
mkdir -p $(HOME)/.config/systemd/user mkdir -p $(HOME)/.config/systemd/user

View file

@ -33,7 +33,7 @@ For `1.0.0`, the manual publication target is the forge release page at
`uv` workflow: `uv` workflow:
```bash ```bash
uv sync --extra x11 uv sync
uv run aman run --config ~/.config/aman/config.json uv run aman run --config ~/.config/aman/config.json
``` ```

View file

@ -14,6 +14,25 @@ sha256sums=('__TARBALL_SHA256__')
prepare() { prepare() {
cd "${srcdir}/aman-${pkgver}" cd "${srcdir}/aman-${pkgver}"
python -m build --wheel python -m build --wheel
python - <<'PY'
from pathlib import Path
import re
import tomllib
project = tomllib.loads(Path("pyproject.toml").read_text(encoding="utf-8"))
exclude = {"pygobject", "python-xlib"}
dependencies = project.get("project", {}).get("dependencies", [])
filtered = []
for dependency in dependencies:
match = re.match(r"\s*([A-Za-z0-9_.-]+)", dependency)
if not match:
continue
name = match.group(1).lower().replace("_", "-")
if name in exclude:
continue
filtered.append(dependency.strip())
Path("dist/runtime-requirements.txt").write_text("\n".join(filtered) + "\n", encoding="utf-8")
PY
} }
package() { package() {
@ -21,7 +40,8 @@ package() {
install -dm755 "${pkgdir}/opt/aman" install -dm755 "${pkgdir}/opt/aman"
python -m venv --system-site-packages "${pkgdir}/opt/aman/venv" python -m venv --system-site-packages "${pkgdir}/opt/aman/venv"
"${pkgdir}/opt/aman/venv/bin/python" -m pip install --upgrade pip "${pkgdir}/opt/aman/venv/bin/python" -m pip install --upgrade pip
"${pkgdir}/opt/aman/venv/bin/python" -m pip install "dist/aman-${pkgver}-"*.whl "${pkgdir}/opt/aman/venv/bin/python" -m pip install --requirement "dist/runtime-requirements.txt"
"${pkgdir}/opt/aman/venv/bin/python" -m pip install --no-deps "dist/aman-${pkgver}-"*.whl
install -Dm755 /dev/stdin "${pkgdir}/usr/bin/aman" <<'EOF' install -Dm755 /dev/stdin "${pkgdir}/usr/bin/aman" <<'EOF'
#!/usr/bin/env bash #!/usr/bin/env bash

View file

@ -358,6 +358,10 @@ def _copy_bundle_support_files(bundle_dir: Path, stage_dir: Path) -> None:
def _run_pip_install(bundle_dir: Path, stage_dir: Path, python_tag: str) -> None: def _run_pip_install(bundle_dir: Path, stage_dir: Path, python_tag: str) -> None:
common_dir = _require_bundle_file(bundle_dir / "wheelhouse" / "common", "common wheelhouse") common_dir = _require_bundle_file(bundle_dir / "wheelhouse" / "common", "common wheelhouse")
version_dir = _require_bundle_file(bundle_dir / "wheelhouse" / python_tag, f"{python_tag} wheelhouse") version_dir = _require_bundle_file(bundle_dir / "wheelhouse" / python_tag, f"{python_tag} wheelhouse")
requirements_path = _require_bundle_file(
bundle_dir / "requirements" / f"{python_tag}.txt",
f"{python_tag} runtime requirements",
)
aman_wheel = _aman_wheel(common_dir) aman_wheel = _aman_wheel(common_dir)
venv_dir = stage_dir / "venv" venv_dir = stage_dir / "venv"
_run([sys.executable, "-m", "venv", "--system-site-packages", str(venv_dir)]) _run([sys.executable, "-m", "venv", "--system-site-packages", str(venv_dir)])
@ -372,6 +376,22 @@ def _run_pip_install(bundle_dir: Path, stage_dir: Path, python_tag: str) -> None
str(common_dir), str(common_dir),
"--find-links", "--find-links",
str(version_dir), str(version_dir),
"--requirement",
str(requirements_path),
]
)
_run(
[
str(venv_dir / "bin" / "python"),
"-m",
"pip",
"install",
"--no-index",
"--find-links",
str(common_dir),
"--find-links",
str(version_dir),
"--no-deps",
str(aman_wheel), str(aman_wheel),
] ]
) )

View file

@ -29,6 +29,8 @@ dependencies = [
"llama-cpp-python", "llama-cpp-python",
"numpy", "numpy",
"pillow", "pillow",
"PyGObject",
"python-xlib",
"sounddevice", "sounddevice",
] ]
@ -36,10 +38,6 @@ dependencies = [
aman = "aman:main" aman = "aman:main"
[project.optional-dependencies] [project.optional-dependencies]
x11 = [
"PyGObject",
"python-xlib",
]
wayland = [] wayland = []
[project.urls] [project.urls]

View file

@ -84,3 +84,30 @@ render_template() {
sed -i "s|__${key}__|${value}|g" "${output_path}" sed -i "s|__${key}__|${value}|g" "${output_path}"
done done
} }
write_runtime_requirements() {
local output_path="$1"
require_command python3
python3 - "${output_path}" <<'PY'
from pathlib import Path
import re
import sys
import tomllib
output_path = Path(sys.argv[1])
exclude = {"pygobject", "python-xlib"}
project = tomllib.loads(Path("pyproject.toml").read_text(encoding="utf-8"))
dependencies = project.get("project", {}).get("dependencies", [])
filtered = []
for dependency in dependencies:
match = re.match(r"\s*([A-Za-z0-9_.-]+)", dependency)
if not match:
continue
name = match.group(1).lower().replace("_", "-")
if name in exclude:
continue
filtered.append(dependency.strip())
output_path.parent.mkdir(parents=True, exist_ok=True)
output_path.write_text("\n".join(filtered) + "\n", encoding="utf-8")
PY
}

View file

@ -21,6 +21,8 @@ fi
build_wheel build_wheel
WHEEL_PATH="$(latest_wheel_path)" WHEEL_PATH="$(latest_wheel_path)"
RUNTIME_REQUIREMENTS="${BUILD_DIR}/deb/runtime-requirements.txt"
write_runtime_requirements "${RUNTIME_REQUIREMENTS}"
STAGE_DIR="${BUILD_DIR}/deb/${PACKAGE_NAME}_${VERSION}_${ARCH}" STAGE_DIR="${BUILD_DIR}/deb/${PACKAGE_NAME}_${VERSION}_${ARCH}"
PACKAGE_BASENAME="${PACKAGE_NAME}_${VERSION}_${ARCH}" PACKAGE_BASENAME="${PACKAGE_NAME}_${VERSION}_${ARCH}"
@ -48,7 +50,8 @@ cp "${ROOT_DIR}/packaging/deb/postinst" "${STAGE_DIR}/DEBIAN/postinst"
chmod 0755 "${STAGE_DIR}/DEBIAN/postinst" chmod 0755 "${STAGE_DIR}/DEBIAN/postinst"
python3 -m venv --system-site-packages "${VENV_DIR}" python3 -m venv --system-site-packages "${VENV_DIR}"
"${VENV_DIR}/bin/python" -m pip install "${PIP_ARGS[@]}" "${WHEEL_PATH}" "${VENV_DIR}/bin/python" -m pip install "${PIP_ARGS[@]}" --requirement "${RUNTIME_REQUIREMENTS}"
"${VENV_DIR}/bin/python" -m pip install "${PIP_ARGS[@]}" --no-deps "${WHEEL_PATH}"
cat >"${STAGE_DIR}/usr/bin/${PACKAGE_NAME}" <<EOF cat >"${STAGE_DIR}/usr/bin/${PACKAGE_NAME}" <<EOF
#!/usr/bin/env bash #!/usr/bin/env bash

View file

@ -49,12 +49,22 @@ export_requirements() {
--python "${python_version}" >"${raw_path}" --python "${python_version}" >"${raw_path}"
python3 - "${raw_path}" "${output_path}" <<'PY' python3 - "${raw_path}" "${output_path}" <<'PY'
from pathlib import Path from pathlib import Path
import re
import sys import sys
raw_path = Path(sys.argv[1]) raw_path = Path(sys.argv[1])
output_path = Path(sys.argv[2]) output_path = Path(sys.argv[2])
lines = raw_path.read_text(encoding="utf-8").splitlines() lines = raw_path.read_text(encoding="utf-8").splitlines()
filtered = [line for line in lines if line.strip() != "."] exclude = {"pygobject", "python-xlib"}
filtered = []
for line in lines:
stripped = line.strip()
if not stripped or stripped == ".":
continue
match = re.match(r"([A-Za-z0-9_.-]+)", stripped)
if match and match.group(1).lower().replace("_", "-") in exclude:
continue
filtered.append(line)
output_path.write_text("\n".join(filtered) + "\n", encoding="utf-8") output_path.write_text("\n".join(filtered) + "\n", encoding="utf-8")
raw_path.unlink() raw_path.unlink()
PY PY
@ -81,6 +91,7 @@ WHEEL_PATH="$(latest_wheel_path)"
rm -rf "${PORTABLE_STAGE_DIR}" rm -rf "${PORTABLE_STAGE_DIR}"
mkdir -p "${PORTABLE_STAGE_DIR}/wheelhouse/common" mkdir -p "${PORTABLE_STAGE_DIR}/wheelhouse/common"
mkdir -p "${PORTABLE_STAGE_DIR}/requirements"
mkdir -p "${PORTABLE_STAGE_DIR}/systemd" mkdir -p "${PORTABLE_STAGE_DIR}/systemd"
cp "${WHEEL_PATH}" "${PORTABLE_STAGE_DIR}/wheelhouse/common/" cp "${WHEEL_PATH}" "${PORTABLE_STAGE_DIR}/wheelhouse/common/"
@ -98,14 +109,18 @@ python3 "${ROOT_DIR}/packaging/portable/portable_installer.py" \
--version "${VERSION}" \ --version "${VERSION}" \
--output "${PORTABLE_STAGE_DIR}/manifest.json" --output "${PORTABLE_STAGE_DIR}/manifest.json"
TMP_REQ_DIR="${BUILD_DIR}/portable/requirements"
mkdir -p "${TMP_REQ_DIR}"
export_requirements "3.10" "${TMP_REQ_DIR}/cp310.txt"
export_requirements "3.11" "${TMP_REQ_DIR}/cp311.txt"
export_requirements "3.12" "${TMP_REQ_DIR}/cp312.txt"
cp "${TMP_REQ_DIR}/cp310.txt" "${PORTABLE_STAGE_DIR}/requirements/cp310.txt"
cp "${TMP_REQ_DIR}/cp311.txt" "${PORTABLE_STAGE_DIR}/requirements/cp311.txt"
cp "${TMP_REQ_DIR}/cp312.txt" "${PORTABLE_STAGE_DIR}/requirements/cp312.txt"
if [[ -n "${TEST_WHEELHOUSE_ROOT}" ]]; then if [[ -n "${TEST_WHEELHOUSE_ROOT}" ]]; then
copy_prebuilt_wheelhouse "${TEST_WHEELHOUSE_ROOT}" "${PORTABLE_STAGE_DIR}/wheelhouse" copy_prebuilt_wheelhouse "${TEST_WHEELHOUSE_ROOT}" "${PORTABLE_STAGE_DIR}/wheelhouse"
else else
TMP_REQ_DIR="${BUILD_DIR}/portable/requirements"
mkdir -p "${TMP_REQ_DIR}"
export_requirements "3.10" "${TMP_REQ_DIR}/cp310.txt"
export_requirements "3.11" "${TMP_REQ_DIR}/cp311.txt"
export_requirements "3.12" "${TMP_REQ_DIR}/cp312.txt"
download_python_wheels "cp310" "310" "cp310" "${TMP_REQ_DIR}/cp310.txt" "${PORTABLE_STAGE_DIR}/wheelhouse/cp310" download_python_wheels "cp310" "310" "cp310" "${TMP_REQ_DIR}/cp310.txt" "${PORTABLE_STAGE_DIR}/wheelhouse/cp310"
download_python_wheels "cp311" "311" "cp311" "${TMP_REQ_DIR}/cp311.txt" "${PORTABLE_STAGE_DIR}/wheelhouse/cp311" download_python_wheels "cp311" "311" "cp311" "${TMP_REQ_DIR}/cp311.txt" "${PORTABLE_STAGE_DIR}/wheelhouse/cp311"
download_python_wheels "cp312" "312" "cp312" "${TMP_REQ_DIR}/cp312.txt" "${PORTABLE_STAGE_DIR}/wheelhouse/cp312" download_python_wheels "cp312" "312" "cp312" "${TMP_REQ_DIR}/cp312.txt" "${PORTABLE_STAGE_DIR}/wheelhouse/cp312"

View file

@ -21,7 +21,6 @@ from typing import Any
from aiprocess import LlamaProcessor from aiprocess import LlamaProcessor
from config import Config, ConfigValidationError, load, redacted_dict, save, validate from config import Config, ConfigValidationError, load, redacted_dict, save, validate
from constants import DEFAULT_CONFIG_PATH, MODEL_PATH, RECORD_TIMEOUT_SEC from constants import DEFAULT_CONFIG_PATH, MODEL_PATH, RECORD_TIMEOUT_SEC
from config_ui import ConfigUiResult, run_config_ui, show_about_dialog, show_help_dialog
from desktop import get_desktop_adapter from desktop import get_desktop_adapter
from diagnostics import ( from diagnostics import (
doctor_command, doctor_command,
@ -791,6 +790,30 @@ def _app_version() -> str:
return "0.0.0-dev" return "0.0.0-dev"
def _load_config_ui_attr(attr_name: str) -> Any:
try:
from config_ui import __dict__ as config_ui_exports
except ModuleNotFoundError as exc:
missing_name = exc.name or "unknown"
raise RuntimeError(
"settings UI is unavailable because a required X11 Python dependency "
f"is missing ({missing_name})"
) from exc
return config_ui_exports[attr_name]
def _run_config_ui(*args, **kwargs):
return _load_config_ui_attr("run_config_ui")(*args, **kwargs)
def _show_help_dialog() -> None:
_load_config_ui_attr("show_help_dialog")()
def _show_about_dialog() -> None:
_load_config_ui_attr("show_about_dialog")()
def _read_json_file(path: Path) -> Any: def _read_json_file(path: Path) -> Any:
if not path.exists(): if not path.exists():
raise RuntimeError(f"file does not exist: {path}") raise RuntimeError(f"file does not exist: {path}")
@ -1446,8 +1469,8 @@ def _run_settings_required_tray(desktop, config_path: Path) -> bool:
lambda: "settings_required", lambda: "settings_required",
lambda: None, lambda: None,
on_open_settings=open_settings_callback, on_open_settings=open_settings_callback,
on_show_help=show_help_dialog, on_show_help=_show_help_dialog,
on_show_about=show_about_dialog, on_show_about=_show_about_dialog,
on_open_config=lambda: logging.info("config path: %s", config_path), on_open_config=lambda: logging.info("config path: %s", config_path),
) )
return reopen_settings["value"] return reopen_settings["value"]
@ -1456,7 +1479,7 @@ def _run_settings_required_tray(desktop, config_path: Path) -> bool:
def _run_settings_until_config_ready(desktop, config_path: Path, initial_cfg: Config) -> Config | None: def _run_settings_until_config_ready(desktop, config_path: Path, initial_cfg: Config) -> Config | None:
draft_cfg = initial_cfg draft_cfg = initial_cfg
while True: while True:
result: ConfigUiResult = run_config_ui( result = _run_config_ui(
draft_cfg, draft_cfg,
desktop, desktop,
required=True, required=True,
@ -1665,7 +1688,7 @@ def _run_command(args: argparse.Namespace) -> int:
if daemon.get_state() != State.IDLE: if daemon.get_state() != State.IDLE:
logging.info("settings UI is available only while idle") logging.info("settings UI is available only while idle")
return return
result = run_config_ui( result = _run_config_ui(
cfg, cfg,
desktop, desktop,
required=False, required=False,
@ -1740,8 +1763,8 @@ def _run_command(args: argparse.Namespace) -> int:
daemon.get_state, daemon.get_state,
lambda: shutdown("quit requested"), lambda: shutdown("quit requested"),
on_open_settings=open_settings_callback, on_open_settings=open_settings_callback,
on_show_help=show_help_dialog, on_show_help=_show_help_dialog,
on_show_about=show_about_dialog, on_show_about=_show_about_dialog,
is_paused_getter=daemon.is_paused, is_paused_getter=daemon.is_paused,
on_toggle_pause=daemon.toggle_paused, on_toggle_pause=daemon.toggle_paused,
on_reload_config=reload_config_callback, on_reload_config=reload_config_callback,

View file

@ -102,7 +102,7 @@ def _sounddevice():
import sounddevice as sd # type: ignore[import-not-found] import sounddevice as sd # type: ignore[import-not-found]
except ModuleNotFoundError as exc: except ModuleNotFoundError as exc:
raise RuntimeError( raise RuntimeError(
"sounddevice is not installed; install dependencies with `uv sync --extra x11`" "sounddevice is not installed; install dependencies with `uv sync`"
) from exc ) from exc
return sd return sd

View file

@ -1,5 +1,6 @@
import io import io
import json import json
import subprocess
import sys import sys
import tempfile import tempfile
import unittest import unittest
@ -242,6 +243,36 @@ class AmanCliTests(unittest.TestCase):
self.assertEqual(exit_code, 0) self.assertEqual(exit_code, 0)
self.assertEqual(out.getvalue().strip(), "1.2.3") self.assertEqual(out.getvalue().strip(), "1.2.3")
def test_version_command_does_not_import_config_ui(self):
script = f"""
import builtins
import sys
from pathlib import Path
sys.path.insert(0, {str(SRC)!r})
real_import = builtins.__import__
def blocked(name, globals=None, locals=None, fromlist=(), level=0):
if name == "config_ui":
raise ModuleNotFoundError("blocked config_ui")
return real_import(name, globals, locals, fromlist, level)
builtins.__import__ = blocked
import aman
args = aman._parse_cli_args(["version"])
raise SystemExit(aman._version_command(args))
"""
result = subprocess.run(
[sys.executable, "-c", script],
cwd=ROOT,
text=True,
capture_output=True,
check=False,
)
self.assertEqual(result.returncode, 0, result.stderr)
self.assertRegex(result.stdout.strip(), r"\S+")
def test_app_version_prefers_local_pyproject_version(self): def test_app_version_prefers_local_pyproject_version(self):
pyproject_text = '[project]\nversion = "9.9.9"\n' pyproject_text = '[project]\nversion = "9.9.9"\n'
@ -600,7 +631,7 @@ class AmanCliTests(unittest.TestCase):
with patch("aman._lock_single_instance", return_value=object()), patch( with patch("aman._lock_single_instance", return_value=object()), patch(
"aman.get_desktop_adapter", return_value=desktop "aman.get_desktop_adapter", return_value=desktop
), patch( ), patch(
"aman.run_config_ui", "aman._run_config_ui",
return_value=ConfigUiResult(saved=True, config=onboard_cfg, closed_reason="saved"), return_value=ConfigUiResult(saved=True, config=onboard_cfg, closed_reason="saved"),
) as config_ui_mock, patch("aman.Daemon", _FakeDaemon): ) as config_ui_mock, patch("aman.Daemon", _FakeDaemon):
exit_code = aman._run_command(args) exit_code = aman._run_command(args)
@ -618,7 +649,7 @@ class AmanCliTests(unittest.TestCase):
with patch("aman._lock_single_instance", return_value=object()), patch( with patch("aman._lock_single_instance", return_value=object()), patch(
"aman.get_desktop_adapter", return_value=desktop "aman.get_desktop_adapter", return_value=desktop
), patch( ), patch(
"aman.run_config_ui", "aman._run_config_ui",
return_value=ConfigUiResult(saved=False, config=None, closed_reason="cancelled"), return_value=ConfigUiResult(saved=False, config=None, closed_reason="cancelled"),
), patch("aman.Daemon") as daemon_cls: ), patch("aman.Daemon") as daemon_cls:
exit_code = aman._run_command(args) exit_code = aman._run_command(args)
@ -640,7 +671,7 @@ class AmanCliTests(unittest.TestCase):
with patch("aman._lock_single_instance", return_value=object()), patch( with patch("aman._lock_single_instance", return_value=object()), patch(
"aman.get_desktop_adapter", return_value=desktop "aman.get_desktop_adapter", return_value=desktop
), patch( ), patch(
"aman.run_config_ui", "aman._run_config_ui",
side_effect=config_ui_results, side_effect=config_ui_results,
), patch("aman.Daemon", _FakeDaemon): ), patch("aman.Daemon", _FakeDaemon):
exit_code = aman._run_command(args) exit_code = aman._run_command(args)

View file

@ -75,8 +75,10 @@ def _build_fake_wheel(root: Path, version: str) -> Path:
def _bundle_dir(root: Path, version: str) -> Path: def _bundle_dir(root: Path, version: str) -> Path:
bundle_dir = root / f"bundle-{version}" bundle_dir = root / f"bundle-{version}"
(bundle_dir / "wheelhouse" / "common").mkdir(parents=True, exist_ok=True) (bundle_dir / "wheelhouse" / "common").mkdir(parents=True, exist_ok=True)
(bundle_dir / "requirements").mkdir(parents=True, exist_ok=True)
for tag in portable.SUPPORTED_PYTHON_TAGS: for tag in portable.SUPPORTED_PYTHON_TAGS:
(bundle_dir / "wheelhouse" / tag).mkdir(parents=True, exist_ok=True) (bundle_dir / "wheelhouse" / tag).mkdir(parents=True, exist_ok=True)
(bundle_dir / "requirements" / f"{tag}.txt").write_text("", encoding="utf-8")
(bundle_dir / "systemd").mkdir(parents=True, exist_ok=True) (bundle_dir / "systemd").mkdir(parents=True, exist_ok=True)
shutil.copy2(PORTABLE_DIR / "install.sh", bundle_dir / "install.sh") shutil.copy2(PORTABLE_DIR / "install.sh", bundle_dir / "install.sh")
shutil.copy2(PORTABLE_DIR / "uninstall.sh", bundle_dir / "uninstall.sh") shutil.copy2(PORTABLE_DIR / "uninstall.sh", bundle_dir / "uninstall.sh")
@ -213,6 +215,9 @@ class PortableBundleTests(unittest.TestCase):
self.assertIn(f"{prefix}/wheelhouse/cp310", names) self.assertIn(f"{prefix}/wheelhouse/cp310", names)
self.assertIn(f"{prefix}/wheelhouse/cp311", names) self.assertIn(f"{prefix}/wheelhouse/cp311", names)
self.assertIn(f"{prefix}/wheelhouse/cp312", names) self.assertIn(f"{prefix}/wheelhouse/cp312", names)
self.assertIn(f"{prefix}/requirements/cp310.txt", names)
self.assertIn(f"{prefix}/requirements/cp311.txt", names)
self.assertIn(f"{prefix}/requirements/cp312.txt", names)
self.assertIn(f"{prefix}/systemd/aman.service.in", names) self.assertIn(f"{prefix}/systemd/aman.service.in", names)
def test_fresh_install_creates_managed_paths_and_starts_service(self): def test_fresh_install_creates_managed_paths_and_starts_service(self):

12
uv.lock generated
View file

@ -16,13 +16,9 @@ dependencies = [
{ name = "numpy", version = "2.2.6", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version < '3.11'" }, { name = "numpy", version = "2.2.6", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version < '3.11'" },
{ name = "numpy", version = "2.4.2", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version >= '3.11'" }, { name = "numpy", version = "2.4.2", source = { registry = "https://pypi.org/simple" }, marker = "python_full_version >= '3.11'" },
{ name = "pillow" }, { name = "pillow" },
{ name = "sounddevice" },
]
[package.optional-dependencies]
x11 = [
{ name = "pygobject" }, { name = "pygobject" },
{ name = "python-xlib" }, { name = "python-xlib" },
{ name = "sounddevice" },
] ]
[package.metadata] [package.metadata]
@ -31,11 +27,11 @@ requires-dist = [
{ name = "llama-cpp-python" }, { name = "llama-cpp-python" },
{ name = "numpy" }, { name = "numpy" },
{ name = "pillow" }, { name = "pillow" },
{ name = "pygobject", marker = "extra == 'x11'" }, { name = "pygobject" },
{ name = "python-xlib", marker = "extra == 'x11'" }, { name = "python-xlib" },
{ name = "sounddevice" }, { name = "sounddevice" },
] ]
provides-extras = ["x11", "wayland"] provides-extras = ["wayland"]
[[package]] [[package]]
name = "anyio" name = "anyio"