refactor: rename preview terminology to free tier cloud - #52
Merged
Conversation
Replace preview-client wording with free tier cloud across the SDK, docs, and tests. Rename JUDGE0_SUPPRESS_PREVIEW_WARNING to JUDGE0_SUPPRESS_FREE_TIER_CLOUD_WARNING and PreviewClientLimitError to FreeTierCloudClientLimitError. Closes #45
Signed-off-by: Filip Karlo Došilović <filipk.dosilovic@gmail.com>
6 tasks
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.
Summary
JUDGE0_SUPPRESS_PREVIEW_WARNINGtoJUDGE0_SUPPRESS_FREE_TIER_CLOUD_WARNING.PreviewClientLimitErrortoFreeTierCloudClientLimitError._get_preview_clientand the rate-limit decorator to the matching free-tier-cloud names.Same commits as #46, opened from
judge0/judge0-pythonsoTest judge0-pythoncan receive repository secrets.Motivation
Closes #45
The unauthenticated Judge0 Cloud fallback is the free tier, not a preview client. The old wording is incorrect in user-facing warnings, docs, and the suppression env var.
Changes
src/judge0/__init__.py: env var, warning flag, fallback helper, and warning textsrc/judge0/api.py:get_clientdocstringsrc/judge0/errors.py: exception renamesrc/judge0/utils.py: decorator and rate-limit error textsrc/judge0/clients.py: decorator import and 9 usagestests/conftest.py: fixture namestests/test_free_tier_cloud.py: unit coverage for the new error type and removed preview namesdocs/source/in_depth/client_resolution.rst,AGENTS.md,CHANGELOG.mdNo compatibility alias is added. The package is
0.1.0.dev0, and the issue accepts a direct rename.PreviewClientLimitErrorwas not exported from__all__.Test Plan
uv run pytest testson this branch: 96 passedTest judge0-pythonon this same-repo PR (liveJUDGE0_*secrets)Notes for Reviewers
This is a breaking rename of the warning env var and the limit error class. No temporary alias for
JUDGE0_SUPPRESS_PREVIEW_WARNINGwas added.Fork PR: #46