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

Remove all mutation of arguments from query_registry_db_with_search_after() #133

Open
alexdunnjpl opened this issue Aug 26, 2024 · 0 comments
Assignees
Labels
B15.0 i&t.skip Skip I&T of this task/ticket task

Comments

@alexdunnjpl
Copy link
Contributor

alexdunnjpl commented Aug 26, 2024

💡 Description

  1. query dict is constructed for dedicated use by a function call
  2. query dict needs to be reused later, ex. by get_query_hits_count()
  3. now you're getting weird errors about "sort must have n values" because a search-after value was mutated into the object you thought was just a clean copy of the query

Side-effect mutation is bad, m'kay?

Current bandaid is to return the dict from a function instead of instantiating it ahead of time, so it's fresh each time, but doing that is how I ended up chasing my tail a second time.

⚔️ Parent Epic / Related Tickets

No response

@alexdunnjpl alexdunnjpl added B15.0 i&t.skip Skip I&T of this task/ticket task labels Aug 26, 2024
@alexdunnjpl alexdunnjpl self-assigned this Aug 26, 2024
@github-project-automation github-project-automation bot moved this to Release Backlog in B15.0 Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B15.0 i&t.skip Skip I&T of this task/ticket task
Projects
Status: Release Backlog
Development

No branches or pull requests

1 participant