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

Replace Gas with Sui throughout end-to-end tutorial #1132

Closed
wants to merge 1 commit into from

Conversation

Clay-Mysten
Copy link
Contributor

Replace Gas with Sui throughout end-to-end tutorial

Replace Gas with Sui throughout end-to-end tutorial
@Clay-Mysten Clay-Mysten requested review from lxfind and awelc March 29, 2022 18:51
Copy link
Contributor

@awelc awelc left a comment

Choose a reason for hiding this comment

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

This may require a wider consultation on how we want to phrase these in the docs. I am tagging @sblackshear and @adeabiodun on this one.

@@ -21,7 +21,7 @@ the `wallet` command used in the remainder of this tutorial in your path.
Simply leave the terminal with Sui running and start a new terminal for the
remainder of this tutorial.

## Gather accounts and gas objects
## Gather accounts and Sui objects
Copy link
Contributor

Choose a reason for hiding this comment

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

I would not do it this way. We use the term "Sui objects" quite pervasively to mean any object in Sui. Calling gas objects "Sui objects" as well will create an enormous amount of confusion.

I'd suggest leaving "gas" in these general descriptions and talk about "SUI" only if it matters (e.g., if we refer to the actual code in SUI.move).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks, Adam. I'm not finding any instances of "gas" that need replacement given the Wallet commands and output retain the term.

Instead, I'm trying to disambiguate in the glossary and will likely abandon this PR:
#1134

Please advise. Thanks.

Copy link
Contributor

Choose a reason for hiding this comment

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

I think it's a good idea. I guess my tagging @mystenadmin and @adeabiodun on this PR did not have the desired effect, but I would still suggest asking them about their view on the gas naming strategy in the docs and conversations about Sui.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Agreed that we should use SUI to refer to the Sui token. Wherever we say "gas objects", we should instead say "SUI tokens" or "SUI coins".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed that we should use SUI to refer to the Sui token. Wherever we say "gas objects", we should instead say "SUI tokens" or "SUI coins".

Whoops. Sorry i missed this, Sam. I was afraid of introducing confusion my mixing and matching, after speaking with Adam.

Does it make sense to rename this as "Gather accounts and SUI tokens" given the remainder of that section and doc use "gas objects" or some variant? Should we use SUI tokens/coins more liberally throughout?

Thanks for your guidance!

Copy link
Contributor

Choose a reason for hiding this comment

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

To throw another potential wrench into this (sorry), I seem to remember @gdanezis saying something along the lines of keeping the notion of gas a a form of computation payment (presumably as it is well understood in the industry) and saying that SUI tokens are used for gas payments.

We should really think this through and decide once and for all how to use both terms before we make any sweeping changes to the docs. Ideally we'd have a doc that summarizes guidance in this department so that there is no doubt in the future on how to use these terms.

----------------------------------------------------------------------
6F675038CAA48184707DBBE95ACFBA2030E87CD8 | 0 | 100000
80C91F0B31EFBC1C7BF639A531301AAF3A1D3AB6 | 0 | 100000
9FED1FC3D21F284DC53DE87C0E19718971D96D8C | 0 | 100000
E293F935F015C23216867442DB4E712518E7CAB7 | 0 | 100000
F19384C06AE538F9C3C9D9762002B4DAEA49FE3A | 0 | 100000
$ wallet --no-shell gas --address $PLAYER_O
Copy link
Contributor

Choose a reason for hiding this comment

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

These commands have not been updated for sure. Nor should they necessarily, I think (please see my other comment).

More generally, wallet outputs have not been updated to the new terminology (again, I don't think it's needed in may, possibly all, cases).

@gdanezis
Copy link
Collaborator

I agree. SUI will be our token, so we need to be careful how we message it. And also not to confuse people between the test tokens being used in test nets / dev nets and what will actually have value. Lets talk to our product people about how to do this best.

@Clay-Mysten
Copy link
Contributor Author

Unless there are objections, I will close this PR.

@Clay-Mysten Clay-Mysten requested a review from gdanezis March 31, 2022 15:38
@Clay-Mysten
Copy link
Contributor Author

Adding George for review. The Marketing team is already included. Let's suss this out.

@econmysten
Copy link
Contributor

i think we should follow existing conventions and
i) refer to gas as gas,
ii) refer to the unit cost of gas in our native currency SUI as the gas price,
iii) refer the product of gas * gas_price as the transaction fee

@Clay-Mysten
Copy link
Contributor Author

Clay-Mysten commented Mar 31, 2022

i think we should follow existing conventions and i) refer to gas as gas, ii) refer to the unit cost of gas in our native currency SUI as the gas price, iii) refer the product of gas * gas_price as the transaction fee

The thing is, we don't mention price one time in:
https://docs.sui.io/explore/tutorials

We do refer to gas value repeatedly though. Ex. "Some gas was charged: the initial gas value was 10000, now it's 92939"

We could make that, "Some SUI was charged: the initial gas value was 100000, now it's 92939 with a transaction fee of 7061."

If we do that, we should introduce SUI at the first gas reference too.

Also, note I added your definitions above to the glossary, but that change still needs approval:
#1134

Further, if you see other references to gas on that page that should instead be SUI, I'd appreciate your help identifying them.

@econmysten
Copy link
Contributor

We have a problem here:

  1. The tutorial indeed does not measure the gas price and simply assumes that the user pays for gas directly using some gas token (which is presumably SUI). The tutorial does not describe what's going on under the hood and, indeed, this tutorial is consistent with a world where gas is directly invoiced in SUI. Which is not how Sui or other blockchains work.
  2. Anyone familiar with gas will expect the transaction fee = gas_units * gas_price. Which is different from 1).
    So the problem we have is that the tutorial is at best imprecise regarding how Sui works or at worst wrong. This is OK because it's a tutorial of an early design of Sui.
    Ultimately, we will have a gas_price and the dev portal will reflect that. I see no reason in delaying this. At most, I'd add a footnote to the tutorial saying that "This tutorial models gas fees under a simplified schema. In practice, the Sui network will charge for gas using its native currency SUI. This transaction fee equals the computational effort of executing operations on the Sui network (i.e. gas units) times the price of gas in the SUI currency (i.e. the gas price)."

@Clay-Mysten
Copy link
Contributor Author

We have a problem here:

  1. The tutorial indeed does not measure the gas price and simply assumes that the user pays for gas directly using some gas token (which is presumably SUI). The tutorial does not describe what's going on under the hood and, indeed, this tutorial is consistent with a world where gas is directly invoiced in SUI. Which is not how Sui or other blockchains work.
  2. Anyone familiar with gas will expect the transaction fee = gas_units * gas_price. Which is different from 1).
    So the problem we have is that the tutorial is at best imprecise regarding how Sui works or at worst wrong. This is OK because it's a tutorial of an early design of Sui.
    Ultimately, we will have a gas_price and the dev portal will reflect that. I see no reason in delaying this. At most, I'd add a footnote to the tutorial saying that "This tutorial models gas fees under a simplified schema. In practice, the Sui network will charge for gas using its native currency SUI. This transaction fee equals the computational effort of executing operations on the Sui network (i.e. gas units) times the price of gas in the SUI currency (i.e. the gas price)."

I've added this note to the Set up section of the tutorial, before the first gas reference, in:
#1170

This does beg the question how we use gas elsewhere and whether those uses are correct, for example in the Move and Wallet docs but truly across the site:
https://docs.sui.io/build/move
https://docs.sui.io/build/wallet

Keeping this PR open for deliberation in lieu of that plan Adam has requested.

@Clay-Mysten
Copy link
Contributor Author

NO NOT MERGE

The original issue here has been addressed in:
#1170

Leaving this open temporarily to see if other changes are required. See the hearty discussion here.

@Clay-Mysten
Copy link
Contributor Author

Now closing this out as a no-op

@Clay-Mysten Clay-Mysten closed this Apr 4, 2022
@huitseeker huitseeker deleted the Clay-Mysten-patch-14 branch April 20, 2022 01:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants