docs: overhaul README with badges + add privacy policy#13
Conversation
…olicy - Centered tagline + 6 shields (PyPI, Python, CI, Coverage, License, Privacy) - Add "What is iotcli?" section with key principles - Add Demo section with list/status/JSON examples - Add Architecture overview with directory tree - Expand AI Agent Integration with clearer MCP/skill/workflow sections - Add PRIVACY.md: local-only data, Fernet encryption, no telemetry - Fix duplicate device lookup line in control.py (post-merge artifact)
Greptile SummaryThis PR delivers a polished README overhaul (badges, demo output, architecture tree, expanded AI agent docs), a new
|
| Filename | Overview |
|---|---|
| src/iotcli/cli/commands/control.py | Removed duplicate cfg.get_device_or_none() call (good cleanup), but the set action is missing a return after its validation error, causing a double error message via the outer exception handler. |
| PRIVACY.md | New privacy policy document; well-structured and accurate, but one bullet has a broken bold span (** Governed with a leading space) that won't render correctly. |
| README.md | Comprehensive README overhaul with badges, demo section, architecture overview, and AI agent integration docs — no issues found. |
Sequence Diagram
sequenceDiagram
actor User
participant CLI as control.py
participant Cfg as ConfigManager
participant Ctrl as DeviceController
participant Out as Output
User->>CLI: iotcli control set DEVICE VALUE
CLI->>Cfg: get_device_or_none(device_name)
Cfg-->>CLI: device or None
alt device not found
CLI->>Out: error("Device not found")
CLI-->>User: error output
else action is set, value invalid
CLI->>Out: error("set requires property=value")
Note over CLI: missing return - falls through to split()
CLI->>Out: error(AttributeError or ValueError message)
CLI-->>User: two error messages
else action is set, value valid
CLI->>Ctrl: set_value(device, prop, coerced)
Ctrl-->>CLI: ok
CLI->>Cfg: update_status(device_name, ONLINE)
CLI->>Out: success(...)
CLI-->>User: success output
end
Comments Outside Diff (1)
-
src/iotcli/cli/commands/control.py, line 95-97 (link)Missing
returnafter validation error causes double error outputWhen
valueisNone(no argument provided) or lacks=,out.error(...)is called correctly on line 96, but execution falls through to line 97 wherevalue.split("=", 1)raises eitherAttributeError(ifvalueisNone) orValueError(if there's no=). The outerexcept Exceptionon line 107 catches it and callsout.error(str(e))a second time, so the user sees two error messages: the helpful one, then a raw Python exception string.A
returnis needed after the validation error:
Reviews (1): Last reviewed commit: "docs(readme): overhaul with badges, demo..." | Re-trigger Greptile
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
|
@joeVenner review |
Summary
Post-merge polish after PR #12. Adds an impressive README overhaul and a privacy policy document.
What's New
README overhaul:
list,status, and--jsonoutputPRIVACY.mdPRIVACY.md:
Bug fix: Removed duplicate
device = cfg.get_device_or_none(device_name)line incontrol.py(post-merge artifact from PR fix: address pre-publish review issues #12).Test Plan
pytest -qpasses (4 passed, 1 skipped)🤖 Generated with Claude Code