bridge: rename slack-bridge to broker-gateway#155
Conversation
Greptile SummaryRenames Key changes:
Issues found:
Confidence Score: 4/5
Important Files Changed
Last reviewed commit: 3371c31 |
Additional Comments (2)
Prompt To Fix With AIThis is a comment left during a code review.
Path: .c8rc.json
Line: 4
Comment:
path needs updating to `broker-gateway/security.mjs`
```suggestion
"broker-gateway/security.mjs",
```
How can I resolve this? If you propose a fix, please make it concise.
Prompt To Fix With AIThis is a comment left during a code review.
Path: .gitignore
Line: 5-7
Comment:
gitignore entries need updating to `broker-gateway/`
```suggestion
# Broker gateway
broker-gateway/node_modules/
broker-gateway/.env
```
How can I resolve this? If you propose a fix, please make it concise. |
15c3ef3 to
132fc8d
Compare
- bin/ci/smoke-agent-inference.sh: sends a real LLM prompt via session-control RPC, waits for turn_end, validates response. - Gated by BAUDBOT_CI_INFERENCE_SMOKE=1 (default off for PR CI). - BAUDBOT_CI_INFERENCE_SMOKE_OPTIONAL=1 for fail-open mode. - CI_ANTHROPIC_API_KEY injected into agent .env when available. - bin/ci/droplet.sh run: accepts optional KEY=VALUE env vars to forward to the remote droplet script. - .github/workflows/nightly.yml: daily schedule + manual dispatch, runs full integration + inference smoke on both Ubuntu and Arch.
- Remove gating flags — inference smoke runs unconditionally. - Use anthropic/claude-haiku via BAUDBOT_MODEL override (cheap). - Add BAUDBOT_MODEL to .env.schema and start.sh model selection. - Pass CI_ANTHROPIC_API_KEY in integration.yml for every PR run. - Remove nightly.yml (redundant now that inference runs on all PRs).
| return 1 | ||
| fi | ||
| log "injecting CI API key and model override into agent .env" | ||
| sed -i "s|^ANTHROPIC_API_KEY=.*|ANTHROPIC_API_KEY=${CI_ANTHROPIC_API_KEY}|" "$AGENT_ENV" |
There was a problem hiding this comment.
Bug: The smoke test's sed command for ANTHROPIC_API_KEY injection is fragile. It fails silently if the key doesn't exist in .env, which occurs when a non-Anthropic LLM is used.
Severity: MEDIUM
Suggested Fix
Update the script to check if ANTHROPIC_API_KEY exists in the .env file before attempting to replace it. If it doesn't exist, append the key and value to the file. This mirrors the safer pattern already used for BAUDBOT_MODEL in the same script.
Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: bin/ci/smoke-agent-inference.sh#L158
Potential issue: The smoke test script at `bin/ci/smoke-agent-inference.sh` uses a `sed`
command to update the `ANTHROPIC_API_KEY`. This command silently fails if the key is not
already present in the agent's `.env` file. The agent installation process only includes
the API key for the LLM provider selected during setup. Consequently, if an agent is
configured with a provider other than Anthropic, the `.env` file will not contain
`ANTHROPIC_API_KEY`. When the smoke test runs against such a configuration, the key
injection fails, and the subsequent inference test fails with an authentication error,
creating a false negative and making the test fragile.
Summary
Rename
slack-bridgetobroker-gatewayto reflect multi-channel architecture direction.What changed
slack-bridge/→broker-gateway/Why
slack-bridgewas channel-specific naming.broker-gatewaybetter matches current and future scope (Slack + additional channels/control-plane integrations).Notes
broker-bridge.mjs.Validation
npm run lint(environment currently missingshellcheck; existing non-rename lint warnings also present in heartbeat files)