Skip to content
This repository has been archived by the owner on Sep 18, 2024. It is now read-only.

[Issue #178] Finish connecting new search parameters to backend queries #197

Merged
merged 11 commits into from
Sep 13, 2024

Conversation

chouinar
Copy link
Collaborator

Summary

Fixes #178

Time to review: 10 mins

Changes proposed

Adjusted the logic that connects the API requests to the builder in the search layer to now connect all of the new fields.

A few minor validation adjustments to the API to prevent a few common mistakes a user could make

Context for reviewers

The length of the search tests are getting pretty long, I think a good follow-up would be to split the test file into validation and response testing.

I adjusted some validation/setup of the API schemas because I don't see a scenario where min/max OR start/end dates would not ever be needed together. This also let me add a quick validation rule that a user would provide at least one of the values.

I adjusted some of the way the search_opportunities file was structured as we only supported filtering by strings before, and it used the name of the variables to determine the type. I made it a bit more explicit, as before random variables could be passed through to the search layer which seems potentially problematic if not filtered out somewhere.

@chouinar chouinar merged commit 4b0bd5b into main Sep 13, 2024
8 checks passed
@chouinar chouinar deleted the chouinar/connect-search branch September 13, 2024 17:10
acouch pushed a commit that referenced this pull request Sep 18, 2024
…ueries (#197)

Fixes HHS#2039

Adjusted the logic that connects the API requests to the builder in the
search layer to now connect all of the new fields.

A few minor validation adjustments to the API to prevent a few common
mistakes a user could make

The length of the search tests are getting pretty long, I think a good
follow-up would be to split the test file into validation and response
testing.

I adjusted some validation/setup of the API schemas because I don't see
a scenario where min/max OR start/end dates would not ever be needed
together. This also let me add a quick validation rule that a user would
provide at least one of the values.

I adjusted some of the way the search_opportunities file was structured
as we only supported filtering by strings before, and it used the name
of the variables to determine the type. I made it a bit more explicit,
as before random variables could be passed through to the search layer
which seems potentially problematic if not filtered out somewhere.
acouch pushed a commit that referenced this pull request Sep 18, 2024
…ueries (#197)

Fixes HHS#2039

Adjusted the logic that connects the API requests to the builder in the
search layer to now connect all of the new fields.

A few minor validation adjustments to the API to prevent a few common
mistakes a user could make

The length of the search tests are getting pretty long, I think a good
follow-up would be to split the test file into validation and response
testing.

I adjusted some validation/setup of the API schemas because I don't see
a scenario where min/max OR start/end dates would not ever be needed
together. This also let me add a quick validation rule that a user would
provide at least one of the values.

I adjusted some of the way the search_opportunities file was structured
as we only supported filtering by strings before, and it used the name
of the variables to determine the type. I made it a bit more explicit,
as before random variables could be passed through to the search layer
which seems potentially problematic if not filtered out somewhere.
acouch pushed a commit to HHS/simpler-grants-gov that referenced this pull request Sep 18, 2024
…ies (navapbc#197)

Fixes #2039

Adjusted the logic that connects the API requests to the builder in the
search layer to now connect all of the new fields.

A few minor validation adjustments to the API to prevent a few common
mistakes a user could make

The length of the search tests are getting pretty long, I think a good
follow-up would be to split the test file into validation and response
testing.

I adjusted some validation/setup of the API schemas because I don't see
a scenario where min/max OR start/end dates would not ever be needed
together. This also let me add a quick validation rule that a user would
provide at least one of the values.

I adjusted some of the way the search_opportunities file was structured
as we only supported filtering by strings before, and it used the name
of the variables to determine the type. I made it a bit more explicit,
as before random variables could be passed through to the search layer
which seems potentially problematic if not filtered out somewhere.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Task]: Modify opportunity v1 search implementation to support filtering by post/close date ranges
2 participants