Skip to content

fix(cli): remove generic "refer to our docs" note from cli errors#4136

Open
anxkhn wants to merge 1 commit into
dlt-hub:develfrom
anxkhn:fix/4126-remove-docs-intro-note
Open

fix(cli): remove generic "refer to our docs" note from cli errors#4136
anxkhn wants to merge 1 commit into
dlt-hub:develfrom
anxkhn:fix/4126-remove-docs-intro-note

Conversation

@anxkhn

@anxkhn anxkhn commented Jun 30, 2026

Copy link
Copy Markdown

Description

The CLI's two generic error handlers always appended:

NOTE: Please refer to our docs at 'https://dlthub.com/docs/intro' for further assistance.

regardless of the actual error, so every failure (e.g. "workspace already exists", invalid args) pointed at the same intro page. As #4126 notes, that is not specific to what the user is facing and clutters the output.

This removes the generic intro-page footer but keeps a docs link when the command or exception provides a specific one:

  • main() parser-ValueError path: footer removed (no command context there); the error line is unchanged.
  • main() catch-all command-error path: drop the DEFAULT_DOCS_URL intro fallback and only emit the note when a command/exception supplies its own docs_url (e.g. dlt telemetry -> the telemetry docs). The real error line (red) is always kept.
  • Removed the now-unused DEFAULT_DOCS_URL constant (no other references).

Out of scope: the deploy command's note (_deploy_command.py:483) is left intact - it points at deploy-specific docs after concrete git init remediation, so it is contextual and useful rather than the generic intro link. Happy to drop it too if you read "all CLI commands" literally.

Related Issues

Additional Context

Tested with tests/workspace/cli/common/test_cli_invoke.py: added test_command_error_omits_generic_docs_note (failing command with no docs link -> error shown, no footer) and test_command_error_keeps_specific_docs_note (command with its own docs_url -> contextual link still shown). Ran tests/workspace/cli + tests/plugins (507 passed) and make lint (ruff / flake8 / black / mypy) clean.

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.

fix(cli): remove NOTE: Please refer to our docs

1 participant