ROB-1370 Fix docs build: use pydantic.v1.fields in autorobusta - #2171
Conversation
|
✅ Docker image ready for
Use this tag to pull the image for testing. 📋 Copy commandsgcloud auth configure-docker us-central1-docker.pkg.dev
docker pull us-central1-docker.pkg.dev/robusta-development/temporary-builds/robusta-runner:ae97a1e
docker tag us-central1-docker.pkg.dev/robusta-development/temporary-builds/robusta-runner:ae97a1e me-west1-docker.pkg.dev/robusta-development/development/robusta-runner-dev:ae97a1e
docker push me-west1-docker.pkg.dev/robusta-development/development/robusta-runner-dev:ae97a1ePatch Helm values in one line: helm upgrade --install robusta robusta/robusta \
--reuse-values \
--set runner.image=me-west1-docker.pkg.dev/robusta-development/development/robusta-runner-dev:ae97a1e |
The extension documents pydantic v1 models but referenced the v2 top-level pydantic.fields, which has no ModelField or SHAPE_* names. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
31ce5c3 to
f15aa9f
Compare
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 8 included reviews per hour; 6 remain after this review. WalkthroughThe documentation extension now references Pydantic v1 field types and shape constants through the ChangesPydantic v1 compatibility
Priority: ⬇️ Low — Defer this docs-build compatibility fix because its narrow scope is limited to Pydantic v1 field imports in the Sphinx extension. Estimated code review effort: 1 (Trivial) | ~2 minutes Merge Risk: ⚪ Minimal · up to The documentation extension now uses Pydantic v1 field APIs, restoring compatibility for model-field rendering without identified remaining merge risk. Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Comment |
Problem
The build-docs action fails:
The extension documents pydantic v1 models (it already imports
BaseModelandModelFieldfrompydantic.v1), but three helpers still referenced the v2 top-levelpydantic.fields, which has neitherModelFieldnor theSHAPE_*constants.Fix
import pydantic.v1.fieldsand use the v1ModelField/pydantic.v1.fields.SHAPE_*names.Testing
__get_readable_field_type,__get_sample_value) over every field of a real model — both work.sphinx-buildstops earlier on an unrelatedsphinx_immaterial.google_fonts403 fetching the Google Fonts API, which is a local network/API-key issue, not this code; CI should get past it.🤖 Generated with Claude Code