Skip to content

CLI: report clear error when inspect finds no feed and add spec - #156

Merged
id774 merged 1 commit into
masterfrom
codex
Aug 19, 2026
Merged

CLI: report clear error when inspect finds no feed and add spec#156
id774 merged 1 commit into
masterfrom
codex

Conversation

@id774

@id774 id774 commented Aug 19, 2026

Copy link
Copy Markdown
Owner

Motivation

  • The inspect subcommand currently raises an internal exception when feed autodiscovery returns no feeds, which is not friendly for CLI users.

Description

  • Make inspect_url raise Automatic::Error with a clear message when Feedbag.find returns an empty list by adding raise Automatic::Error, "no feed found at #{url}" if feeds.empty?.
  • Add a spec in spec/lib/automatic/cli_spec.rb that stubs Feedbag.find to return [] and asserts the command returns EXIT_FAILURE, emits the expected error text, and produces no stdout.
  • Update doc/VERSIONS to document the new behavior and bump file header update timestamps in the modified source and spec files.

Testing

  • Ran rspec spec/lib/automatic/cli_spec.rb and the suite containing the new inspect test passed successfully.

Codex Task

@id774
id774 merged commit 1a0f268 into master Aug 19, 2026
8 checks passed
@id774
id774 deleted the codex branch August 19, 2026 10:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant