Fix docs and installed-wheel claim drift - #84
Conversation
📝 WalkthroughWalkthroughThe release updates documentation and package docstrings, expands storefront claim validation to repository and installed-wheel surfaces, and wires installed-artifact checks into the wheel smoke test. The package version and changelog advance to ChangesStorefront and release validation
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant CleanWheelSmoke
participant InstalledWheel
participant ValidateStorefrontClaims
participant PackageMetadata
CleanWheelSmoke->>InstalledWheel: install wheel and locate package root
CleanWheelSmoke->>ValidateStorefrontClaims: run --package-root
ValidateStorefrontClaims->>InstalledWheel: scan installed package sources
ValidateStorefrontClaims->>PackageMetadata: inspect metadata and version
PackageMetadata-->>ValidateStorefrontClaims: return contract and version data
ValidateStorefrontClaims-->>CleanWheelSmoke: report validation result
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@docs/PERFORMANCE_GUIDE.md`:
- Line 347: Update the cache examples around the application-selected bucket and
the Redis example to use the documented source-timestamp freshness policy
consistently: make the freshness interval explicit, include the API/source
timestamp with each cached value, and derive staleness from that timestamp
rather than hard-coded five-minute or commodity-only key behavior. If retaining
five-minute values, clearly label them as illustrative.
In `@docs/TELEMETRY.md`:
- Line 194: Update the telemetry diagram’s “max 10 or 5min” label to reference
the configured batch interval, or explicitly identify five minutes as the
default, keeping it consistent with the configured batch interval described in
step 3.
In `@oilpriceapi/resources/diesel.py`:
- Around line 19-20: Update the get_price and get_stations docstrings to remove
or qualify hard-coded tier, free-access, and monthly station-limit claims,
ensuring both package source and installed documentation describe current
entitlements and rely on response metadata where applicable.
In `@scripts/validate_storefront_claims.py`:
- Around line 131-142: Update the non-package-root success message in main so it
reports the count from discover_public_surfaces() as “public surfaces” rather
than “Python public surfaces”; leave the exact installed artifact message
unchanged.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: e751d152-4522-40aa-abb1-fac76f0ecacb
📒 Files selected for processing (15)
CHANGELOG.mdEXAMPLES.mddocs/PERFORMANCE_GUIDE.mddocs/TELEMETRY.mddocs/index.mdoilpriceapi/async_client.pyoilpriceapi/resources/diesel.pyoilpriceapi/streaming/__init__.pyoilpriceapi/streaming/client.pyoilpriceapi/version.pypyproject.tomlscripts/clean-wheel-smoke.shscripts/validate_storefront_claims.pytests/test_release_readiness.pytests/test_storefront_claims.py
Problem
The claim guard covered only README.md, pyproject.toml, and oilpriceapi/init.py. Public docs and most packaged source could bypass it. Current docs still advertised 1,000 API requests/month, fixed plan prices, a five-minute cadence, and a 99.9% uptime SLA; the installed wheel also carried a fixed streaming plan/price in customer recovery text. This is the Python portion of OilpriceAPI/oilpriceapi-api#5644.
Red / green
Red before implementation:
Green at 2f77d57:
Change
No API, entitlement, credential, email, or customer mutation is included.