-
Notifications
You must be signed in to change notification settings - Fork 26
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
feat: Add rejectNetworkError to API calls (part four) #3768
feat: Add rejectNetworkError to API calls (part four) #3768
Conversation
Bundle ReportChanges will increase total bundle size by 208 bytes (0.0%) ⬆️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: gazebo-production-systemAssets Changed:
Files in
Files in
Files in
view changes for bundle: gazebo-production-esmAssets Changed:
Files in
Files in
Files in
|
Bundle ReportChanges will increase total bundle size by 208 bytes (0.0%) ⬆️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: gazebo-staging-systemAssets Changed:
Files in
Files in
Files in
view changes for bundle: gazebo-staging-esmAssets Changed:
Files in
Files in
Files in
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
✅ All tests successful. No failed tests found. @@ Coverage Diff @@
## main #3768 +/- ##
==========================================
+ Coverage 98.68% 98.69% +0.01%
==========================================
Files 825 825
Lines 14832 14826 -6
Branches 4250 4242 -8
==========================================
- Hits 14637 14633 -4
+ Misses 188 186 -2
Partials 7 7
... and 13 files with indirect coverage changes
Continue to review full report in Codecov by Sentry.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅ ✅ All tests successful. No failed tests found. @@ Coverage Diff @@
## main #3768 +/- ##
==========================================
+ Coverage 98.68% 98.69% +0.01%
==========================================
Files 825 825
Lines 14832 14826 -6
Branches 4250 4242 -8
==========================================
- Hits 14637 14633 -4
+ Misses 188 186 -2
Partials 7 7
... and 13 files with indirect coverage changes
Continue to review full report in Codecov by Sentry.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
✅ All tests successful. No failed tests found. Additional details and impacted files@@ Coverage Diff @@
## main #3768 +/- ##
==========================================
+ Coverage 98.68% 98.69% +0.01%
==========================================
Files 825 825
Lines 14832 14826 -6
Branches 4250 4250
==========================================
- Hits 14637 14633 -4
+ Misses 188 186 -2
Partials 7 7
... and 13 files with indirect coverage changes
Continue to review full report in Codecov by Sentry.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
✅ All tests successful. No failed tests found. @@ Coverage Diff @@
## main #3768 +/- ##
==========================================
+ Coverage 98.68% 98.69% +0.01%
==========================================
Files 825 825
Lines 14832 14827 -5
Branches 4242 4242
==========================================
- Hits 14637 14634 -3
+ Misses 188 186 -2
Partials 7 7
Continue to review full report in Codecov by Sentry.
|
return rejectNetworkError({ | ||
errorName: 'Parsing Error', | ||
errorDetails: { | ||
callingFn: 'fetchRepoSettingsDetails', |
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.
General comment -> What do we think about making this a const so we don't accidentally misspell it for one of these rejectNetworkError calls?
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.
Just playing around with this a bit, instead I think we can actually use the function definition, and the name
property from it. That way it's typesafe as we're accessing properties off of the function declaration and no magic strings. Sadly there's no way to infer this from the calling function.
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.
Actually nvm, that won't work. Minification will change the function names and in turn the name
property on the function. This would probably also prevent us from trying to magically infer the name as well.
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.
Yea we can do that, however I'll do that in a follow up PR and adjust the previous changes that I have already made, and continue with this going forward.
Description
This PR is part four in a series going through Gazebo updating our API calls to utilize
rejectNetworkError
in functions where we call the API.Ticket: codecov/engineering-team#3329
Notable Changes
rejectNetworkError
(see commits)