Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion crates/buzz-acp/src/engram_fetch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ async fn fetch_core_body(
agent_keys: &Keys,
owner: &PublicKey,
) -> Result<Option<String>, String> {
let k_c = conversation_key(agent_keys.secret_key(), owner);
let k_c = conversation_key(agent_keys.secret_key(), owner)
.map_err(|e| format!("conversation key derivation failed: {e}"))?;
let d = d_tag(&k_c, buzz_core::engram::CORE_SLUG);

let filter = nostr::Filter::new()
Expand Down
11 changes: 10 additions & 1 deletion crates/buzz-cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,15 @@ buzz channels list | jq '.[].name'
constraint omitted from the command is removed. `protect list` reports malformed
stored rules in `validation_error` so an owner can remove and repair them.

`mem patch` checks the value it is *replacing*, not the replacement.
`--base-hash <hex>` (from `buzz mem hash <slug>`) refuses the write with exit 5
if another writer moved the head first, and hunk context and `-` lines must
match the current value verbatim at their declared line numbers. Neither check
looks at the `+` lines: a patch that quotes the current value correctly can
insert content from anywhere and will be accepted. To check what actually
landed, use `--dry-run` (prints the sha256 that would be written) and re-read
the slug after writing.

## Commands

| Group | Subcommand | Description |
Expand Down Expand Up @@ -164,7 +173,7 @@ stored rules in `validation_error` so an owner can remove and repair them.
| | `get` | Print memory value to stdout |
| | `hash` | Print SHA-256 hex of memory value |
| | `set` | Write a memory value (use `-` for stdin) |
| | `patch` | Apply unified diff to memory value |
| | `patch` | Apply unified diff to memory value (checks the preimage only) |
| | `rm` | Publish a tombstone to delete memory |

## Architecture
Expand Down
Loading