← Back to issue list

The `adopt_info` field should be checked to reference a valid part.

View original Github issue

Metadata

Project
craft-application
Number
#926
Type
issue
State
open
Author
lengau
Labels
Status: Triaged Type: Bug
Created
Updated
Closed

Current evaluation

Bug: the adopt-info field accepts any string without verifying it references an existing part in the project. Triaged by a maintainer (lengau) with a Jira ticket (CRAFT-4818) created, but no fix has landed; the field is still a plain str with no validator in the current code.

Suggested action: keep open

Reason: The issue is labelled Status: Triaged and Type: Bug, authored by a maintainer, with an internal Jira ticket (CRAFT-4818) created on 2025-09-30, so it has been assessed and is not stale or a support request. The current code still declares adopt_info as a plain str | None with no validator checking the referenced part exists, and the earlier adopt-info validation work (PR #227) was reverted, so the bug remains unfixed and should stay open.

Impact: 50 Quick Win: 30.0 Staleness: 55 Complexity: 40 Confidence: 70 Support Request: 5

Issue body

### Bug Description Right now the `adopt-info` field accepts any string, whether it's a part in the project or not. ### To Reproduce Use testcraft to build the file below. ### part yaml ```shell name: minimal-valid-project parts: {} version: "0.0" adopt-info: my-part platforms: amd64: build-on: [amd64] build-for: [amd64] ``` ### Relevant log output ```shell n/a ```

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.8-27b
Impact: 50
Quick Win: 30.0
Staleness: 55
Complexity: 40
Confidence: 70
Support Request: 5
keep open Bug: the adopt-info field accepts any string without verifying it references an existing part in the project. Triaged by a maintainer (lengau) with a Jira ticket (CRAFT-4818) created, but no fix has landed; the field is still a plain str with no validator in the current code.
qwen/qwen3.6-35b-a3b
Staleness: 75
Complexity: 15
Confidence: 85
Support Request: 5
keep open adopt-info field accepts any string instead of validating it references an existing part. Currently triaged and awaiting implementation.
qwen3.6-35b-a3b-mtp-q6
Staleness: 78
Complexity: 20
Confidence: 85
Support Request: 0
keep open Validates that the adopt-info field references an existing part. Currently accepts any string. Triaged as a bug, but inactive for ~9 months with no maintainer follow-up.
qwen3.6-35b-a3b-mtp-q6
Staleness: 75
Complexity: 20
Confidence: 85
Support Request: 0
keep open adopt-info field lacks validation to ensure it references an existing project part. This triaged bug has been open for 259 days awaiting assignment and a fix.

Update history

No update history recorded yet.

Related work

  • Related To: craft-application#227 (confidence 60%)

    PR #227 'fix(models): address adopt-info validation by name' touched adopt-info validation but was reverted (commit 12685e8e) and addressed a different Pydantic alias issue, not part-existence validation.

Related issues

No related issues found above the similarity threshold.