Skip to content
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

refactor(backend): better error handling in backend #277

Merged
merged 7 commits into from
Nov 10, 2023

Conversation

Piv94165
Copy link
Contributor

@Piv94165 Piv94165 commented Nov 2, 2023

Add specific messages if Github settings were not added and change some status codes in backend

What

Some errors raised by backend have a 500 status code intead of having 4XX error.
For example, if a developer forgets to add a Personal Access Token and wants to import a project to edit, the server throws a 500 error instead of 400 error.

Screenshot

image

Fixes bug(s)

Part of

  • backend/editor

@Piv94165 Piv94165 requested a review from a team as a code owner November 2, 2023 14:05
@Piv94165 Piv94165 changed the title Refactor/better error handling in backend Refactor(backend): better error handling in backend Nov 2, 2023
@Piv94165 Piv94165 changed the title Refactor(backend): better error handling in backend refactor(backend): better error handling in backend Nov 2, 2023
@Piv94165 Piv94165 force-pushed the refactor/better-error-handling-backend branch from 7cd6482 to 0d76858 Compare November 2, 2023 14:12
Copy link
Contributor

@eric-nguyen-cs eric-nguyen-cs left a comment

Choose a reason for hiding this comment

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

Some few nits but otherwise LGTM

backend/editor/api.py Outdated Show resolved Hide resolved
backend/editor/api.py Outdated Show resolved Hide resolved
backend/editor/api.py Outdated Show resolved Hide resolved
backend/editor/github_functions.py Outdated Show resolved Hide resolved
Copy link
Member

@alexgarel alexgarel left a comment

Choose a reason for hiding this comment

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

LGTM

@alexgarel alexgarel merged commit af9e1f3 into main Nov 10, 2023
7 checks passed
@alexgarel alexgarel deleted the refactor/better-error-handling-backend branch November 10, 2023 14:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

3 participants