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 basics/close-account/poseidon #161

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

adpthegreat
Copy link
Contributor

@adpthegreat adpthegreat commented Oct 20, 2024

  • added poseidon close_account program to basics/close-program folder
  • updated dependencies to use latest versions of anchor
  • used pnpm in place of yarn, , replaced all instances of yarn with pnpm
  • wrote solana bankrun tests
  • ran pnpm fix
Screenshot 2024-10-29 at 11 22 14

@adpthegreat adpthegreat changed the title Add basics/poseidon/close-accounts Add basics/close-accounts/poseidon Oct 20, 2024
@adpthegreat adpthegreat changed the title Add basics/close-accounts/poseidon Add basics/close-account/poseidon Oct 20, 2024
Copy link

@Yangatech Yangatech left a comment

Choose a reason for hiding this comment

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

Instead of using u8 for the name field, consider using a String or a fixed-size byte array for more practical usage. Ensure the allocated account space matches the actual size needed for the UserAccount struct. Add logging with msg! to track key actions like account creation and closure.

Choose a reason for hiding this comment

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

storing the name as a u8 may limit usability; switching to a string or byte array would be better.

@adpthegreat
Copy link
Contributor Author

adpthegreat commented Oct 22, 2024

Poseidon does not currently support strings or fixed sized byte arrays so i did that to improvise, i think its best i removed it, also poseidon does not support msg()! macro

@Yangatech
Copy link

Yangatech commented Oct 22, 2024 via email

@heyAyushh heyAyushh added contribute:poseidon Adds a poseidon example contribution to the repository. close-account basics/close-account labels Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
close-account basics/close-account contribute:poseidon Adds a poseidon example contribution to the repository.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants