proto becomes bxcore, the one shared crate (M5b task 00)
Done the way the owner asked and the spike mapped: the crate and the manifests renamed, then what the build reported fixed. Layers: 138 "proto unresolved" errors across 169 files; cargo fmt reordering imports; six fixture paths built as strings in brokerd's and bxctl's tests, which the compiler cannot see, and comments naming crates/proto/; the crate-dependency check and its self-test. One more the spike did not reach: a `\nproto =` key inside a printf format in the self-test, which a word-boundary replacement skips because `n` and `p` are both word characters. make gate: gate: ok, 944 tests; no new entry in /tmp. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
use std::sync::MutexGuard;
|
||||
|
||||
use proto::{ApprovalAnswer, AuditEvent, DataClass, DenyReason, Timestamp, ToolResponse};
|
||||
use bxcore::{ApprovalAnswer, AuditEvent, DataClass, DenyReason, Timestamp, ToolResponse};
|
||||
|
||||
use super::{Answer, Answered, Call, Grants, Inner, Ledger};
|
||||
use crate::approvals::Verdict;
|
||||
@@ -107,16 +107,16 @@ impl Ledger {
|
||||
guard: &mut MutexGuard<'_, Inner>,
|
||||
call: &Call,
|
||||
now: Timestamp,
|
||||
status: proto::ResultStatus,
|
||||
status: bxcore::ResultStatus,
|
||||
taint_after: DataClass,
|
||||
response: &ToolResponse,
|
||||
) -> ToolResponse {
|
||||
let (sha256, bytes) = match response {
|
||||
ToolResponse::Result { content, .. } => match proto::sha256(content.as_bytes()) {
|
||||
ToolResponse::Result { content, .. } => match bxcore::sha256(content.as_bytes()) {
|
||||
Ok(sha) => (sha, u64::try_from(content.len()).unwrap_or(u64::MAX)),
|
||||
Err(_) => return Self::not_recorded(),
|
||||
},
|
||||
ToolResponse::Failed { message } => match proto::sha256(message.as_bytes()) {
|
||||
ToolResponse::Failed { message } => match bxcore::sha256(message.as_bytes()) {
|
||||
Ok(sha) => (sha, u64::try_from(message.len()).unwrap_or(u64::MAX)),
|
||||
Err(_) => return Self::not_recorded(),
|
||||
},
|
||||
@@ -182,7 +182,7 @@ impl Ledger {
|
||||
&mut guard,
|
||||
call,
|
||||
now,
|
||||
proto::ResultStatus::Result,
|
||||
bxcore::ResultStatus::Result,
|
||||
raised.taint,
|
||||
&response,
|
||||
)
|
||||
@@ -197,7 +197,7 @@ impl Ledger {
|
||||
&mut guard,
|
||||
call,
|
||||
now,
|
||||
proto::ResultStatus::Failed,
|
||||
bxcore::ResultStatus::Failed,
|
||||
taint_after,
|
||||
&response,
|
||||
)
|
||||
|
||||
@@ -6,7 +6,7 @@ mod answer;
|
||||
|
||||
use std::sync::{Mutex, MutexGuard};
|
||||
|
||||
use proto::{
|
||||
use bxcore::{
|
||||
AuditEvent, CallId, DataClass, DecisionRecord, DenyReason, GrantProblem, Mode, SessionId,
|
||||
Timestamp, ToolRequest, ToolResponse,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user