fix: review_rate_limits unusable in Cloud OAuth mode - #199
Closed
zzstoatzz wants to merge 1 commit into
Closed
Conversation
The tool errored with 'workspace_id is required when using Prefect Cloud OAuth mode' but its input schema had no workspace_id parameter, making it impossible to call. Thread workspace_id from the tool through get_rate_limits to both client factories. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
this PR adds a
workspace_idparameter toreview_rate_limits— in Cloud OAuth mode the tool errored withworkspace_id is required when using Prefect Cloud OAuth mode, but its input schema had noworkspace_idparameter, so it was impossible to call.details
workspace_idfrom the tool throughget_rate_limitsto bothget_prefect_clientandget_prefect_cloud_clientworkspace_id, and the tool's input schema exposes it/accounts/{account_id}/rate-limits/usageis an account-level path — I haven't been able to verify whether workspace-scoped OAuth tokens are authorized for it, so OAuth-mode calls may still be rejected server-side even with this fix. this at least makes the tool callable and surfaces the real answer🤖 Generated with Claude Code