mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-28 01:21:43 +00:00
fix(cli): allow empty strings and falsy values in config set
`hermes config set KEY ""` and `hermes config set KEY 0` were rejected because the guard used `not value` which is truthy for empty strings, zero, and False. Changed to `value is None` so only truly missing arguments are rejected. Closes #4277 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
49d7210fed
commit
c1606aed69
2 changed files with 42 additions and 2 deletions
|
|
@ -2040,7 +2040,7 @@ def config_command(args):
|
|||
elif subcmd == "set":
|
||||
key = getattr(args, 'key', None)
|
||||
value = getattr(args, 'value', None)
|
||||
if not key or not value:
|
||||
if not key or value is None:
|
||||
print("Usage: hermes config set <key> <value>")
|
||||
print()
|
||||
print("Examples:")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue