Skip to content

Support aliases in calldata#4383

Open
DelevoXDG wants to merge 7 commits into
zdobnikau/alias-multicallfrom
zdobnikau/alias-calldata
Open

Support aliases in calldata#4383
DelevoXDG wants to merge 7 commits into
zdobnikau/alias-multicallfrom
zdobnikau/alias-calldata

Conversation

@DelevoXDG
Copy link
Copy Markdown
Contributor

@DelevoXDG DelevoXDG commented May 25, 2026

Closes #2240

Stack

Introduced changes

  • @alias in --calldata and --constructor-calldata (call, invoke, deploy, multicall deploy/invoke)
  • tests: calldata alias on call, deploy, invoke, utils contract-address

Checklist

  • Linked relevant issue
  • Updated relevant documentation
  • Added relevant tests
  • Performed self-review of the code
  • Added changes to CHANGELOG.md

@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-multicall branch from 969d2b7 to b7493cf Compare May 25, 2026 17:53
@DelevoXDG DelevoXDG mentioned this pull request May 25, 2026
5 tasks
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-calldata branch from ed6a019 to 3899792 Compare May 25, 2026 18:32
@DelevoXDG DelevoXDG marked this pull request as ready for review May 26, 2026 11:54
@DelevoXDG DelevoXDG requested a review from a team as a code owner May 26, 2026 11:54
@DelevoXDG DelevoXDG requested review from MKowalski8 and franciszekjob and removed request for a team May 26, 2026 11:54
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-multicall branch from 77e59b4 to 7abce6b Compare May 26, 2026 11:57
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-calldata branch from 3899792 to 029558e Compare May 26, 2026 12:08
Comment thread crates/sncast/tests/e2e/alias/list.rs Outdated
Comment thread crates/sncast/tests/data/files/snfoundry_aliases.toml
Comment thread crates/sncast/src/starknet_commands/utils/felt_or_id.rs
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-multicall branch from 7abce6b to 591f51c Compare May 28, 2026 13:10
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-calldata branch from 029558e to 397b0ff Compare May 28, 2026 13:12
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-multicall branch from 591f51c to e7c0409 Compare May 29, 2026 14:46
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-calldata branch from 397b0ff to bff4b4b Compare May 29, 2026 15:01
@DelevoXDG DelevoXDG requested a review from franciszekjob May 29, 2026 15:17
maciektr pushed a commit to maciektr/starknet-foundry that referenced this pull request May 29, 2026
<!-- Reference any GitHub issues resolved by this PR -->

Towards foundry-rs#2240

## Stack
- foundry-rs#4365 
- foundry-rs#4366
- foundry-rs#4376 
- foundry-rs#4382
- foundry-rs#4383

## Introduced changes

- Initial alias logic setup; `[sncast.<profile>.aliases]` in
`snfoundry.toml`
- Support alias in `--contract-address` in `call`, `invoke`
- **tests:** `call` and `invoke` (alias resolves, unknown alias fails)

## Checklist

<!-- Make sure all of these are complete -->

- [x] Linked relevant issue
- [x] Updated relevant documentation
- [x] Added relevant tests
- [x] Performed self-review of the code
- [x] Added changes to `CHANGELOG.md`

---------

Co-authored-by: Franciszek Job <54181625+franciszekjob@users.noreply.github.com>
maciektr pushed a commit to maciektr/starknet-foundry that referenced this pull request May 29, 2026
…#4366)

<!-- Reference any GitHub issues resolved by this PR -->

Towards foundry-rs#2240

## Stack
- foundry-rs#4365 
- foundry-rs#4366
- foundry-rs#4376 
- foundry-rs#4382
- foundry-rs#4383

## Introduced changes

<!-- A brief description of the changes -->

- add `alias list` - show aliases from effective config
- update `show-config` - display number of configured aliases

## Checklist

<!-- Make sure all of these are complete -->

- [x] Linked relevant issue
- [x] Updated relevant documentation
- [x] Added relevant tests
- [ ] Performed self-review of the code
- [x] Added changes to `CHANGELOG.md`

---------

Co-authored-by: Franciszek Job <54181625+franciszekjob@users.noreply.github.com>
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-multicall branch from 9d9ad68 to 85151b6 Compare June 1, 2026 12:01
@DelevoXDG DelevoXDG force-pushed the zdobnikau/alias-calldata branch from e9de00c to 1db7a32 Compare June 1, 2026 12:03
Copy link
Copy Markdown
Contributor

@MKowalski8 MKowalski8 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left some comments, apart from that LGTM.
Also I assume existing CHANGLOG entry is enough?
I mean it's okay for me, just checking.

Comment thread crates/sncast/src/starknet_commands/utils/felt_or_id.rs
Comment thread crates/sncast/src/starknet_commands/utils/felt_or_id.rs Outdated
}

#[tokio::test]
async fn test_invoke_with_calldata_alias() {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: For call there is an Error test. If you find it useful we can add similar test for invoke and deploy as well.

DelevoXDG and others added 2 commits June 2, 2026 10:26
Co-authored-by: Maksymilian Kowalski <126796018+MKowalski8@users.noreply.github.com>
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.

3 participants