Skip to content

refactor: standardize error handling#422

Merged
pkoprda merged 1 commit into
mainfrom
pschrimp/standardize_error_handling
May 14, 2026
Merged

refactor: standardize error handling#422
pkoprda merged 1 commit into
mainfrom
pschrimp/standardize_error_handling

Conversation

@Peto-RH
Copy link
Copy Markdown
Contributor

@Peto-RH Peto-RH commented Apr 23, 2026

CardID: CCT-2168

Replaced magic number exit codes with named constants and normalized error message formatting.

@Peto-RH Peto-RH force-pushed the pschrimp/standardize_error_handling branch from 298cdd3 to 27c88ee Compare April 23, 2026 15:45
@Peto-RH
Copy link
Copy Markdown
Contributor Author

Peto-RH commented Apr 23, 2026

Note for reviewer:
It might make more sense having error constants file directly in /cmd dir since rhc and rhc-collector and rhc-server share those constants

@Peto-RH Peto-RH marked this pull request as ready for review April 23, 2026 15:59
@Peto-RH Peto-RH requested a review from pkoprda April 23, 2026 16:00
@Peto-RH Peto-RH force-pushed the pschrimp/standardize_error_handling branch from 0deda7d to 27c88ee Compare April 29, 2026 09:15
Copy link
Copy Markdown
Contributor

@pkoprda pkoprda left a comment

Choose a reason for hiding this comment

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

There are still some pending error: prefixes in cmd/rhc/connect_cmd.go (probably re-introduced by #416) and also server error: prefix in cmd/rhc-server/main.go.

Comment thread cmd/rhc-collector/main.go Outdated
@Peto-RH Peto-RH force-pushed the pschrimp/standardize_error_handling branch 5 times, most recently from 05fa2ee to 0c6cc00 Compare May 14, 2026 09:19
CardID: CCT-2168

Replaced magic number exit codes with named constants and
normalized error message formatting.
@Peto-RH Peto-RH force-pushed the pschrimp/standardize_error_handling branch from 0c6cc00 to 116b35a Compare May 14, 2026 09:19
Copy link
Copy Markdown
Contributor

@pkoprda pkoprda left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@pkoprda pkoprda merged commit af1791e into main May 14, 2026
21 checks passed
@pkoprda pkoprda deleted the pschrimp/standardize_error_handling branch May 14, 2026 10:22
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