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

Improve max_results/delay_seconds types, defaults #138

Merged
merged 3 commits into from
Oct 17, 2023

Conversation

lukasschwab
Copy link
Owner

Description

  • Make Search.max_results an int | None.
  • Make Client.delay_seconds a float.
  • Update tests accordingly.

Major refactor of Client.results. It's a matter of taste, but the code is much simpler: use itertools to enforce max_results rather than varying page size.

Breaking changes

List any changes that break the API usage supported on master.

None. Search constructor retains backwards compatibility for float('inf'); other floats were effectively unsupported (broken).

Relevant issues

List GitHub issues relevant to this change.

Checklist

  • (If appropriate) README.md example usage has been updated.

@lukasschwab lukasschwab merged commit adff3d5 into v2.0.0 Oct 17, 2023
5 of 6 checks passed
@lukasschwab lukasschwab deleted the fix-123-int-limit branch October 17, 2023 08:14
lukasschwab added a commit that referenced this pull request Oct 17, 2023
+ Improve `max_results`/`delay_seconds` types, defaults (#138)
+ Eliminate `get`, deprecate `Search.Results` (#137)
+ Accelerate CI integration tests (#140)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant