-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Add error codes to API #4676
Add error codes to API #4676
Conversation
afc70bc
to
d2b7fdf
Compare
I did the first review and I think we have to look through the codes and think whether we can unify/generalize some of them. Another question is whether we need to start exposing them all at once. Maybe a better idea would be to have dedicated enums for each group e.g. |
91fca66
to
43625e6
Compare
Here is the report for 702e735 (mirumee/saleor @ add-error-codes-in-api) No differences were found. (click me)
# api.benchmark checkout
test name left count right count duplicate count
------------------------------------ ----------- ----------- ---------------
add billing address to checkout 34 34 20
add shipping to checkout 7 7 0
checkout payment charge 14 14 0
complete checkout 6 6 0
create checkout 48 48 24
# api.benchmark homepage
test name left count right count duplicate count
------------------------------------ ----------- ----------- ---------------
retrieve main menu 5 5 0
retrieve product list 4 4 0
retrieve secondary menu 5 5 0
retrieve shop 2 2 0
# api.benchmark product
test name left count right count duplicate count
------------------------------------ ----------- ----------- ---------------
product details 15 15 3
# api.benchmark variant
test name left count right count duplicate count
------------------------------------ ----------- ----------- ---------------
retrieve variant list 18 18 8 |
Codecov Report
@@ Coverage Diff @@
## master #4676 +/- ##
==========================================
+ Coverage 91.41% 91.49% +0.07%
==========================================
Files 307 308 +1
Lines 18445 18572 +127
Branches 1844 1848 +4
==========================================
+ Hits 16862 16992 +130
+ Misses 1065 1063 -2
+ Partials 518 517 -1
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #4676 +/- ##
==========================================
+ Coverage 91.67% 91.96% +0.28%
==========================================
Files 313 324 +11
Lines 18855 19491 +636
Branches 1851 1863 +12
==========================================
+ Hits 17286 17925 +639
+ Misses 1049 1047 -2
+ Partials 520 519 -1
Continue to review full report at Codecov.
|
Can we plan a meeting where we go through all of these codes and determine whether they are correct or even needed? |
679b223
to
57e93a8
Compare
@patrys @maarcingebala I've created typed versions of |
dc4cfb9
to
1d0a908
Compare
@maarcingebala @korycins @NyanKiyoshi @patrys I've changed error code mechanism to use |
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.
❤️
I want to merge this change because it adds error codes for mutation errors.
It closes #4119.
Screenshots
Pull Request Checklist