No reviewers
Labels
No labels
prio_critical
prio_low
type_bug
type_contact
type_issue
type_lead
type_question
type_story
type_task
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lhumina_code/hero_lib!140
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "development_mik"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
s96 hero_lib reconciliation — T1 #1 of the hero_proc#102 workspace
service.toml+ dep sweep (deps-first re-sequencing).Three stacked commits:
481bb322(s96 starter, local-only since s95) — patchesherolib_tools::agentfor the newhero_proc_sdk @ 8028f71f+API shape (5 breaking changes —JobLogsInput.attempt,JobLogsOutput.valueshape,LogLine.{line,src,stream,timestamp_ms}non-Option-ization,JobCreateOutput.idnon-Option-ization).f1c5b9b6— severs theherolib_ai → hero_aibroker_sdkStream* cascade by clean-deleting the dead streaming surface (5 Stream* re-exports,chat_streammethod,streamingfield,with_streaming_socket/supports_streaminghelpers,StreamErrorFromimpl,AiError::Streamvariant). Zero external callers verified across all 50+ workspace repos.40a2e2b3— conservative dep audit per playbook §4: stripsasync-trait/futures/tracingfromcrates/aiandherolib_core/tomlfromcrates/tools(zero matches under src/, bins/, tests/, examples/).Net: −64 LOC across 5 files, 1042/1042 workspace lib tests pass,
cargo build --workspace --releaseclean,cargo updatecleanly unblocked.Why this matters beyond
hero_libUntil this PR,
cargo updatecascade-failed in every downstream consumer ofherolib_ai(transitively, almost every repo in the D-07 35-set) becausehero_aibroker_sdk @ 00197f6removed the flat Stream* type family. hero_code PR #15 explicitly documented its D-10 acceptance criterion 3 as deferred for this reason; merging this PR retroactively validates hero_code#15's criterion 3 and unblocks T1 #2-#6 (hero_proc,hero_db,hero_aibroker,hero_router) + every T2/T3 repo in the sweep.D-10 acceptance state for
hero_libservice.tomlcanonical per crateBINARIES=""(library-only) per its ownCLAUDE.md, butlab infocheckdiscovers 4 crates with test/demo binaries (modeltest,ai_direct/{image_gen_test,nemotron_super,ttstest,modeltest_direct},clients/{opencode_tester,opencode_demo},web/herolib_web) flagging 21 D-10 issues. Resolution path (delete vs upgrade to canonical infra) deferred to #139 per scope.cargo build --workspace --releasecleancargo updateclean66abdf1f → 8028f71f; no cascade failures. Retro-validates hero_code#15 criterion 3.lab service … --startsmoke gatecrates/ai+ 2 incrates/tools).Out of scope (declared)
crates/ai/agent/,crates/ai/examples/,crates/ai_direct/examples/, etc.) — pre-existing, not introduced by this PR. My 3 edited files emit zerorustfmt --checkdrift.-D warnings(8 hits inagent/builder.rs,agent/runner.rs,agent/template.rs,model.rs) — pre-existing, my 3 edited files emit zero clippy findings.crates/ai/examples/(AiClient::from_env,AiClient::direct) andcrates/ai_direct/examples/(AiClient::get) — pre-existing references to methods that no longer exist; surfaces withcargo test --workspacebut notcargo build --workspace --releasebecause examples aren't built by default.hero_proc) — next session.Intra-T1 sequencing addendum candidate
D-10 intra-T1 ordering was originally
hero_proc → hero_router → hero_db → hero_lib → hero_code. s95 (hero_code first under that order) hit deps-first reality: criterion 3 cannot pass untilhero_lib'sherolib_aicascade reconciles. Proposing in-place D-10 addendum (not a new D-11) flipping intra-T1 tohero_lib → hero_proc → hero_db → hero_aibroker → hero_router → hero_code-retroactive. Decide at squash gate.Test plan
cargo build --workspace --release— clean, 2m 16scargo update—hero_proc_sdk @ 66abdf1f → 8028f71f, no failurescargo build --workspace --releasepost-update — cleancargo test --workspace --lib --release --no-fail-fast— 16 crates, 1042 pass / 6 ignored / 0 failcargo test -p herolib_ai --lib --release— 45 pass / 0 failrustfmt --checkon the 3 edited source files — cleancargo clippy -p herolib_ai --release --all-targets -- -D warningson edited source — zero new findings (8 hits pre-existing in unedited files)chat_stream(,StreamingClient,ChatChunkStream,StreamError— zero external callers00197f6(chat module surface unchanged since refactor)🤖 Generated with Claude Code
The hero_aibroker_sdk refactor on its `development` (HEAD 00197f6, "refactor: unify startup banner and socket dir resolution") removed the flat streaming type family in favor of a per-domain `chat` module: - ChatChunkStream, ChatStreamChunk, StreamChoice, StreamDelta, StreamUsage — gone (structural removal) - StreamingClient — gone (replaced by `chat::Client::ai_chat`) - StreamError — gone (folded into OpenRpcError) The new streaming contract is a `stream: true` flag on ChatRequest plus an SSE GET /events subscription on the broker's REST socket — not a typed Rust stream return. Workspace-wide grep confirms ZERO external callers of `AiClient::chat_stream(...)`, `StreamingClient`, `ChatChunkStream`, or any of the removed types. Across all 50+ workspace repos, the only internal call site was the method body itself. Clean-delete is correct, not re-implement against the new SSE surface. This commit: - drops the 5 Stream* re-exports from `crates/ai/src/lib.rs` - narrows the `hero_aibroker_sdk` use line in `client.rs` to `AIBrokerRawClient` only - removes `AiClient::chat_stream`, `AiClient::with_streaming_socket`, `AiClient::supports_streaming`, and the `streaming` field on the `AiClient` struct - simplifies `AiClient::default_socket` (no longer auto-attaches a REST socket — was the only `with_streaming_socket` caller) - removes `impl From<hero_aibroker_sdk::StreamError> for AiError` - removes the now-dead `AiError::Stream(String)` variant and the docstring reference to it - audits + strips 3 unused workspace deps from `crates/ai/Cargo.toml` (`async-trait`, `futures`, `tracing` — zero hits under src/, bins/, tests/, examples/) - updates the package `description` to drop the "streaming" mention Net: -64 LOC across 4 files, no test regressions (45/45 herolib_ai lib tests pass; workspace lib tests 16 crates / 1042 passing / 0 failing under `cargo test --workspace --lib --release`). This is the load-bearing change that unblocks `cargo update` across the entire 35-repo D-07 demo set. Prior to this commit, every downstream consumer of `herolib_ai` (i.e. anyone transitively pulling `hero_aibroker_sdk`) had its `cargo update` fail with E0599 on the removed Stream* type imports. s95 hero_code PR #15 documented this explicitly as criterion-3-deferred; this commit retroactively validates that criterion. Refs: - lhumina_code/hero_proc#102 - lhumina_code/hero_proc#102 (comment) - lhumina_code/hero_code#15 Signed-off-by: mik-tf Signed-off-by: mik-tf <logismos@protonmail.ch>mik-tf referenced this pull request from lhumina_code/hero_demo2026-05-16 00:33:48 +00:00
mik-tf referenced this pull request from lhumina_code/hero_demo2026-05-16 03:55:40 +00:00