Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes for RK042 - Support for Pro Rocks in Rockcraft - 30/01/25 #616

Merged
merged 51 commits into from
Feb 5, 2025

Conversation

clay-lake
Copy link

@clay-lake clay-lake commented Jan 28, 2025

  • Have you followed the guidelines for contributing?
  • Have you signed the CLA?
  • Have you successfully run tox?

Updates to complete feature set fot RK042 - Support for Pro Rocks in Rockcraft.

bepri and others added 30 commits December 5, 2024 07:53
These environment variables may be set if the integration tests are run inside a snapped IDE or terminal.
Signed-off-by: Dariusz Duda <[email protected]>
Co-authored-by: Tiago Nobrega <[email protected]>
Co-authored-by: Michael DuBelko <[email protected]>
This class will hold the implementation that is valid for all non-snap recipe
types. For now it's just the previous CharmRecipe - the next commit will do
the generalization work.
Subclasses must provide the name of the artifact (charm, rock, etc) and the
launchpad object that wraps the utility to manipulate recipes.
* refactor: add _StandardRecipe base class

This class will hold the implementation that is valid for all non-snap recipe
types. For now it's just the previous CharmRecipe - the next commit will do
the generalization work.

* refactor: generalize _StandardRecipe

Subclasses must provide the name of the artifact (charm, rock, etc) and the
launchpad object that wraps the utility to manipulate recipes.

---------

Co-authored-by: Alex Lowe <[email protected]>
build(deps) replace pytest-freezegun with pytest-freezer
Since 3.12.8, argparse 'choices' are no longer quoted.
Ref: python/cpython#11776

---------

Co-authored-by: Alex Lowe <[email protected]>
The implementation comes from Charmcraft. This commit has the code changes to
make the command craft-tool-agnostic, plus some general test and linting fixes
and improvements.
This also adds an utility function, get_recipe_class(), so that client code
can be a bit more agnostic on the concrete recipe types (with the notable
exception of Snaps).
Snap recipes support defining 'architectures', but charm and rocks don't. Since
the remote-build service always passes this parameter, accept it but fail with
a good message if the value is not None.
* chore: bring latest ruff config from starbase

* style: autoformat

* style(tests): fix linting issues in tests

* style(tests): fix linting issues in docs

* style: fix linting issues in main code

* style: autoformat
Signed-off-by: Dariusz Duda <[email protected]>
Co-authored-by: Alex Lowe <[email protected]>
Signed-off-by: Callahan Kovacs <[email protected]>
Co-authored-by: Alex Lowe <[email protected]>
This ensures each platform is built in its own build environment.

Signed-off-by: Callahan Kovacs <[email protected]>
…nical#611)

build(deps): update canonical/setup-lxd action to v0.1.2

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@clay-lake clay-lake changed the title DRAFT: RK042 - Support for Pro Rocks in Rockcraft Changes for RK042 - Support for Pro Rocks in Rockcraft - 30/01/25 Jan 30, 2025
Copy link

codecov bot commented Feb 4, 2025

Codecov Report

Attention: Patch coverage is 87.47554% with 64 lines in your changes missing coverage. Please review.

Project coverage is 90.37%. Comparing base (2768bb5) to head (4a72dc3).
Report is 2 commits behind head on feature/pro-sources.

Files with missing lines Patch % Lines
craft_application/commands/remote.py 74.74% 22 Missing and 3 partials ⚠️
craft_application/services/service_factory.py 83.47% 1 Missing and 19 partials ⚠️
craft_application/launchpad/launchpad.py 66.66% 1 Missing and 3 partials ⚠️
craft_application/launchpad/models/recipe.py 92.15% 3 Missing and 1 partial ⚠️
craft_application/services/remotebuild.py 76.47% 4 Missing ⚠️
craft_application/util/pro_services.py 85.00% 3 Missing ⚠️
craft_application/application.py 90.00% 1 Missing and 1 partial ⚠️
craft_application/errors.py 81.81% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@                   Coverage Diff                   @@
##           feature/pro-sources     #616      +/-   ##
=======================================================
- Coverage                90.47%   90.37%   -0.11%     
=======================================================
  Files                       65       67       +2     
  Lines                     3781     4175     +394     
  Branches                   414      480      +66     
=======================================================
+ Hits                      3421     3773     +352     
- Misses                     288      306      +18     
- Partials                    72       96      +24     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@clay-lake clay-lake marked this pull request as ready for review February 4, 2025 15:58
@clay-lake
Copy link
Author

Hey, @canonical/starcraft-reviewers @tigarmo Could I get this merged in?

@tigarmo tigarmo merged commit e921232 into canonical:feature/pro-sources Feb 5, 2025
11 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants