canonical / craft-application

The basis for *craft applications
https://canonical-craft-application.readthedocs-hosted.com/en/latest
GNU Lesser General Public License v3.0
7 stars 11 forks source link

feat(app): add lists of adoptable and mandatory project fields #231

Closed cmatsuoka closed 7 months ago

cmatsuoka commented 7 months ago

Project variables are defined in the application metadata and correspond to fields in the project model that can be set using craftctl.

Mandatory adoptable fields are project fields that can be adopted from external sources, including craftctl and metadata files.

Signed-off-by: Claudio Matsuoka claudio.matsuoka@canonical.com


syu-w commented 7 months ago

I still got

E   pydantic.error_wrappers.ValidationError: 1 validation error for Project
E   __root__
E     'adopt-info' does not reference a valid part. (type=value_error)
cmatsuoka commented 7 months ago

Rebased on main.

cmatsuoka commented 7 months ago

E pydantic.error_wrappers.ValidationError: 1 validation error for Project E root E 'adopt-info' does not reference a valid part. (type=value_error)

This PR needs to land for canonical/snapcraft#4601 to land on snapcraft, to address all those issues.

cmatsuoka commented 7 months ago

Restacked on top of cherry-picked #217 and #227.

codecov[bot] commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 89.29%. Comparing base (0705676) to head (49a8692). Report is 45 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #231 +/- ## ========================================== - Coverage 99.28% 89.29% -9.99% ========================================== Files 29 47 +18 Lines 1265 2383 +1118 Branches 209 411 +202 ========================================== + Hits 1256 2128 +872 - Misses 6 212 +206 - Partials 3 43 +40 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.