2.5 KiB
AI Agent TODOs
Pending tasks for AI agents. Remove items when completed.
Features
-
Extract TS-exported types into a lightweight sub-crate for fast binding generation
Problem:
make ts-bindingscompiles the entirestart-oscrate (with all dependencies: tokio, axum, openssl, etc.) just to run test functions that serialize type definitions to.tsfiles. Even in debug mode, this takes minutes. The generated output is pure type info — no runtime code is needed.Goal: Generate TS bindings in seconds by isolating exported types in a small crate with minimal dependencies.
Approach: Create a
core/bindings-types/sub-crate containing (or re-exporting) all 168#[ts(export)]types. This crate depends only onserde,ts-rs,exver, and other type-only crates — not on tokio, axum, openssl, etc. Thenbuild-ts.shrunscargo test -p bindings-typesinstead ofcargo test -p start-os.Challenge: The exported types are scattered across
core/src/and reference each other and other crate types. Extracting them requires either moving the type definitions into the sub-crate (and importing them back intostart-os) or restructuring to share a common types crate. -
Make
SetupExecuteParams.passwordoptional in the backend - @dr-bonezProblem: In
core/src/setup.rs,SetupExecuteParamshaspassword: EncryptedWire(non-nullable), but the frontend needs to sendnullfor restore/transfer flows where the user keeps their existing password. TheAttachParamstype correctly usesOption<EncryptedWire>for this purpose.Fix: Change
password: EncryptedWiretopassword: Option<EncryptedWire>inSetupExecuteParamsand handle theNonecase in theexecutehandler (similar to howattachhandles it). -
Auto-configure port forwards via UPnP/NAT-PMP/PCP - @dr-bonez
Goal: When a binding is marked public, automatically configure port forwards on the user's router using UPnP, NAT-PMP, or PCP, instead of requiring manual router configuration. Fall back to displaying manual instructions (the port forward mapping from patch-db) when auto-configuration is unavailable or fails.
-
Decouple createTask from service running state - @dr-bonez
Problem:
createTaskcurrently depends on the service being in a running state.Goal: The
input-not-matcheshandler in StartOS should queue the task, check it once the service is ready, then clear it if it matches. This allows tasks to be created regardless of whether the service is currently running.