Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
73 commits
Select commit Hold shift + click to select a range
f7d4e6b
feat: parse chain constants from metadata
moliholy Oct 7, 2025
a2902b0
feat(chains): parse storage state
moliholy Oct 8, 2025
fe15001
test(chains): add tests for chain constants and state
moliholy Oct 8, 2025
74b7377
feat(cli): allow querying storage and constants when calling pop call…
moliholy Oct 8, 2025
945387a
test: add tests for the chain call functionality
moliholy Oct 8, 2025
a5fa958
test: make integration tests pass
moliholy Oct 8, 2025
6d32b7a
feat: polish how documentation is displayed
moliholy Oct 9, 2025
a3556ed
refactor(cli): make the option to query the whole storage the first one
moliholy Oct 9, 2025
261c667
refactor: auto-enable retrying calls
moliholy Oct 9, 2025
386432b
ci: optimize docs test
moliholy Oct 9, 2025
03df838
test(chains): increase test coverage
moliholy Oct 9, 2025
292c287
fix: failing test
moliholy Oct 9, 2025
0ee85a8
test: constant and storage
moliholy Oct 9, 2025
2088bbc
doc(chains): improve errors
moliholy Oct 9, 2025
de75e88
doc(common): add missing documentation for pop()
moliholy Oct 9, 2025
ad47e8f
fix(cli): remove function parser
moliholy Oct 9, 2025
b63c6c1
fix(chains): FunctionNotFound assertion
moliholy Oct 9, 2025
52c6101
fix: FunctionNotFound assetion
moliholy Oct 9, 2025
bc0abd0
ci: run integration tests until the end
moliholy Oct 9, 2025
23ea1f6
feat(cli): parse endpoints directly as JSON array
moliholy Oct 9, 2025
c21e475
feat(cli): do not ask to make another call with --skip-confirm
moliholy Oct 9, 2025
58a2a40
fix(cli): RPCNode deserialization issues
moliholy Oct 9, 2025
6e46ec8
feat(cli): create a shortcut to type the URL manually
moliholy Oct 10, 2025
7b9210c
Merge branch 'main' into feat/chain-call-read
moliholy Oct 13, 2025
bccbd5c
feat(chains): lowercase hex string
moliholy Oct 13, 2025
2ed23ea
fix: default value for types without path
moliholy Oct 13, 2025
35711d8
fix: test with uppercase hexadecimals
moliholy Oct 13, 2025
b0a190d
feat: allow to query multiple storage entries
moliholy Oct 13, 2025
5155ad8
Merge remote-tracking branch 'origin/main' into feat/chain-call-read
moliholy Oct 13, 2025
53a9f05
feat: pretty-print large chain calls
moliholy Oct 13, 2025
862bb4b
feat: allow to specify some parameters via --args flag, but not neces…
moliholy Oct 13, 2025
8160b5a
doc: improve documentation for the function parameter
moliholy Oct 14, 2025
9f3a0dc
Merge remote-tracking branch 'origin/main' into feat/chain-call-read
moliholy Oct 15, 2025
4de50c6
fix: docs
moliholy Oct 16, 2025
3640a25
fix: tests
moliholy Oct 16, 2025
b37eca8
feat: display a list of contract-supported chains when calling a cont…
moliholy Oct 15, 2025
03fad05
feat: display chain selection while deploying a contract
moliholy Oct 15, 2025
afa6bf9
test: contract call
moliholy Oct 15, 2025
8565943
feat: allow to query contract storage
moliholy Oct 15, 2025
6ab9f31
refactor(cli): make suri optional
moliholy Oct 15, 2025
358cc00
refactor(cli): make url optional
moliholy Oct 15, 2025
9cd5c70
fix(cli): properly reset the contract call
moliholy Oct 15, 2025
04db7c3
refactor(cli): show success when successful dry-run
moliholy Oct 15, 2025
3f3f981
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 16, 2025
0666dbf
fix: parse contract address in advance
moliholy Oct 16, 2025
7ed8c65
refactor(cli): move rpc-related stuff to its own folder
moliholy Oct 16, 2025
a1225c8
fix(contracts): ink v6 imports
moliholy Oct 16, 2025
44ac020
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 17, 2025
bea5e98
fix: contract integration tests
moliholy Oct 17, 2025
a781f35
fix(cli): ink! v6 tests
moliholy Oct 17, 2025
a006b70
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 17, 2025
6cb39e5
chore: Use rustilities functions to get a better behavior and reduce …
tsenovilla Oct 21, 2025
edde874
fix: Allow users to specify the runtime dir path on pop build spec
tsenovilla Oct 21, 2025
be14ace
refactor: BuildSpecCommand id field becomes para_id
tsenovilla Oct 21, 2025
4b150de
feat: Allow use id/name in pop build spec
tsenovilla Oct 21, 2025
6b77c66
fix: Clippy warnings; test: Add some tests
tsenovilla Oct 22, 2025
f8bc11e
fix: Clippy
tsenovilla Oct 22, 2025
72be1d4
test: Add further tests
tsenovilla Oct 22, 2025
9fe0bb5
fix: Clippy warnings
tsenovilla Oct 22, 2025
6ee8000
Address comments
tsenovilla Oct 22, 2025
d5e9127
fmt
tsenovilla Oct 22, 2025
b33054f
test: fix test
tsenovilla Oct 22, 2025
8a946af
fix: Remove unnecesary artifact
tsenovilla Oct 22, 2025
5e5bdd6
address last comments
tsenovilla Oct 22, 2025
0a63314
address last comments
tsenovilla Oct 22, 2025
415ef4d
Merge branch 'main' into fix/allow-chain-spec-builder-to-specify-runt…
tsenovilla Oct 22, 2025
3527bf0
fix: Allow `pop build spec` to specify the runtime path as argument
tsenovilla Oct 22, 2025
b264f28
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 27, 2025
b80c319
refactor: improve ContractCallable implementation
moliholy Oct 27, 2025
a178810
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 28, 2025
a6f12d1
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 31, 2025
8ec2b1a
Merge remote-tracking branch 'origin/main' into feat/contract-call-read
moliholy Oct 31, 2025
71f63a1
fix: contract tests
moliholy Oct 31, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions crates/pop-cli/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -499,6 +499,7 @@ pub(crate) mod tests {
input,
placeholder: "".to_string(),
required: false,
validate_fn: None,
};
}
MockInput::default()
Expand Down Expand Up @@ -632,10 +633,14 @@ pub(crate) mod tests {
input: String,
placeholder: String,
required: bool,
validate_fn: Option<Box<dyn Fn(&String) -> std::result::Result<(), &'static str>>>,
}

impl Input for MockInput {
fn interact(&mut self) -> Result<String> {
if let Some(validator) = &self.validate_fn {
validator(&self.prompt).map_err(std::io::Error::other)?;
}
Ok(self.prompt.clone())
}
fn default_input(mut self, value: &str) -> Self {
Expand All @@ -654,9 +659,10 @@ pub(crate) mod tests {
}

fn validate(
self,
_validator: impl Fn(&String) -> std::result::Result<(), &'static str> + 'static,
mut self,
validator: impl Fn(&String) -> std::result::Result<(), &'static str> + 'static,
) -> Self {
self.validate_fn = Some(Box::new(validator));
self
}
}
Expand Down
13 changes: 8 additions & 5 deletions crates/pop-cli/src/commands/call/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ impl CallChainCommand {
cli.intro("Call a chain")?;
// Configure the chain.
let chain = chain::configure(
"Select a chain (type to filter)",
"Which chain would you like to interact with?",
urls::LOCAL,
&self.url,
Expand Down Expand Up @@ -236,7 +237,7 @@ impl CallChainCommand {
self.function = Some(action.function_name().to_string());
find_pallet_by_name(&chain.pallets, action.pallet_name())?
} else {
let mut prompt = cli.select("Select the pallet to call (type to filter):");
let mut prompt = cli.select("Select the pallet to call (type to filter)");
for pallet_item in &chain.pallets {
prompt = prompt.item(pallet_item, &pallet_item.name, &pallet_item.docs);
}
Expand All @@ -249,7 +250,7 @@ impl CallChainCommand {
let mut call_item = match self.function {
Some(ref name) => find_callable_by_name(&chain.pallets, &pallet.name, name)?,
None => {
let mut prompt = cli.select("Select the function to call (type to filter):");
let mut prompt = cli.select("Select the function to call (type to filter)");
for callable in pallet.get_all_callables() {
let name = format!("{} {}", callable.hint(), callable);
let docs = callable.docs();
Expand Down Expand Up @@ -811,7 +812,7 @@ mod tests {

let mut cli = MockCli::new()
.expect_select(
"Select a chain (type to filter):".to_string(),
"Select a chain (type to filter)".to_string(),
Some(true),
true,
Some(vec![("Custom".to_string(), "Type the chain URL manually".to_string())]),
Expand All @@ -820,7 +821,7 @@ mod tests {
)
.expect_input("Which chain would you like to interact with?", node_url.into())
.expect_select(
"Select the function to call (type to filter):",
"Select the function to call (type to filter)",
Some(true),
true,
Some(
Expand Down Expand Up @@ -871,6 +872,7 @@ mod tests {
.expect_confirm(USE_WALLET_PROMPT, true);

let chain = chain::configure(
"Select a chain (type to filter)",
"Which chain would you like to interact with?",
node_url,
&None,
Expand Down Expand Up @@ -903,7 +905,7 @@ mod tests {
let mut call_config = CallChainCommand::default();
let mut cli = MockCli::new()
.expect_select(
"Select a chain (type to filter):".to_string(),
"Select a chain (type to filter)".to_string(),
Some(true),
true,
Some(vec![("Custom".to_string(), "Type the chain URL manually".to_string())]),
Expand All @@ -912,6 +914,7 @@ mod tests {
)
.expect_input("Which chain would you like to interact with?", node_url.into());
let chain = chain::configure(
"Select a chain (type to filter)",
"Which chain would you like to interact with?",
node_url,
&None,
Expand Down
Loading
Loading