Skip to content

Conversation

@jasononaquest
Copy link
Contributor

@jasononaquest jasononaquest commented Aug 14, 2025

fix: W-19078504 - misleading error message in ai:models:info command

Problem

When users ran heroku ai:models:info -a nonexistent-app, they received a confusing error message:

Error: The add-on was unable to be destroyed: Couldn't find that app.

Root Cause

The ai:models:info command used a custom wrapper function (app_addons.ts) that added unnecessary error message context. The wrapper was only used in one place and provided inferior error messages compared to the default Heroku API client.

Solution

  • Removed the unnecessary app_addons.ts wrapper function and its tests
  • Updated ai:models:info to call the Heroku API directly
  • Added test coverage for the new error behavior

Result

Users now see clean, direct error messages:

Couldn't find that app.

Error ID: not_found

@jasononaquest jasononaquest requested a review from a team as a code owner August 14, 2025 00:30
Copy link
Contributor

@k80bowman k80bowman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for fixing this!

@jasononaquest jasononaquest merged commit 0a86137 into main Aug 14, 2025
6 checks passed
@jasononaquest jasononaquest deleted the fix/correct-error-message-when-no-app branch August 14, 2025 16:17
@jasononaquest jasononaquest changed the title Corrects error message when app not found fix: W-19078504 - misleading error message in ai:models:info command Aug 14, 2025
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.

2 participants