Skip to content

Conversation

@zhao-oai
Copy link
Collaborator

@zhao-oai zhao-oai commented Dec 2, 2025

in response to incoming changes to responses headers where the header may sometimes not contain credits info (no longer forcing a credit check)


pub(crate) fn set_rate_limits(&mut self, snapshot: RateLimitSnapshot) {
self.latest_rate_limits = Some(snapshot);
self.latest_rate_limits = Some(merge_rate_limit_credits(
Copy link
Collaborator

Choose a reason for hiding this comment

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

can we start writing tests against this logic?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

sorry just added a test for this

@zhao-oai zhao-oai requested a review from pakrym-oai December 2, 2025 18:48
@zhao-oai zhao-oai merged commit 5ebdc9a into main Dec 2, 2025
26 checks passed
@zhao-oai zhao-oai deleted the dev/zhao/persist-credits branch December 2, 2025 21:23
@github-actions github-actions bot locked and limited conversation to collaborators Dec 2, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants