Skip to content

docs: improve basic_solana Candid documentation#161

Merged
lpahlavi merged 3 commits intomainfrom
lpahlavi/basic-solana-candid-documentation
Jun 30, 2025
Merged

docs: improve basic_solana Candid documentation#161
lpahlavi merged 3 commits intomainfrom
lpahlavi/basic-solana-candid-documentation

Conversation

@lpahlavi
Copy link
Contributor

@lpahlavi lpahlavi commented Jun 27, 2025

(XC-405) Improve the documentation in basic_solana.did for all endpoints.

@lpahlavi lpahlavi changed the title doc: improve basic_solana Candid documentation docs: improve basic_solana Candid documentation Jun 27, 2025
@lpahlavi lpahlavi marked this pull request as ready for review June 27, 2025 13:34
@lpahlavi lpahlavi requested a review from a team as a code owner June 27, 2025 13:34
Copy link
Contributor

@gregorydemay gregorydemay left a comment

Choose a reason for hiding this comment

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

Thanks @lpahlavi for improving the docs!

// Parameters:
// - `owner` (optional): The principal to derive the address from.
// If omitted, the caller's principal is used.
solana_account : (owner: opt principal) -> (Address);
Copy link
Contributor

Choose a reason for hiding this comment

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

it's a bit confusing that the function is called solana_account but returns an address. should this be renamed for this and the other endpoints?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@letmejustputthishere That's a good point. I merged this PR, but I can potentially open another one for renaming the endpoints. My reasoning is that pretty much everywhere in the Candid interface, accounts are identified by an address. It's a bit of a subtle difference, as the account is rather the data contained in the account, and the address is the identifier for an account. In this sense I don't see a contradiction per se, but I agree that it could be confusing... One option would be to just use address everywhere (i.e. in parameter and method names). @gregorydemay do you have an opinion?

@lpahlavi lpahlavi merged commit 0a084f4 into main Jun 30, 2025
12 checks passed
@lpahlavi lpahlavi deleted the lpahlavi/basic-solana-candid-documentation branch June 30, 2025 08:02
@github-actions github-actions bot mentioned this pull request Jul 31, 2025
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.

3 participants

Comments