Skip to content

Commit b36f237

Browse files
authored
fix(build): harden rustls dependency path for Linux builds (RightNow-AI#275)
1 parent 3234159 commit b36f237

3 files changed

Lines changed: 16 additions & 8 deletions

File tree

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ http-body-util = "0.1"
9595
# OpenTelemetry — OTLP trace + metrics export
9696
opentelemetry = { version = "0.31", default-features = false, features = ["trace", "metrics"] }
9797
opentelemetry_sdk = { version = "0.31", default-features = false, features = ["trace", "metrics"] }
98-
opentelemetry-otlp = { version = "0.31", default-features = false, features = ["trace", "metrics", "http-proto", "reqwest-blocking-client"] }
98+
opentelemetry-otlp = { version = "0.31", default-features = false, features = ["trace", "metrics", "http-proto", "reqwest-client", "reqwest-rustls-webpki-roots"] }
9999

100100
[features]
101101
default = []

README.md

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,8 @@ ls -lh target/release/zeroclaw
6767
```bash
6868
git clone https://github.com/zeroclaw-labs/zeroclaw.git
6969
cd zeroclaw
70-
cargo build --release
71-
cargo install --path . --force
70+
cargo build --release --locked
71+
cargo install --path . --force --locked
7272

7373
# Quick setup (no prompts)
7474
zeroclaw onboard --api-key sk-... --provider openrouter
@@ -474,6 +474,18 @@ A git hook runs `cargo fmt --check`, `cargo clippy -- -D warnings`, and `cargo t
474474
git config core.hooksPath .githooks
475475
```
476476

477+
### Build troubleshooting (Linux OpenSSL errors)
478+
479+
If you see an `openssl-sys` build error, sync dependencies and rebuild with the repository lockfile:
480+
481+
```bash
482+
git pull
483+
cargo build --release --locked
484+
cargo install --path . --force --locked
485+
```
486+
487+
ZeroClaw is configured to use `rustls` for HTTP/TLS dependencies; `--locked` keeps the transitive graph deterministic on fresh environments.
488+
477489
To skip the hook when you need a quick push during development:
478490

479491
```bash

src/channels/mod.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ const CHANNEL_MAX_IN_FLIGHT_MESSAGES: usize = 64;
5252
struct ChannelRuntimeContext {
5353
channels_by_name: Arc<HashMap<String, Arc<dyn Channel>>>,
5454
provider: Arc<dyn Provider>,
55-
provider_name: Arc<String>,
5655
memory: Arc<dyn Memory>,
5756
tools_registry: Arc<Vec<Box<dyn Tool>>>,
5857
observer: Arc<dyn Observer>,
@@ -188,7 +187,7 @@ async fn process_channel_message(ctx: Arc<ChannelRuntimeContext>, msg: traits::C
188187
&mut history,
189188
ctx.tools_registry.as_ref(),
190189
ctx.observer.as_ref(),
191-
"channels",
190+
"channel-runtime",
192191
ctx.model.as_str(),
193192
ctx.temperature,
194193
),
@@ -969,7 +968,6 @@ pub async fn start_channels(config: Config) -> Result<()> {
969968
let runtime_ctx = Arc::new(ChannelRuntimeContext {
970969
channels_by_name,
971970
provider: Arc::clone(&provider),
972-
provider_name: Arc::new(provider_name),
973971
memory: Arc::clone(&mem),
974972
tools_registry: Arc::clone(&tools_registry),
975973
observer,
@@ -1162,7 +1160,6 @@ mod tests {
11621160
let runtime_ctx = Arc::new(ChannelRuntimeContext {
11631161
channels_by_name: Arc::new(channels_by_name),
11641162
provider: Arc::new(ToolCallingProvider),
1165-
provider_name: Arc::new("openrouter".to_string()),
11661163
memory: Arc::new(NoopMemory),
11671164
tools_registry: Arc::new(vec![Box::new(MockPriceTool)]),
11681165
observer: Arc::new(NoopObserver),
@@ -1253,7 +1250,6 @@ mod tests {
12531250
provider: Arc::new(SlowProvider {
12541251
delay: Duration::from_millis(250),
12551252
}),
1256-
provider_name: Arc::new("openrouter".to_string()),
12571253
memory: Arc::new(NoopMemory),
12581254
tools_registry: Arc::new(vec![]),
12591255
observer: Arc::new(NoopObserver),

0 commit comments

Comments
 (0)