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

refactor: pop up command #403

Draft
wants to merge 9 commits into
base: feat/deploy-parachain
Choose a base branch
from
Draft

Conversation

AlexD10S
Copy link
Collaborator

@AlexD10S AlexD10S commented Feb 6, 2025

  • Enables pop up command to run without specifying contract or parachain, automatically detecting the project type.

  • Refactors pop up to distinguish between deploying a parachain and launching a local network, as it does currently with pop up parachain.

  • Handles the deprecation of pop up contract and pop up parachain, keeping them functional for now but marking them for future removal (Reference feat: enable building without project type specification #222).

Notes for reviewer

  • This PR is not targeting main. It is the first step toward a larger PR that will handle the full parachain deployment functionality.
  • Verify pop up --help to ensure clarity for users.
  • Unit tests for the deprecation warning are not included since unit tests for these files are being worked on in PR #315, and adding them here would introduce unnecessary noise.

Commands for testing

# Deploy a contract passing path
pop up ../flipper --args false
# Deploy a contract using flag --path
pop up --path ./flipper --args false
# Deploy a contract, inside the contract folder.
pop up --args false
# Deploy a contract with deprecated command. (Should display an warning message).
pop up contract --args false
# Launch a local network
pop up network -f ./network.toml
# Launch a local network  with deprecated command. (Should display an warning message).
pop up parachain -f ./network.toml

# This will be used to deploy a parachain; currently, it does not produce any output.
pop up

[sc-2506]

Copy link

codecov bot commented Feb 7, 2025

Codecov Report

Attention: Patch coverage is 13.88889% with 31 lines in your changes missing coverage. Please review.

Project coverage is 75.00%. Comparing base (17d3bd6) to head (651b73e).

Files with missing lines Patch % Lines
crates/pop-cli/src/commands/up/mod.rs 0.00% 12 Missing ⚠️
crates/pop-cli/src/commands/mod.rs 0.00% 9 Missing ⚠️
crates/pop-cli/src/commands/up/contract.rs 45.45% 5 Missing and 1 partial ⚠️
crates/pop-cli/src/commands/up/network.rs 0.00% 4 Missing ⚠️
@@                    Coverage Diff                    @@
##           feat/deploy-parachain     #403      +/-   ##
=========================================================
- Coverage                  75.11%   75.00%   -0.12%     
=========================================================
  Files                         63       64       +1     
  Lines                      13842    13862      +20     
  Branches                   13842    13862      +20     
=========================================================
- Hits                       10398    10397       -1     
- Misses                      2118     2139      +21     
  Partials                    1326     1326              
Files with missing lines Coverage Δ
crates/pop-cli/src/commands/up/network.rs 6.88% <0.00%> (ø)
crates/pop-cli/src/commands/up/contract.rs 34.17% <45.45%> (+0.09%) ⬆️
crates/pop-cli/src/commands/mod.rs 14.28% <0.00%> (-2.05%) ⬇️
crates/pop-cli/src/commands/up/mod.rs 0.00% <0.00%> (ø)

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.

1 participant