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

abci-cli: added PrepareProposal command to cli #8656

Merged
merged 18 commits into from
Jun 13, 2022

Conversation

jmalicevic
Copy link
Contributor

Closes #8643 .

Added cli command for PrepareProposal.

@@ -333,6 +342,13 @@ func cmdTest(cmd *cobra.Command, args []string) error {
}, nil)
},
func() error { return servertest.Commit(ctx, client, []byte{0, 0, 0, 0, 0, 0, 0, 5}) },
func() error {
return servertest.PrepareProposal(ctx, client, [][]byte{
[]byte("abc"),
Copy link
Contributor

@tychoish tychoish May 31, 2022

Choose a reason for hiding this comment

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

why abc here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have changed to a random transaction as this should technically pass the prepare proposal. But I have issues with these tests written the way they are.. These are app specific things and it is unclear whether any of these should pass or not by default.

@jmalicevic jmalicevic changed the title abci-cli: added PrepareProposal command to cli #8643 (WIP) abci-cli: added PrepareProposal command to cli #8643 Jun 1, 2022
@@ -600,6 +618,43 @@ func cmdQuery(cmd *cobra.Command, args []string) error {
return nil
}

func cmdPrepareProposal(cmd *cobra.Command, args []string) error {
Copy link
Contributor

Choose a reason for hiding this comment

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

I might also be useful to accept extension... although I guess the complexity wouldn't justify the usefulness

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@sergio-mena I agree, but I think we would want to rewrite a lot of these tests at some point but right now this is not very high on the priority list. Can you please re-review the code that there is now, is it sufficient to provide basic testing functionality for someone wanting to use the command line for it?

Copy link
Contributor

Choose a reason for hiding this comment

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

Taking a look

@jmalicevic jmalicevic changed the title (WIP) abci-cli: added PrepareProposal command to cli #8643 abci-cli: added PrepareProposal command to cli Jun 1, 2022
@github-actions
Copy link

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale for use by stalebot label Jun 12, 2022
@jmalicevic jmalicevic removed the stale for use by stalebot label Jun 13, 2022
@jmalicevic jmalicevic merged commit 0617512 into master Jun 13, 2022
@jmalicevic jmalicevic deleted the jasmina/8643-abci-cli-prepareproposal branch June 13, 2022 12:09
@sergio-mena sergio-mena added this to In progress in ABCI++ via automation Jul 6, 2022
@sergio-mena sergio-mena moved this from In progress to Done in ABCI++ Jul 6, 2022
@sergio-mena sergio-mena mentioned this pull request Jul 22, 2022
35 tasks
sergio-mena pushed a commit that referenced this pull request Aug 17, 2022
sergio-mena added a commit that referenced this pull request Aug 17, 2022
* [cherrypicked] abci-cli: added `PrepareProposal` command to cli (#8656)

* Prepare prosal cli

* [cherrypicked + fixes] abci-cli: Add `process_proposal` command to abci-cli (#8901)

* Add `process_proposal` command to abci-cli

* Added process proposal to the 'tutorial' examples

* Added entry in CHANGELOG_PENDING.md

* Allow empty blocks in PrepareProposal, ProcessProposal, and FinalizeBlock

* Fix minimum arguments

* Add tests for empty block

* Updated abci-cli doc

Co-authored-by: Sergio Mena <sergio@informal.systems>
Co-authored-by: Jasmina Malicevic <jasmina.dustinac@gmail.com>

* Addressed @williambanfield's comment

Co-authored-by: Jasmina Malicevic <jasmina.dustinac@gmail.com>
Co-authored-by: Hernán Vanzetto <hernan.vanzetto@gmail.com>
@hvanz hvanz mentioned this pull request Sep 12, 2023
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

abci-cli: implement command for PrepareProposal
4 participants