feat: Add network field to LlamaStackDistribution#2647
feat: Add network field to LlamaStackDistribution#2647jgarciao wants to merge 1 commit intoRedHatQE:mainfrom
Conversation
Update the LlamaStackDistribution resource and schema following the steps at class_generator/README.md Signed-off-by: Jorge Garcia Oncins <jgarciao@redhat.com>
WalkthroughModified Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes 🚥 Pre-merge checks | ✅ 2 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Tip Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord. 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 |
|
Report bugs in Issues Welcome! 🎉This pull request will be automatically processed with the following features: 🔄 Automatic Actions
📋 Available CommandsPR Status Management
Review & Approval
Testing & Validation
Cherry-pick Operations
Label Management
✅ Merge RequirementsThis PR will be automatically approved when the following conditions are met:
📊 Review ProcessApprovers and ReviewersApprovers:
Reviewers:
Available Labels
💡 Tips
For more information, please refer to the project documentation or contact the maintainers. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@ocp_resources/llama_stack_distribution.py`:
- Around line 3-7: There are duplicate imports of MissingRequiredArgumentError
and NamespacedResource: remove the stale line that imports both from
ocp_resources.resource (the first import) so only the correct imports remain
(NamespacedResource from ocp_resources.resource and MissingRequiredArgumentError
from ocp_resources.exceptions); if this duplication stems from the generator,
fix the generator template that emits the import block so it doesn't produce a
leftover import for MissingRequiredArgumentError.
| from ocp_resources.resource import MissingRequiredArgumentError, NamespacedResource | ||
|
|
||
| from typing import Any | ||
| from ocp_resources.resource import NamespacedResource | ||
| from ocp_resources.exceptions import MissingRequiredArgumentError |
There was a problem hiding this comment.
Duplicate imports: line 3 was not removed when lines 5–7 were added.
Line 3 imports both MissingRequiredArgumentError and NamespacedResource from ocp_resources.resource, then lines 6–7 re-import them (with MissingRequiredArgumentError now sourced from ocp_resources.exceptions). Ruff F811 confirms the redefinition. Remove the stale line 3.
Proposed fix
-from ocp_resources.resource import MissingRequiredArgumentError, NamespacedResource
-
from typing import Any
from ocp_resources.resource import NamespacedResource
from ocp_resources.exceptions import MissingRequiredArgumentErrorAs per coding guidelines, this file is auto-generated (# Generated using … → # End of generated code). If the generator produced this duplicate, the fix should be applied in the class-generator tool itself; if the stale line was left over from a previous version and the generator didn't clean it up, re-running the generator cleanly should resolve it.
🧰 Tools
🪛 Ruff (0.15.0)
[error] 6-6: Redefinition of unused NamespacedResource from line 3: NamespacedResource redefined here
Remove definition: NamespacedResource
(F811)
[error] 7-7: Redefinition of unused MissingRequiredArgumentError from line 3: MissingRequiredArgumentError redefined here
(F811)
🤖 Prompt for AI Agents
In `@ocp_resources/llama_stack_distribution.py` around lines 3 - 7, There are
duplicate imports of MissingRequiredArgumentError and NamespacedResource: remove
the stale line that imports both from ocp_resources.resource (the first import)
so only the correct imports remain (NamespacedResource from
ocp_resources.resource and MissingRequiredArgumentError from
ocp_resources.exceptions); if this duplication stems from the generator, fix the
generator template that emits the import block so it doesn't produce a leftover
import for MissingRequiredArgumentError.
This PR is a follow-up of #2637, updating the LlamaStackDistribution resource and schema following the steps at class_generator/README.md
Summary by CodeRabbit