ujjwalm29 / social-scheduler

Full fledged, feature rich social media scheduler with support for teams and collaboration
0 stars 0 forks source link

Add error handling #2

Open ujjwalm29 opened 10 months ago

ujjwalm29 commented 10 months ago

I've added error handling here and there in the backend but it isn't sufficient enough for a production app. All kinds of validation like users can't sign up twice, projects and content should be uniquely named etc.

As far as I know, this is how it should work :

Catch the error, raise a custom exception, catch the exception, throw valid HTTP error + log the error

ujjwalm29 commented 10 months ago

This is super important in the send invite part. If the send_email fails due to some reason, the state in the db needs to change to "failed" or something and API needs to respond correctly