Commit Graph

13 Commits

Author SHA1 Message Date
Teknium
d99af4187b refactor: move the Singularity terminal backend out of core into the singularity catalog plugin
The Singularity/Apptainer backend (tools/environments/singularity.py) now ships
as the official 'singularity' plugin in NousResearch/hermes-official-plugins,
registered through the terminal-environment provider seam under the same
backend name and config keys (terminal.backend: singularity,
terminal.singularity_image / TERMINAL_SINGULARITY_IMAGE, terminal.container_*).

- 'singularity' leaves BUILTIN_BACKEND_NAMES so the plugin can register it;
  every hardcoded classification set drops it (the provider declares
  is_remote/is_container/supports_streams instead).
- LEFT_CORE gains a singularity row: homes whose terminal.backend (or .env
  TERMINAL_ENV) is singularity get the catalog plugin once, on hermes update
  or agent/gateway start. An unknown-backend error for 'singularity' names
  the install command (new row field terminal_backend).
- A plugin backend receives its per-task '<backend>_image' override; batch
  runs register one for the active backend.
- BaseEnvironment's sudo-probe knob is renamed _passwordless_sudo_probe_supported:
  plugin backends set it, and the old spelling trips the install scanner.
- Core's scratch-dir disk warning and process-exit sweep were Singularity-only
  and move to the plugin; the singularity setup row, dashboard probe/row and
  config defaults/bridges go too. Docs point at the plugin.
2026-10-22 05:26:10 -07:00
Teknium
ee9f9c82a0 fix(gateway,cli): a skill's missing env var opens main's masked secret panel; the gateway saves it
Main's classic CLI registered set_secret_capture_callback in process: skill_view of a
skill whose required_environment_variables were missing opened the masked "Skill Setup
Required" panel and saved the answer to the profile .env. On the session authority the
skill runs in the gateway, where a gateway surface only returned the "secure secret
entry is not available" hint.

Gateway (generic, no CLI naming; usable by the TUI/Desktop too):
- gateway/session_secret_prompt.py: for a local viewer's turn the runner binds a
  turn-scoped capture callback (tools.skills_tool.bind_turn_secret_capture, a ContextVar
  so tool workers started with propagate_context_to_thread inherit it). It sends main's
  `secret` server→client request (SecretRequestParams -> ValueResult) through the same
  request/response machinery as the sudo prompt (session_sudo_prompt.ask_viewer), saves a
  non-empty answer with save_env_value_secure in the gateway, and returns main's result.
- tools/skills_tool_setup: a bound turn callback wins over the gateway-surface hint and
  the process-global slot. Messaging turns bind nothing: hint unchanged.

CLI: GatewayAgent answers a `secret` request with main's own panel (prompt_for_secret,
same lines) and returns the value in the JSON-RPC response; the panel's local .env save
is captured, so this process never writes .env.

LEDGER: CB-021, IPS-049 (W4).
(cherry picked from commit 23d28512108bc0469af2c7423f9c6e8e68e87258)
2026-10-12 22:48:29 -07:00
Maciej Lisiewski
d76cce4f11 ci: apply all automatic linter fixes available 2026-10-08 17:22:54 +02:00
KoNit-K
0aec64c874 fix(skills): honor profile-scoped readiness secrets 2026-09-15 18:33:15 -07:00
Teknium
d2f2862d51 refactor(tools): fold single-use readiness helpers, compact module docstrings, wrap long lines 2026-09-03 01:09:55 -07:00
Teknium
9bcf3069eb refactor(tools): dedup stat check, secret-capture walrus, comment reflow 2026-09-03 00:53:28 -07:00
Teknium
c37eff79e3 refactor(tools): skills_tool_setup folds setup-metadata normalizer into the env-var merge 2026-09-03 00:48:15 -07:00
Teknium
73c9cd1c24 refactor(tools): skills_tool_setup drops unused prerequisites.commands/None-snapshot paths; trims re-export lists 2026-09-03 00:38:39 -07:00
Teknium
4355ad0ce2 refactor(tools): skills_tool drops _Located dataclass, shares _safe_frontmatter, flattens env-var merge; squeeze body blanks 2026-09-03 00:26:48 -07:00
Teknium
90075b1d22 refactor(tools): skills_tool_setup walrus compaction 2026-09-02 23:33:39 -07:00
Teknium
f9ab9abb89 refactor(tools): compact skills_tool plugin/setup/dedup signatures and guards 2026-09-02 23:09:18 -07:00
Teknium
1523a3ba9c refactor(tools): extract skill_view locate/security phases, compact skills_tool siblings 2026-09-02 22:17:38 -07:00
Teknium
7c1ec19d4a refactor(tools/skills): split skills_hub into per-source modules; extract skill_manager guards/batch, skills_tool dedup/plugin/setup; compact skill_usage, skills_guard 2026-09-02 14:45:15 -07:00