codama-idl / codama

Generate clients, CLIs, documentation and more from your Solana programs
MIT License
73 stars 16 forks source link

Fully Support Anchor 0.30.0 IDL Seed Spec #42

Closed kespinola closed 3 months ago

kespinola commented 4 months ago

Background

The original release of anchor 0.30.0 only shipped with basic account and const support.

Goal

Support the complete seed specification.

Changes

Next Step

changeset-bot[bot] commented 4 months ago

🦋 Changeset detected

Latest commit: 973fe2af27d1bab57bf4606eebf4e8bf434ffc7b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 13 packages | Name | Type | | ---------------------------- | ----- | | @kinobi-so/nodes-from-anchor | Minor | | @kinobi-so/errors | Minor | | @kinobi-so/nodes | Minor | | @kinobi-so/renderers-js | Patch | | kinobi | Minor | | @kinobi-so/renderers-core | Patch | | @kinobi-so/renderers-js-umi | Patch | | @kinobi-so/renderers-rust | Patch | | @kinobi-so/validators | Minor | | @kinobi-so/visitors-core | Minor | | @kinobi-so/visitors | Minor | | @kinobi-so/renderers | Patch | | @kinobi-so/node-types | Minor |

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

lorisleiva commented 4 months ago

Regarding the e2e tests, you shouldn't need to update dependencies or use relative path since the monorepo will understand they are local packages. You just need to make sure you are running the e2e tests from the package directory — e.g. cd packages/renderers-js && pnpm test:e2e.

One thing you could do is duplicate the system e2e folder for example and name it system-from-anchor. Then you just need to update the generateProject function so it uses rootNodeFromAnchor instead of rootNode.

kespinola commented 4 months ago

Regarding the e2e tests, you shouldn't need to update dependencies or use relative path since the monorepo will understand they are local packages. You just need to make sure you are running the e2e tests from the package directory — e.g. cd packages/renderers-js && pnpm test:e2e.

One thing you could do is duplicate the system e2e folder for example and name it system-from-anchor. Then you just need to update the generateProject function so it uses rootNodeFromAnchor instead of rootNode.

I'll get a e2e test in place. I started on it before but stopped.

kespinola commented 4 months ago

Regarding the e2e tests, you shouldn't need to update dependencies or use relative path since the monorepo will understand they are local packages. You just need to make sure you are running the e2e tests from the package directory — e.g. cd packages/renderers-js && pnpm test:e2e. One thing you could do is duplicate the system e2e folder for example and name it system-from-anchor. Then you just need to update the generateProject function so it uses rootNodeFromAnchor instead of rootNode.

I'll get a e2e test in place. I started on it before but stopped.

And FYI on this. I was linking to external project.

kespinola commented 3 months ago

Sorry on lagging on this @lorisleiva. It now handles all seed permutations.

kespinola commented 3 months ago

@lorisleiva thanks for fixing up the lock. I am good to merge when you are.