-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
replace pkg/errors with stdlib errors #484
Conversation
Codecov Report
@@ Coverage Diff @@
## main #484 +/- ##
==========================================
+ Coverage 66.27% 66.30% +0.03%
==========================================
Files 42 42
Lines 3644 3642 -2
==========================================
Hits 2415 2415
+ Misses 1056 1054 -2
Partials 173 173
Continue to review full report at Codecov.
|
do they both return a string? sorry not super familiar with the libs just want to make sure we are not losing any behavior |
Both of them will return an interface of type The only major functional difference between the two libs are that pkg/errors support error stack trace which isn't present in stdlib errors, but that's something which we anyways don't use it in CLI. Found a decent blog post illustrating that: https://blog.dharnitski.com/2019/09/09/go-errors-are-not-pkg-errors/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
well done!
…ion for houston methods) (#490) * create client interface and implementation for houston methods * update controller packages to use new houston client * update cmds and main to use new houston client * change houston variable visiblity * fix linter, rename methods * moved away from pkg/errors (#484) * astro-cli should prompt the user for namespace name input when pre-deployment validation is configured (#487) * based on pre-deployment validation config, user should be prompted for k8 namespace name to be enter instead of select from available k8 namespaces * added test cases for NamespaceFreeformEntry (Pre-Deployment validation webhook) * fixed broken test cases for namespaceFreeformEntry * fixed broken test cases * updated ErrKubernetesNamespaceNotSpecified message changes create client interface and implementation for houston methods fix linter, rename methods * fix airflow upgrade * fix test and add mocks for houston client w/ mockery * fix houston request errors add proper json tags * rename methods according to code review * fix new log_tests, use renamed houston newClient method * deploy test: add assertions on the houston mock client * move houston mocks to houston directory * add tests for houston package Co-authored-by: Neel Dalsania <92356010+neel-astro@users.noreply.github.com> Co-authored-by: Aj <ajayy101@gmail.com>
* create client interface and implementation for houston methods * change houston variable visiblity * fix linter, rename methods * moved away from pkg/errors (#484) * astro-cli should prompt the user for namespace name input when pre-deployment validation is configured (#487) * based on pre-deployment validation config, user should be prompted for k8 namespace name to be enter instead of select from available k8 namespaces * added test cases for NamespaceFreeformEntry (Pre-Deployment validation webhook) * fixed broken test cases for namespaceFreeformEntry * fixed broken test cases * updated ErrKubernetesNamespaceNotSpecified message changes create client interface and implementation for houston methods fix linter, rename methods * fix test and add mocks for houston client w/ mockery * rename methods according to code review * move houston mocks to houston directory * refactor tests to use houston client mock * rename mocks package to use houston_mocks Co-authored-by: Neel Dalsania <92356010+neel-astro@users.noreply.github.com> Co-authored-by: Aj <ajayy101@gmail.com>
Description
Changes:
🎟 Issue(s)
Related astronomer/issues#3965
🧪 Functional Testing
📸 Screenshots
📋 Checklist
make test
before taking out of draft