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

Add withdrawal output type #101

Closed
SilentCicero opened this issue Feb 21, 2021 · 1 comment · Fixed by #103
Closed

Add withdrawal output type #101

SilentCicero opened this issue Feb 21, 2021 · 1 comment · Fixed by #103
Assignees
Labels
comp:VAL Component: Transaction Validity outside the Fuel VM enhancement New feature or request

Comments

@SilentCicero
Copy link
Member

Motivation:

I didn't see any deposit and withdraw types in our tx format as of today.

With v1.x we have clearly specified withdraw and deposit types. I recommend adding these for our tx format, keeping them the same as before unless further changes are required.

Posterity:

I would keep the same properties for deposit, namely the block number, amount, token and receiver.

Note:

Funnels can come later if choose to continue that pattern.

@adlerjohn adlerjohn changed the title Withdraw and Deposit Tx Types Add withdrawal output type Feb 21, 2021
@adlerjohn
Copy link
Contributor

adlerjohn commented Feb 21, 2021

Uniquely identifying deposits is defined here https://github.com/FuelLabs/fuel-specs/blob/afcb701935f975a327353bd4721f7e0218807ae8/specs/protocol/identifiers.md#utxo-id (pending actually having a deposit format, which we can defer until the smart contract implementation begins), as of #95 merged yesterday.

keeping them the same as before unless further changes are required

I disagree. There's no benefit to restricting ourselves to anything in the v1.x design, which was made ad-hoc without fully planning things out. The smart contracts will be re-written and changing the deposit format is trivial in a properly-abstracted codebase.

I would keep the same properties for deposit, namely the block number, amount, token and receiver.

This doesn't match up with the documented deposit ID (https://github.com/FuelLabs/docs/blob/e2d57505997a9a8af0438d57191df2ab024af04d/src/v1.0.0/3.%20Concepts/1.%20Data%20Structures/Deposits.md#deposit):

Deposits are uniquely keyed by { owner, token, blockNumber }

@adlerjohn adlerjohn added comp:VAL Component: Transaction Validity outside the Fuel VM enhancement New feature or request labels Feb 21, 2021
@adlerjohn adlerjohn self-assigned this Feb 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp:VAL Component: Transaction Validity outside the Fuel VM enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants