Skip to content

Conversation

lunalucadou
Copy link
Contributor

@lunalucadou lunalucadou commented Mar 27, 2025

This MR was previously opened against the DSL project but I was told I should submit it here instead: elastic/elasticsearch-dsl-py#1970

Earlier today I was trying to pass wait_for_completion=True to Search.delete but found Search.delete does not support **kwargs.

I was going to just add support for **kwargs (it would be a fairly trivial change), but after seeing elastic/elasticsearch-dsl-py#1115 and elastic/elasticsearch-dsl-py#1395, it seems the preferred way is to call Search.params first. However, this is not called out in the documentation for Search.delete, so I instead opted to add it to the documentation.

While I was at it, I noticed Search.scan and FacetedSearch.params had broken links so I fixed those as well.

The preferred way of passing parameters to the DSL `Search.delete` appears to be calling `Search.params` first, but this is only ever discussed in GitHub issues like elastic/elasticsearch-dsl-py#1115 and elastic/elasticsearch-dsl-py#1395. To help anyone else who has stumbled across this, I added a note about this to the documentation. I also went ahead and updated the links for the `Search.scan` and `FacetedSearch.params` methods to the most recent versions since they were 404ing.
Copy link

cla-checker-service bot commented Mar 27, 2025

💚 CLA has been signed

@lunalucadou
Copy link
Contributor Author

lunalucadou commented Mar 27, 2025

I have signed the CLA.

@miguelgrinberg miguelgrinberg merged commit b6d1211 into elastic:main Mar 31, 2025
11 checks passed
github-actions bot pushed a commit that referenced this pull request Mar 31, 2025
… links (#2861) * Add param notes to DSL search.delete documentation, fix broken links The preferred way of passing parameters to the DSL `Search.delete` appears to be calling `Search.params` first, but this is only ever discussed in GitHub issues like elastic/elasticsearch-dsl-py#1115 and elastic/elasticsearch-dsl-py#1395. To help anyone else who has stumbled across this, I added a note about this to the documentation. I also went ahead and updated the links for the `Search.scan` and `FacetedSearch.params` methods to the most recent versions since they were 404ing. * make sync and async changes the same --------- Co-authored-by: Luna Lucadou <LUNA.LUCADOU@users.noreply.git.doit.wisc.edu> Co-authored-by: Miguel Grinberg <miguel.grinberg@gmail.com> (cherry picked from commit b6d1211)
@miguelgrinberg
Copy link
Contributor

Thanks @lunalucadou !

miguelgrinberg pushed a commit that referenced this pull request Apr 1, 2025
… links (#2861) (#2869) * Add param notes to DSL search.delete documentation, fix broken links The preferred way of passing parameters to the DSL `Search.delete` appears to be calling `Search.params` first, but this is only ever discussed in GitHub issues like elastic/elasticsearch-dsl-py#1115 and elastic/elasticsearch-dsl-py#1395. To help anyone else who has stumbled across this, I added a note about this to the documentation. I also went ahead and updated the links for the `Search.scan` and `FacetedSearch.params` methods to the most recent versions since they were 404ing. * make sync and async changes the same --------- Co-authored-by: Luna Lucadou <LUNA.LUCADOU@users.noreply.git.doit.wisc.edu> Co-authored-by: Miguel Grinberg <miguel.grinberg@gmail.com> (cherry picked from commit b6d1211) Co-authored-by: Luna Lucadou <22415965+lunalucadou@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

2 participants