Skip to content

Conversation

@mcollina
Copy link
Member

Summary

  • Remove deprecated maxRedirections option from TypeScript type definitions
  • Update type tests to remove usage of the deprecated option
  • Preserve maxRedirections in redirect interceptor where it's still valid

Test plan

  • TypeScript type checking tests pass (npm run test:typescript)
  • Linting passes (npm run lint)
  • All references to maxRedirections removed from public API types
  • Redirect interceptor functionality preserved

🤖 Generated with Claude Code

The maxRedirections option was removed in v7 but still remained in
TypeScript type definitions. This removes it from:

- Agent.Options and Agent.DispatchOptions
- Dispatcher ConnectOptions, RequestOptions, and UpgradeOptions
- Client.Options and H2CClient.Options
- MockInterceptor.MockResponseCallbackOptions

Also updates corresponding type tests to remove usage of the
deprecated option. The redirect interceptor still supports
maxRedirections as that functionality remains available.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Matteo Collina <hello@matteocollina.com>
@mcollina mcollina requested review from Uzlopak and metcoder95 July 28, 2025 20:04
Copy link
Member

@metcoder95 metcoder95 left a comment

Choose a reason for hiding this comment

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

lgtm, some nits left

Signed-off-by: Matteo Collina <hello@matteocollina.com>
@mcollina
Copy link
Member Author

@metcoder95 good spot!

@mcollina mcollina merged commit 567a589 into main Jul 30, 2025
33 checks passed
@github-actions github-actions bot mentioned this pull request Jul 31, 2025
@JoshMock JoshMock mentioned this pull request Aug 7, 2025
@Uzlopak Uzlopak deleted the maxredirectiontypes branch August 14, 2025 07:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants