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

feat!: move config commands to top level #1086

Merged
merged 20 commits into from
Jan 11, 2024

Conversation

willemneal
Copy link
Member

@willemneal willemneal commented Nov 16, 2023

What

Why

[TODO: Why this change is being made. Include any context required to understand the why.]

Known limitations

[TODO or N/A]

@willemneal
Copy link
Member Author

@leighmcculloch The last step is to split identity into keys and address book. Should I put them under the network too?

That is store them in a folder for each network?

@leighmcculloch
Copy link
Member

I thought the identity command today was just keys that have a secret, not address only identities. I don't think we need to add the address book now if so.

@leighmcculloch
Copy link
Member

That is store them in a folder for each network?

I'm concerned that separating keys by network in the CLI UI will create for a confusing or unintuitive interface. I think we should do some UI design in a doc before embarking on it in code.

@willemneal
Copy link
Member Author

Yeah the addresses become tricky because contract id's are derived from the network passsphrase and are obviously only deployed on one network. So we could keep keys as is and add the address book per network. But either way I'll just update this PR to just rename identity to keys.

@willemneal willemneal marked this pull request as ready for review November 28, 2023 15:12
@willemneal
Copy link
Member Author

@2opremio Looks like the prefight debug test is failing:

=== RUN   TestGetPreflightDebug
    preflight_test.go:388: 
                Error Trace:    /Users/willem/c/s/soroban-cli/cmd/soroban-rpc/internal/preflight/preflight_test.go:388
                Error:          "host invocation failed\n\nCaused by:\n    HostError: Error(WasmVm, MissingValue)\n    DebugInfo not available\n    " does not contain "Backtrace"

@janewang
Copy link
Contributor

janewang commented Dec 2, 2023

Food for thought, and not this PR. Would be nice to be able view accounts in a table-like view with its respective network futurenet|testnet|mainnet

Network Name Public key 
─────── ──── ─────── 
testnet alice G-
testnet bob G-

@2opremio
Copy link
Contributor

2opremio commented Dec 2, 2023

@2opremio Looks like the prefight debug test is failing:

=== RUN   TestGetPreflightDebug
    preflight_test.go:388: 
                Error Trace:    /Users/willem/c/s/soroban-cli/cmd/soroban-rpc/internal/preflight/preflight_test.go:388
                Error:          "host invocation failed\n\nCaused by:\n    HostError: Error(WasmVm, MissingValue)\n    DebugInfo not available\n    " does not contain "Backtrace"

Uhm, can you try to debug it? I am off this week. Thanks!

@leighmcculloch
Copy link
Member

cc @stellarsaur Is this something you able to help with?

@willemneal
Copy link
Member Author

Food for thought, and not this PR. Would be nice to be able view accounts in a table-like view with its respective network futurenet|testnet|mainnet

Network Name Public key 
─────── ──── ─────── 
testnet alice G-
testnet bob G-

I agree, but we currently don't store keys under their network so it's not possible. So I'll make a future PR that addresses this.

@willemneal willemneal linked an issue Dec 4, 2023 that may be closed by this pull request
@willemneal
Copy link
Member Author

willemneal commented Dec 5, 2023

error: There are multiple stellar-xdr packages in your project, and the specification stellar-xdr is ambiguous

I purposely depended on the stellar-xdr repo at a different version in the soroban-cli crate to get access to thecil feature. When I initially updated the version at the top level it broke other crates. I can either update the whole workspace to the newest xdr and then merge the xdr CLI stuff or we can ignore this for now?

I vote for shelving the xdr cli until the whole workspace is updated to the newest stellar-xdr, as it doesn't make sense that the rest of the workspace has a different version.

@leighmcculloch
Copy link
Member

There's no need to ship embedding the xdr CLI right now. It's not urgent. There's an issue open tracking that work separately:

@willemneal
Copy link
Member Author

@leighmcculloch @mollykarcher

The CI dep checker failed with just the following:

Error: Process completed with exit code 6.

@willemneal willemneal force-pushed the feat!/refactor-config branch 4 times, most recently from d030134 to 0f30c3d Compare December 15, 2023 14:30
@leighmcculloch
Copy link
Member

Would be great to get this included in the next release, but a couple things:

  1. Looks like there's one system test failing that might be important.

  2. There are some minor conflicts before it can merge.

  3. This change is a breaking change to the CLI's UI, and we've released v20 stable already, so can we add hidden subcommands, or subcommands marked as deprecated, into the old locations for the commands being moved/renamed so that anyone already using them will continue to be able to use them?

@janewang
Copy link
Contributor

Let's make this change not breaking please #1146

@willemneal willemneal force-pushed the feat!/refactor-config branch 2 times, most recently from 6818ab7 to cc2552d Compare January 4, 2024 00:22
docs/soroban-cli-full-docs.md Show resolved Hide resolved
docs/soroban-cli-full-docs.md Show resolved Hide resolved
docs/soroban-cli-full-docs.md Outdated Show resolved Hide resolved
@willemneal willemneal enabled auto-merge (squash) January 11, 2024 12:53
@willemneal willemneal merged commit 8906a53 into stellar:main Jan 11, 2024
24 checks passed
@willemneal willemneal deleted the feat!/refactor-config branch January 11, 2024 18:53
chadoh added a commit to AhaLabs/stellar-cli that referenced this pull request Jun 21, 2024
There has been no default `--source-account` since 8906a53 / stellar#1086
willemneal pushed a commit that referenced this pull request Jun 21, 2024
There has been no default `--source-account` since 8906a53 / #1086
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants