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

Cl/handle search infrastructure exceptions #35

Merged
merged 6 commits into from
Aug 8, 2024

Conversation

CathLass
Copy link
Collaborator

@CathLass CathLass commented Aug 7, 2024

Added and modified tests to better define and test behaviour
Added a response status to the application layer
Some small tidy-ups like adding a models folder which now makes the PR look massive - sorry about that :(

Closed = 0,
Open = 1,
Unknown
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is just a rename from StatusCode - not new code

InvalidRequest,
SearchServiceError,
DataFormatError
}
Copy link
Collaborator Author

@CathLass CathLass Aug 7, 2024

Choose a reason for hiding this comment

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

This is the actual main thing I've added - this response status and the setting of it by the use-case and the mapper

@CathLass CathLass marked this pull request as ready for review August 7, 2024 13:56
Copy link
Member

@RogerHowellDfE RogerHowellDfE left a comment

Choose a reason for hiding this comment

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

With the caveat of my comment about the currently unused SearchResponseStatus.DataFormatError (personally I'd not want to block the PR based just on this unused value) and caution re: I don't quite have a full mental model yet of how everything fits together, it's a ✅ from me 👍

  • the commits seem to follow a logical progression
  • the tests seem to be testing what they say to be testing
  • overall this seems a good/reasonable improvement

A few nitpicky comments if we were to refine the PR (i.e., not anything I'd want to block the PR on):

  • Seems to be a few nullability mismatches floating around (parameters marked as non-nullable then a robust additional runtime check for null causing warnings, and a few places in the tests use ! to override the nullability declarations)
  • Possibly split the PR into refactoring changes (renaming/moving) vs functionality (behaviour) changes?

@CathLass CathLass merged commit 39895e4 into main Aug 8, 2024
1 check passed
@CathLass CathLass deleted the CL/handle-search-infrastructure-exceptions branch September 26, 2024 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants