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

Docs for currency #2042

Merged
merged 4 commits into from
Aug 29, 2024
Merged

Docs for currency #2042

merged 4 commits into from
Aug 29, 2024

Conversation

grumbach
Copy link
Member

@grumbach grumbach commented Aug 14, 2024

Docs for the currency

@grumbach grumbach marked this pull request as ready for review August 21, 2024 07:17
@grumbach grumbach changed the title WIP: docs for currency Docs for currency Aug 21, 2024
@grumbach grumbach enabled auto-merge August 21, 2024 07:18
Copy link
Member

@maqi maqi left a comment

Choose a reason for hiding this comment

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

A very nice write up.
However, note it is based one the new spend struct, hence may have to be merged of the refactor PR got merged.


Without the `DerivationIndex`, there is no way to link a `MainPubkey` to a `UniquePubkey`. Since `UniquePubkey`s are spendable only once, this means every transaction involves new and unique keys which are all unrelated and unlinkable to their original owner's `MainPubkey`.

Under the hood, those types are simply:
Copy link
Member

Choose a reason for hiding this comment

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

simply -> simple ?

@b-zee b-zee marked this pull request as draft August 27, 2024 10:57
auto-merge was automatically disabled August 27, 2024 10:57

Pull request was converted to draft

@b-zee b-zee marked this pull request as ready for review August 27, 2024 10:57
Copy link
Member

@maqi maqi left a comment

Choose a reason for hiding this comment

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

Depends on the PR #1989

pub struct Spend {
pub unique_pubkey: UniquePubkey,
pub ancestors: BTreeSet<UniquePubkey>,
pub descendants: BTreeMap<UniquePubkey, NanoTokens>,
Copy link
Member

Choose a reason for hiding this comment

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

still need to keep the royalties member field

also, shall the doc cover the reason member field as well?

if this doc is just about currency & spend DAG, which these two fields (especially the reason field) are not that related,
at least put a ... below the line of descendants, to avoid give a mis-impression to the readers that Spend struct only has that three member fields ?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes I didn't document that as those fields are more likely to evolve thus the ...

Copy link
Member Author

Choose a reason for hiding this comment

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

We could add those once stabilized?

@grumbach grumbach added this pull request to the merge queue Aug 29, 2024
Merged via the queue into maidsafe:main with commit cb97565 Aug 29, 2024
41 checks passed
@grumbach grumbach deleted the currency_docs branch August 29, 2024 11:44
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.

2 participants