Skip to content

feat(cli)!: remove the feedback command - #63

Merged
ilya-bogin-keenable merged 1 commit into
mainfrom
remove-feedback-command
Aug 13, 2026
Merged

feat(cli)!: remove the feedback command#63
ilya-bogin-keenable merged 1 commit into
mainfrom
remove-feedback-command

Conversation

@ilya-bogin-keenable

Copy link
Copy Markdown
Contributor

Why

Last night's nightly e2e failed on all three platforms (run 31674016437):

  • test_feedback_for_unsearched_query — expected error: Bad request, got Not found
  • test_no_scores — expected error: Invalid parameter, got Not found

The endpoint is gone, not flapping — probed live on both environments:

POST https://api.keenable.ai/v1/feedback            → 404 {"error":"Not found"}
POST https://api.keenable.ai/v1/feedback/public     → 404 {"error":"Not found"}
POST https://api-test.keenable.ai/v1/feedback/public → 404 {"error":"Not found"}
POST https://api.keenable.ai/v1/search/public       → 400  (route alive, just validation)

The Keenable MCP server likewise exposes only search_web_pages and fetch_page_content. A subcommand that can only ever 404 is worse than no subcommand, so this removes keenable feedback end to end rather than papering over the tests.

What

  • main.rs: drop the Feedback clap variant, its handler, and its update-check arm
  • search.rs: drop the feedback branch from the direct-HTTP dispatcher and the feedback() command
  • daemon.rs: drop the feedback branch from the daemon dispatcher
  • daemon.rs / search.rs: drop DaemonRequest::idempotent() and DaemonError::AfterSend. Feedback was the only non-idempotent command, so every daemon failure is now safe to retry directly and the before/after-send distinction no longer changes behavior (keeping it would have left a dead AfterSend(String) payload warning)
  • e2e: delete test_feedback.py, the write_feedback opt-in gate in conftest.py, test_login_flow.py's daemon-path feedback test, and feedback from the --help subcommand list in test_global.py
  • CI: drop the now-moot KEENABLE_E2E_WRITE_FEEDBACK note
  • CLAUDE.md: updated

Test

cargo build --release, cargo clippy --all-targets (clean, no warnings), cargo test (20 passed). e2e runs here in CI.

Breaking for anyone scripting keenable feedback, but that call already fails with a 404 against the live API.

🤖 Generated with Claude Code

The backend no longer serves /v1/feedback — both api.keenable.ai and
api-test.keenable.ai return 404 {"error":"Not found"} for the authenticated
and public routes alike, which is what broke last night's e2e run
(test_feedback_for_unsearched_query and test_no_scores asserted on the old
"Bad request"/"Invalid parameter" payloads). A subcommand that can only ever
404 is worse than no subcommand, so remove it end to end:

- drop the `Feedback` clap variant, its handler, and its update-check arm
- drop the `feedback` branches from the direct-HTTP and daemon dispatchers
- drop `DaemonRequest::idempotent()` and `DaemonError::AfterSend`: feedback was
  the only non-idempotent command, so every daemon failure is now safe to retry
  directly and the before/after-send distinction no longer changes behavior
- delete tests/e2e/test_feedback.py plus the `write_feedback` opt-in gate, the
  daemon-path feedback test, and the KEENABLE_E2E_WRITE_FEEDBACK note in CI
- update CLAUDE.md

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

Remove keenable feedback command and simplify daemon retry semantics

✨ Enhancement 🐞 Bug fix 🧪 Tests 📝 Documentation ⚙️ Configuration changes 🕐 20-40 Minutes

Grey Divider

AI Description

• Remove the feedback subcommand end-to-end because the backend endpoint now 404s.
• Simplify daemon error/retry handling since all remaining commands are read-only.
• Delete/update e2e tests, CI notes, and docs that referenced feedback submissions.
Diagram

graph TD
  cli["CLI (main.rs)"] --> handlers["Search/Fetch handlers"] --> daemon(["Background daemon"]) --> api{{"Keenable API"}}
  handlers --> direct["Direct HTTP path"] --> api
  handlers --> tests["E2E tests"]
  handlers --> docs["Docs / CI"]

  subgraph Legend
    direction LR
    _cli["CLI"] ~~~ _svc(["Service/process"]) ~~~ _ext{{"External"}}
  end
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Keep `feedback` as a deprecated stub
  • ➕ Avoids immediate breaking change for scripts
  • ➕ Can provide a clearer error message than a 404
  • ➖ Still ships a non-functional command and increases maintenance surface
  • ➖ Encourages users to depend on a feature that cannot work
2. Feature-flag `feedback` behind a build flag or hidden command
  • ➕ Keeps code available if the endpoint returns later
  • ➕ Reduces public surface area while preserving internal testing hooks
  • ➖ Adds conditional complexity and code paths to keep compiling
  • ➖ Still requires ongoing upkeep for an effectively dead endpoint

Recommendation: Proceed with full removal as implemented. Given the upstream endpoint is consistently gone (404), keeping a stub or hidden feature adds complexity without restoring functionality. The follow-on daemon simplification (all commands are read-only) is a net maintainability win and removes dead error-path distinctions.

Files changed (8) +19 / -177

Enhancement (3) +10 / -148
search.rsDelete feedback command implementation and HTTP dispatch branch +3/-80

Delete feedback command implementation and HTTP dispatch branch

• Removes the 'feedback()' CLI command and its request construction/validation logic. Deletes the direct-HTTP dispatcher branch for 'feedback' and simplifies daemon fallback handling now that all remaining operations are safe to retry.

src/commands/search.rs

daemon.rsRemove non-idempotent request handling and feedback proxying +6/-37

Remove non-idempotent request handling and feedback proxying

• Deletes 'DaemonRequest::idempotent()' and the 'DaemonError::AfterSend' variant, reflecting that only read-only commands remain. Removes the daemon's 'feedback' routing and simplifies response-read timeout/error mapping to a single retryable failure mode.

src/daemon.rs

main.rsRemove clap 'Feedback' subcommand and dispatch logic +1/-31

Remove clap 'Feedback' subcommand and dispatch logic

• Drops the 'Feedback' command variant, help text, and handler invocation. Updates update-check gating logic to only consider 'search' and 'fetch' for human-facing output.

src/main.rs

Tests (3) +4 / -21
conftest.pyRemove feedback opt-in marker and adjust fixture docs +2/-10

Remove feedback opt-in marker and adjust fixture docs

• Deletes the 'write_feedback' skip marker and its environment-variable gate. Updates the 'basic_search' fixture docstring to remove feedback references.

tests/e2e/conftest.py

test_global.pyStop asserting 'feedback' appears in '--help' output +1/-1

Stop asserting 'feedback' appears in '--help' output

• Updates the subcommand list asserted by the global help test to remove 'feedback'.

tests/e2e/test_global.py

test_login_flow.pyRemove daemon-path feedback test and related imports +1/-10

Remove daemon-path feedback test and related imports

• Updates the module docstring to reflect only search/fetch daemon coverage. Removes the feedback-via-daemon test and the 'write_feedback' import dependency.

tests/e2e/test_login_flow.py

Documentation (1) +5 / -5
CLAUDE.mdUpdate docs to remove feedback references +5/-5

Update docs to remove feedback references

• Removes mentions of the feedback command from the repo overview and CLI behavior sections. Updates endpoint examples to only cover search/fetch public routes.

CLAUDE.md

Other (1) +0 / -3
e2e.ymlRemove CI note about feedback opt-in env var +0/-3

Remove CI note about feedback opt-in env var

• Deletes comments referencing KEENABLE_E2E_WRITE_FEEDBACK since feedback tests no longer exist. Keeps the e2e workflow behavior unchanged.

.github/workflows/e2e.yml

@qodo-code-review

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Tip of the day
💡 Did you know, you can type 'qodo, fix this' on a finding and the fix lands right on your PR

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

@ilya-bogin-keenable
ilya-bogin-keenable merged commit a74f9cf into main Aug 13, 2026
12 checks passed
@ilya-bogin-keenable
ilya-bogin-keenable deleted the remove-feedback-command branch August 13, 2026 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant