fedspendingtransparency / usaspending-api

Server application to serve U.S. federal spending data via a RESTful API
https://www.usaspending.gov
Creative Commons Zero v1.0 Universal
309 stars 112 forks source link

[DEV-11287] Update query_with_filters to escape keywords #4147

Closed aguest-kc closed 3 months ago

aguest-kc commented 3 months ago

Description: Escape the Elasticsearch keywords of AND and OR if they are included in the recipient_search_text filter.

Technical details: The technical details for the knowledge of other developers. Any detailed caveats or specific deployment steps should be outlined here.

Requirements for PR merge:

  1. [x] Unit & integration tests updated
  2. [x] Necessary PR reviewers:
    • [x] Backend
  3. [x] Data validation completed
  4. [x] Jira Ticket DEV-11287:
    • [x] Link to this Pull-Request
    • [x] Performance evaluation of affected (API | Script | Download)
    • [x] Before / After data comparison

Area for explaining above N/A when needed:

2. API documentation updated
No API contracts are affected by this change.

4. Matview impact assessment completed
No matviews are affected by this change.

5. Frontend impact assessment completed
The frontend is not affected by this change.

7. Appropriate Operations ticket(s) created
No operations tickets are needed for this change.