Take the SDK version from the contract - #26
Conversation
|
👋 Hello @glenn-jocher, thank you for submitting a
For more guidance, please refer to our Contributing Guide. Don't hesitate to leave a comment if you have any questions. Thank you for contributing to Ultralytics! 🚀 |
UltralyticsAssistant
left a comment
There was a problem hiding this comment.
🔍 PR Review
Made with ❤️ by Ultralytics Actions
The version override removal and README updates are behaviorally consistent with taking the package version from the contract. One stale CI-generated instruction remains and should be corrected before merge.
💬 Posted 1 inline comment
- 📝 LOW
openapi.config.json:38Removing the override without updating.github/workflows/ci.ymlleaves the automated contract-update PR body telling maintainers to “bump openapi.config.json python.version”. On the next contract sync, following that instruction would reintroduce the obsolete configuration and contradict the newinfo.versionsource-of-truth behavior. Update that workflow message in this PR to direct reviewers to assess the contract version instead.
| "project": "ultralytics-platform", | ||
| "readme": "README.python.md", | ||
| "requiresPython": ">=3.11", | ||
| "version": "0.1.5" |
There was a problem hiding this comment.
📝 LOW: Removing the override without updating .github/workflows/ci.yml leaves the automated contract-update PR body telling maintainers to “bump openapi.config.json python.version”. On the next contract sync, following that instruction would reintroduce the obsolete configuration and contradict the new info.version source-of-truth behavior. Update that workflow message in this PR to direct reviewers to assess the contract version instead.
There was a problem hiding this comment.
Updated the contract-update PR body: reviewers now confirm the upstream contract info.version bump instead of editing openapi.config.json.
|
🎉 This PR has been successfully merged—thank you, @glenn-jocher!
This update brings contract-driven package versioning, refreshed OpenAPI metadata, and clearer generated documentation to the SDK while preserving existing request behavior. |
Summary
Removes the hard-coded
python.versionfromopenapi.config.json: with ultralytics/openapi#43 the generator defaults the package version to the contract'sinfo.version, so the API version is the single source of truth and a contract bump reachingmainpublishes the SDK. README wording updated.Also re-pins the live contract snapshot (now
info.version0.1.5 via ultralytics/portal#3620, plus the authored examples from ultralytics/portal#3619) and regenerates: only docstring example text in five resource modules changes; the package version stays 0.1.5, so no publish is triggered.Depends on ultralytics/openapi#43 (CI regenerates from
openapimain).Verification
sha256sum --check,ruff check,pytest tests(4 passed); regeneratedpyproject.tomlreportsversion = "0.1.5"from the contract.🛠️ PR Summary
Made with ❤️ by Ultralytics Actions
🌟 Summary
The SDK now derives its package version from the OpenAPI contract’s
info.version, with the contract snapshot updated to 0.1.5 and related generated documentation refreshed.📊 Key Changes
versionfromopenapi.config.json, makingopenapi.json’sinfo.versionthe package-version source.openapi.jsonto contract version 0.1.5 and updated its checksum.🎯 Purpose & Impact
maindetermine the generated package version and publishing trigger.