Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

issue #10831: added --with-memo option to all cli commands that submit #16291

Merged
merged 6 commits into from
Apr 5, 2021

Conversation

bji
Copy link
Contributor

@bji bji commented Apr 1, 2021

transactions. Also, improve the block command to show UTF-8 string instead
of integer values for memo program data.

Problem

There was no way previously to add a memo to transactions via the cli.

Summary of Changes

Added memo support and additionally ensured that memo data is displayed as UTF-8 string instead of raw data in the cli block command

Fixes #10831

… that submit

transactions.  Also, improve the block command to show UTF-8 string instead
of integer values for memo program data.
@CriesofCarrots CriesofCarrots added the CI Pull Request is ready to enter CI label Apr 1, 2021
@solana-grimes solana-grimes removed the CI Pull Request is ready to enter CI label Apr 1, 2021
Copy link
Contributor

@CriesofCarrots CriesofCarrots left a comment

Choose a reason for hiding this comment

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

CI points out there are a bunch of manually built CliCommands in cli/tests that now need memo fields (sorry...)

docs/src/developing/programming-model/transactions.md Outdated Show resolved Hide resolved
cli/src/memo.rs Outdated Show resolved Hide resolved
cli/src/cli.rs Show resolved Hide resolved
cli/src/memo.rs Show resolved Hide resolved
cli-output/src/display.rs Outdated Show resolved Hide resolved
@CriesofCarrots CriesofCarrots added the CI Pull Request is ready to enter CI label Apr 2, 2021
@solana-grimes solana-grimes removed the CI Pull Request is ready to enter CI label Apr 2, 2021
cli/src/cli.rs Outdated Show resolved Hide resolved
@mvines
Copy link
Contributor

mvines commented Apr 3, 2021

@bji - I sent you a github invite for contributor access to the repo, if you accept then we don't need to continually add the CI flag to your PR anymore

@mvines mvines added CI Pull Request is ready to enter CI and removed CI Pull Request is ready to enter CI labels Apr 3, 2021
@solana-grimes solana-grimes removed the CI Pull Request is ready to enter CI label Apr 3, 2021
@bji
Copy link
Contributor Author

bji commented Apr 5, 2021

Can someone explain this Cargo.lock issue?

I had to use the spl-memo package and this resulted in the cargo build command updating Cargo.lock.

Isn't Cargo.lock a generated file? If so, why is it even checked into the repo?

cli-output/Cargo.toml Outdated Show resolved Hide resolved
cli-output/src/display.rs Outdated Show resolved Hide resolved
cli-output/src/display.rs Outdated Show resolved Hide resolved
cli/Cargo.toml Outdated Show resolved Hide resolved
Copy link
Contributor

@CriesofCarrots CriesofCarrots left a comment

Choose a reason for hiding this comment

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

Thank you for all the patience and polish! This looks great to me, pending CI

@CriesofCarrots CriesofCarrots added the automerge Merge this Pull Request automatically once CI passes label Apr 5, 2021
@mergify mergify bot merged commit 364af3a into solana-labs:master Apr 5, 2021
mergify bot pushed a commit that referenced this pull request Apr 5, 2021
#16291)

* issue #10831: added --with-memo option to all cli commands that submit
transactions.  Also, improve the block command to show UTF-8 string instead
of integer values for memo program data.

* Fixed tests and changed some syntax according to feedback.

* Use spl_memo id (all versions where applicable) instead of hardcoding id.

* Update Cargo.toml in programs/bpf.

* Update formatting via cargo fmt.

* Update to use spl_memo version 3.0.1, which simplifies package imports

(cherry picked from commit 364af3a)

# Conflicts:
#	cli-output/Cargo.toml
#	cli-output/src/display.rs
#	cli/Cargo.toml
#	cli/tests/transfer.rs
mergify bot pushed a commit that referenced this pull request Apr 5, 2021
#16291)

* issue #10831: added --with-memo option to all cli commands that submit
transactions.  Also, improve the block command to show UTF-8 string instead
of integer values for memo program data.

* Fixed tests and changed some syntax according to feedback.

* Use spl_memo id (all versions where applicable) instead of hardcoding id.

* Update Cargo.toml in programs/bpf.

* Update formatting via cargo fmt.

* Update to use spl_memo version 3.0.1, which simplifies package imports

(cherry picked from commit 364af3a)

# Conflicts:
#	cli-output/Cargo.toml
#	cli/Cargo.toml
mergify bot added a commit that referenced this pull request Apr 5, 2021
…t (bp #16291) (#16387)

* issue #10831: added --with-memo option to all cli commands that submit (#16291)

* issue #10831: added --with-memo option to all cli commands that submit
transactions.  Also, improve the block command to show UTF-8 string instead
of integer values for memo program data.

* Fixed tests and changed some syntax according to feedback.

* Use spl_memo id (all versions where applicable) instead of hardcoding id.

* Update Cargo.toml in programs/bpf.

* Update formatting via cargo fmt.

* Update to use spl_memo version 3.0.1, which simplifies package imports

(cherry picked from commit 364af3a)

# Conflicts:
#	cli-output/Cargo.toml
#	cli/Cargo.toml

* Fix conflicts

Co-authored-by: bji <bryan@ischo.com>
Co-authored-by: Tyera Eulberg <tyera@solana.com>
@brooksprumo brooksprumo mentioned this pull request Aug 23, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
automerge Merge this Pull Request automatically once CI passes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add --memo support to solana command-line
5 participants