fix: missing minisweagent_path module + add nix checks

- Patch upstream pyproject.toml to include minisweagent_path in py-modules
- Copy mini-swe-agent/src/minisweagent into package for importability
- Add 3 nix checks: package-contents, cli-commands, doctor
- All binaries tested: hermes, hermes-agent, hermes-acp
- hermes gateway, config, status, claw migrate all verified working
This commit is contained in:
Ciphercat 2026-03-16 01:15:13 +00:00
commit 1d95780fff
3 changed files with 94 additions and 1 deletions

View file

@ -147,7 +147,19 @@ pythonPackages.buildPythonApplication {
# Don't run tests during build
doCheck = false;
# mini-swe-agent is included via fetchSubmodules and referenced at runtime
# Upstream pyproject.toml is missing minisweagent_path from py-modules.
# Also ensure mini-swe-agent/src is importable.
postPatch = ''
# Fix: add minisweagent_path.py to py-modules if missing from pyproject.toml
if [ -f minisweagent_path.py ] && ! grep -q minisweagent_path pyproject.toml; then
sed -i 's/py-modules = \[/py-modules = ["minisweagent_path", /' pyproject.toml
fi
# Make mini-swe-agent importable by copying src into the package
if [ -d mini-swe-agent/src/minisweagent ]; then
cp -r mini-swe-agent/src/minisweagent .
fi
'';
postFixup = ''
# Wrap binaries with runtime deps on PATH