Skip to content
This repository has been archived by the owner on Oct 31, 2023. It is now read-only.

ref(link): Return better errors when provider id is given #207

Merged

Conversation

thomastaylor312
Copy link
Contributor

It is relatively common for first time users to pass the provider id rather
than the contract ID when doing wash ctl link del. This adds a block
that tests if it is a provider ID and returns a hint to the user. I also
noticed we weren't returning an error code on link commands if they failed,
so I added some logic to fix it

autodidaddict
autodidaddict previously approved these changes Nov 23, 2021
src/ctl/mod.rs Outdated Show resolved Hide resolved
It is relatively common for first time users to pass the provider id rather
than the contract ID when doing `wash ctl link del`. This adds a block
that tests if it is a provider ID and returns a hint to the user. I also
noticed we weren't returning an error code on link commands if they failed,
so I added some logic to fix it

Signed-off-by: Taylor Thomas <taylor@cosmonic.com>
Copy link
Member

@brooksmtownsend brooksmtownsend left a comment

Choose a reason for hiding this comment

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

LGTM, this is gonna save a few developers a lot of time

@thomastaylor312 thomastaylor312 merged commit 867b4e9 into wasmCloud:main Nov 24, 2021
@thomastaylor312 thomastaylor312 deleted the ref/better_link_error branch November 24, 2021 17:03
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants