Introduce custom error types
@const-cloudinary is already working on this.
Since Feb 9, 2021.
Assessment
This issue has not been assessed yet.
Description
Explain your use case
All the errors from SDK now returns in raw format.
Moreover - they are bubbling up from the very bottom level to the client level.
Describe the problem you’re trying to solve
This errors might be everything - starting from the HTTP errors (can't connect to the server, wrong credentials, smth else) to JSON umarshaling problems.
Does the client really need such verbose level of errors and does he (she) really need to know that we've got some problem during JSON unmarshaling?
Do you have a proposed solution?
- Catch errors before returning to clients
- Introduce some types of errors (internal error, server error, auth error ...)(
- Introduce some interfaces that would help to separate errors by behavior (fatal, retryable, limit exceed) - here is a good article about it https://dave.cheney.net/2016/04/27/dont-just-check-errors-handle-them-gracefully
- Dominant language
- Go
- Stars
- 51
- Forks
- 25
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from cloudinary/cloudinary-go
-
Base64file uploading to cloudinary is not workingMay be free again @AnshShah77 claimed this 1135 days ago, and no pull request is open. Open
Difficulty 3/5 1-2 days Newbie friendliness 30/100
cloudinary/cloudinary-go#82 · 2 comments ·
All issues in cloudinary/cloudinary-go
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
volcano-sh/volcano#6323 ·
Maintainers usually reply within 1 day
-
needs-triage typo
Difficulty 1/5 Under an hour Newbie friendliness 88/100
llm-d-incubation/llm-d-scaling-manager#122 ·
Maintainers usually reply within 1 day
-
good first issue severity: low tech-debt
Difficulty 2/5 Half a day Newbie friendliness 75/100
TMHSDigital/subenum#329 ·
Maintainers usually reply within 1 day
-
[Bug] Backend summarize min() / max() panics when a field has no numeric valuesPossibly taken @weng5e claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
grafana/grafana-infinity-datasource#1832 ·
Maintainers usually reply within 1 day
-
tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day