Quadlet spec#371
Conversation
WalkthroughAdds an ArtifactApplicationProviderSpec type and integrates artifact-app handling: extends ApplicationProviderSpec union, adds AppTypeQuadlet enum member, exports the new type, adds an isArtifactAppProvider type guard, and updates device spec utilities to skip/omit artifact apps in patching and value generation. Changes
Sequence Diagram(s)sequenceDiagram
participant UI as EditDeviceWizard
participant Utils as deviceSpecUtils
participant Types as typeGuards
UI->>Utils: getApplicationPatches(currentApps, formApps)
Utils->>Types: isArtifactAppProvider(app)?
alt artifact app
Types-->>Utils: true
Utils-->>UI: no patch (skip artifact app)
else not artifact
Types-->>Utils: false
Utils-->>UI: compute patch (image/inline logic)
end
sequenceDiagram
participant UI as EditDeviceWizard
participant Utils as deviceSpecUtils
participant Types as typeGuards
UI->>Utils: getApplicationValues(deviceSpec)
Utils->>Types: isArtifactAppProvider(app)?
alt artifact app
Types-->>Utils: true
Utils-->>UI: filter out artifact app (exclude from values)
else not artifact
Types-->>Utils: false
Utils-->>UI: map to AppForm (OCI_IMAGE or INLINE)
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20–30 minutes
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 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 |
80cb7b5 to
cb08652
Compare
There was a problem hiding this comment.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (8)
libs/types/index.ts(1 hunks)libs/types/models/AppType.ts(1 hunks)libs/types/models/ApplicationProviderSpec.ts(2 hunks)libs/types/models/ArtifactApplicationProviderSpec.ts(1 hunks)libs/types/models/EnrollmentRequestSpec.ts(1 hunks)libs/ui-components/src/components/Device/EditDeviceWizard/deviceSpecUtils.ts(4 hunks)libs/ui-components/src/types/deviceSpec.ts(2 hunks)libs/ui-components/src/types/extraTypes.ts(2 hunks)
🚧 Files skipped from review as they are similar to previous changes (4)
- libs/types/models/ArtifactApplicationProviderSpec.ts
- libs/ui-components/src/components/Device/EditDeviceWizard/deviceSpecUtils.ts
- libs/ui-components/src/types/deviceSpec.ts
- libs/types/models/ApplicationProviderSpec.ts
🧰 Additional context used
🧬 Code graph analysis (1)
libs/ui-components/src/types/extraTypes.ts (2)
libs/types/index.ts (2)
ImageApplicationProviderSpec(109-109)ArtifactApplicationProviderSpec(16-16)libs/types/models/ImageApplicationProviderSpec.ts (1)
ImageApplicationProviderSpec(6-11)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: integration-tests
- GitHub Check: Lint
- GitHub Check: Build
🔇 Additional comments (3)
libs/types/models/EnrollmentRequestSpec.ts (1)
19-22: LGTM!The optional field addition maintains backward compatibility and is appropriately documented.
libs/ui-components/src/types/extraTypes.ts (1)
5-5: LGTM!The import is correctly added to support the new artifact-based application provider type.
libs/types/index.ts (1)
16-16: All verification checks pass. The source file exists and correctly exports the type.The verification confirms that
ArtifactApplicationProviderSpec.tsexists in the expected location, exports the correct type, and the re-export statement inlibs/types/index.tsis valid.
Adapts the UI to the new types introduced in flightctl/flightctl#1855 to support Quadlet and Artifact applications.
Support not yet added either on the Backend or UI, that will be done later.
Summary by CodeRabbit