Skip to content

feat(templates): add request_options to python helpers consistently #3868

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

Merged
merged 2 commits into from
Oct 2, 2024

Conversation

kai687
Copy link
Contributor

@kai687 kai687 commented Oct 1, 2024

🧭 What and Why

Make the Python helpers more consistent by supporting request_options for all helpers
that are based on chunked_batch.

Changes included:

Add request_options to the following helpers:

  • save_objects
  • delete_objects
  • partial_update_objects

The rest of them already work with request_options.

Also provide dict as accepted type for API key restrictions in generate_secured_api_key, since the function already handles that case.

@algolia-bot
Copy link
Collaborator

algolia-bot commented Oct 1, 2024

✔️ Code generated!

Name Link
🪓 Triggered by c112d9f54b3cb9b834f2f6f96f8283529cad2d7d
🍃 Generated commit a7aac981a37b70e71902e86076d7e04c40b60a94
🌲 Generated branch generated/feat/python-helpers-request-options
📊 Benchmark results

Benchmarks performed on the method using a mock server, the results might not reflect the real-world performance.

Language Req/s
python 1033

@kai687 kai687 changed the title feat(helpers): add request_options to python helpers consistently feat(templates): add request_options to python helpers consistently Oct 1, 2024
@kai687 kai687 marked this pull request as ready for review October 1, 2024 17:07
@kai687 kai687 requested a review from a team as a code owner October 1, 2024 17:07
@kai687 kai687 requested review from morganleroi and millotp October 1, 2024 17:07
Copy link
Contributor

@Fluf22 Fluf22 left a comment

Choose a reason for hiding this comment

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

Thanks for that!
Btw, I'm working on Python typing in general in another pr
I found other issues

@millotp millotp merged commit f377640 into main Oct 2, 2024
17 checks passed
@millotp millotp deleted the feat/python-helpers-request-options branch October 2, 2024 09:01
algolia-bot added a commit that referenced this pull request Oct 2, 2024
algolia-bot added a commit to algolia/algoliasearch-client-python that referenced this pull request Oct 2, 2024
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.

4 participants