Improve error logging and add user guidance for issue reporting

- Added fatal log in `login.go` for Cloud AI API enablement check failures, prompting users to report issues.
- Enhanced error logging in `client.go` with warning messages directing users to copy and provide error details when creating issues.
This commit is contained in:
Luis Pater
2025-07-24 04:51:09 +08:00
parent 58b7afdf1e
commit ead71fb7ef
2 changed files with 2 additions and 0 deletions

View File

@@ -73,6 +73,7 @@ func DoLogin(cfg *config.Config, projectID string) {
// If the check fails (returns false), the CheckCloudAPIIsEnabled function
// will have already printed instructions, so we can just exit.
if !isChecked {
log.Fatal("Failed to check if Cloud AI API is enabled. If you encounter an error message, please create an issue.")
return
}
}