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

gen-upgrade-proposal.sh should be scriptable #8784

Open
mhofman opened this issue Jan 22, 2024 · 1 comment · May be fixed by #10590
Open

gen-upgrade-proposal.sh should be scriptable #8784

mhofman opened this issue Jan 22, 2024 · 1 comment · May be fixed by #10590
Assignees
Labels
agoric-cosmos enhancement New feature or request

Comments

@mhofman
Copy link
Member

mhofman commented Jan 22, 2024

What is the Problem Being Solved?

gen-upgrade-proposal.sh is a script to help the chain participant (usually a validator) generate a governance proposal transaction to upgrade an agoric-sdk based chain.

Some of the information must be provided, such as expected upgrade height, or upgrade name, and descriptions.

The script is currently outputting plain text instruction, including a command template meant to be copy/pasted with placeholders data for the above information. This results in the inability to script this process, and this helper script no longer being used for upgrades of the agoric-3 chain.

Description of the Design

  • Script accepting needed input as command line parameters or environment variables
    • Consider a way to extract information such as upgrade name (possibly related to Enforce xsnap version on chain start #7012 for a way to configure the codebase with the expected upgrade name)
    • Consider integrating the block estimator to calculate an upgrade height
    • Consider an interactive prompt with sane defaults if some information is not provided, e.g. for the title and description
  • Issue the command directly instead of printing it out
    • There should remain an option to print out the agd tx command, albeit fully populated, so that the validator can manually verify the transaction before submitting it

Furthermore the script does not currently support indicating core proposal information, which is needed for upgrade-14

Security Considerations

The script must remain legible, especially around how the tx command is generated, for validators to trust its output.

Scaling Considerations

None

Test Plan

Manual?

Upgrade Considerations

This is to facilitate upgrade instructions, but has no bearing on the actual upgrade.

@mhofman
Copy link
Member Author

mhofman commented Mar 18, 2024

#9048 captures the need to change the upgrade info generated by the script.

@aj-agoric aj-agoric assigned gibson042 and unassigned mhofman Apr 1, 2024
gibson042 added a commit that referenced this issue Dec 1, 2024
Fixes #8784

* script arguments for target release/tag/commit and Cosmos upgrade
  name, plus pass-through of arbitrary `agd tx` arguments
* automatic selection of upgrade name from gen-github-release.sh release
  contents, with interactive disambiguation (where possible) of multiple
  candidates
* reasonable defaults for title and description from
  gen-github-release.sh release contents
* script option `--send` to invoke `agd tx` rather than just printing it
  out (but successfully invocation additionally requires `--from` etc.)
* readable output of the `agd tx` command and data affecting it, whether
  or not it is to be invoked directly
* argument checking with readable error messages and usage details
* use of GitHub requests and https://main.agoric.net/network-config,
  overridable by environment variables
@gibson042 gibson042 linked a pull request Dec 1, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
agoric-cosmos enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants