Skip to content

Conversation

@stainless-app
Copy link
Contributor

@stainless-app stainless-app bot commented May 8, 2025

Automated Release PR

7.0.0 (2025-05-16)

Full Changelog: v6.0.0...v7.0.0

⚠ BREAKING CHANGES

  • client: extract auto pagination to shared classes
  • client: Migration: - If you were referencing the AutoPager class on a specific *Page or *PageAsync type, then you should instead reference the shared AutoPager and AutoPagerAsync types, under the core package
    • AutoPagerAsync now has different usage. You can call .subscribe(...) on the returned object instead to get called back each page item. You can also call onCompleteFuture() to get a future that completes when all items have been processed. Finally, you can call .close() on the returned object to stop auto-paginating early
    • If you were referencing getNextPage or getNextPageParams:
      • Swap to nextPage() and nextPageParams()
      • Note that these both now return non-optional types (use hasNextPage() before calling these, since they will throw if it's impossible to get another page)

Features

  • api: api update (f226da9)
  • api: api update (7932861)
  • api: api update (17bd5c1)
  • client: allow providing some params positionally (ec6fa40)
  • client: extract auto pagination to shared classes (c4a8874)

This pull request is managed by Stainless's GitHub App.

The semver version number is based on included commit messages. Alternatively, you can manually set the version number in the title of this pull request.

For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request.

🔗 Stainless website
📚 Read the docs
🙋 Reach out for help or questions

@stainless-app stainless-app bot requested a review from a team as a code owner May 8, 2025 22:09
refactor(client)!: refactor async auto-pagination
refactor(client)!: rename `getNextPage{,Params}` to `nextPage{,Params}`
refactor(client)!: swap `nextPage{,Params}` to return non-optional

# Migration

- If you were referencing the `AutoPager` class on a specific `*Page` or `*PageAsync` type, then you should instead reference the shared `AutoPager` and `AutoPagerAsync` types, under the `core` package
- `AutoPagerAsync` now has different usage. You can call `.subscribe(...)` on the returned object instead to get called back each page item. You can also call `onCompleteFuture()` to get a future that completes when all items have been processed. Finally, you can call `.close()` on the returned object to stop auto-paginating early
- If you were referencing `getNextPage` or `getNextPageParams`:
   - Swap to `nextPage()` and `nextPageParams()`
   - Note that these both now return non-optional types (use `hasNextPage()` before calling these, since they will throw if it's impossible to get another page)

There are examples and further information about pagination in the readme.
@stainless-app stainless-app bot force-pushed the release-please--branches--main--changes--next branch from c28a197 to c4a8874 Compare May 8, 2025 23:52
@stainless-app stainless-app bot changed the title release: 6.1.0 release: 7.0.0 May 8, 2025
@stainless-app stainless-app bot force-pushed the release-please--branches--main--changes--next branch from e3bc769 to c4a8874 Compare May 8, 2025 23:52
@stainless-app stainless-app bot force-pushed the release-please--branches--main--changes--next branch from 55a0cb8 to 17bd5c1 Compare May 15, 2025 20:40
@stainless-app stainless-app bot force-pushed the release-please--branches--main--changes--next branch from fdd647d to 7932861 Compare May 15, 2025 21:43
@stainless-app stainless-app bot force-pushed the release-please--branches--main--changes--next branch from 2319afd to f226da9 Compare May 16, 2025 04:52
@jordanbrauer jordanbrauer merged commit 5737bc6 into main May 16, 2025
3 checks passed
@jordanbrauer jordanbrauer deleted the release-please--branches--main--changes--next branch May 16, 2025 16:07
@stainless-app
Copy link
Contributor Author

stainless-app bot commented May 16, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant