Repository navigation
Improved error handling for expeye posts - #960
Open
stephen-riggs wants to merge 4 commits into
Open
stephen-riggs wants to merge 4 commits into
stephen-riggs wants to merge 4 commits into
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #960 +/- ##
==========================================
- Coverage 56.39% 56.30% -0.09%
==========================================
Files 106 106
Lines 12153 12174 +21
Branches 1653 1658 +5
==========================================
+ Hits 6854 6855 +1
- Misses 4912 4931 +19
- Partials 387 388 +1 🚀 New features to boost your workflow:
|
tieneupin
reviewed
Dec 3, 2026
| except json.JSONDecodeError: | ||
| logger.error("Expeye json decode failed") | ||
| return None | ||
| if not result.get("atlasId"): |
Contributor
There was a problem hiding this comment.
I don't think it's going to happen in production, but technically, this would fail if atlasId was 0. You'd want if result.get("atlasId") is None: instead.
tieneupin
reviewed
Dec 3, 2026
Comment on lines
80
to
+81
| return None | ||
| return result["atlasId"] |
Contributor
There was a problem hiding this comment.
Technically, you can just assign results.get("atlasId") to a variable and return it once at the end. No need for the separate return None.
if (atlas_id := result.get("atlasId")) is None:
logger.error(f"Expeye atlas insert failed with {results}")
return atlas_id
tieneupin
reviewed
Dec 3, 2026
Comment on lines
+55
to
+58
| if not result.get("atlasId"): | ||
| logger.error(f"Expeye atlas insert failed with {result}") | ||
| return None | ||
| return result["atlasId"] |
Contributor
There was a problem hiding this comment.
Same here:
if (atlas_id := result.get("atlasId")) is None:
logger.error(f"Expeye atlas insert failed with {results}")
return atlas_id
tieneupin
approved these changes
Dec 3, 2026
tieneupin
left a comment
Contributor
There was a problem hiding this comment.
Looks fine, as far as I can tell!
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Various edits to make the expeye posts work properly and also to handle exceptions if the posts fail: