**Pull Request Title:** Improve Error Handling for External API Failures - Fixes #37 #38
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Description
Title: Improve Error Handling in Application
Issue: #37 - Improve error handling
Overview:
This pull request addresses persistent error handling issues caused by external API failures, specifically those related to authentication errors. The changes made significantly improve the application's resilience by implementing robust error handling throughout the affected modules.
Changes Made:
Enhanced Error Handling in
_get_instance_to_solve
:KeyError
exceptions when accessing nested data.Updates to
get_awarded_proposals
:Refinements in
_send_message
:bool
to facilitate better tracking of success or failure states.Modifications in
solve_instances_handler
:_send_message
, allowing for better flow control based on message send success.Impact:
These changes collectively reduce the likelihood of application crashes due to API errors, making the system more reliable and user-friendly. The application should now handle external API failures gracefully, ensuring a better user experience.
Note: By implementing these enhancements, we are addressing issue #37: Improve error handling.
Fixes: #37
Please review the changes and provide feedback or approval to merge these improvements into the main branch. Thank you!
Fixes #37