metaplex-foundation / shank

Extracts IDL from Solana Rust contracts
https://docs.rs/crate/shank_macro/latest
116 stars 23 forks source link

Shank has trouble with split state files #37

Open blockiosaurus opened 1 year ago

blockiosaurus commented 1 year ago

When I was attempting to refactor Token Metadata code, and split out feature specific state into its own state.rs file (as seen here https://github.com/metaplex-foundation/metaplex-program-library/tree/d4eb8783a2d34cb2a1da65aaf14aa3ac3cc2a3e1/token-metadata/program), it seemed like shank didn't properly extract all of the different states. When I tried to generate an API with Solita it looked like not all the types and structures were in the IDL and so API generation failed.