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

Client generation error #121

Closed
topeolatunji19 opened this issue May 3, 2023 · 4 comments
Closed

Client generation error #121

topeolatunji19 opened this issue May 3, 2023 · 4 comments

Comments

@topeolatunji19
Copy link

Everytime I try using the anchorpy client-gen idl.json client command, I get this kind of error

apischema.validation.errors.ValidationError: ValidationError(messages=[], children={'instructions': ValidationError(messages=[], children={12: ValidationError(messages=[], children={'accounts': ValidationError(messages=[], children={2: ValidationError(messages=[], children={'isSigner': ValidationError(messages=['unexpected property'], children={}), 'accounts': ValidationError(messages=['missing property'], children={}), 'isMut': ValidationError(messages=['unexpected property'], children={}), 'isOptional': ValidationError(messages=['unexpected property', 'unexpected property'], children={})})})}), 16: ValidationError(messages=[], children={'accounts': ValidationError(messages=[], children={1: ValidationError(messages=[], children={'isSigner': ValidationError(messages=['unexpected property'], children={}), 'accounts': ValidationError(messages=['missing property'], children={}), 'isMut': ValidationError(messages=['unexpected property'], children={}), 'isOptional': ValidationError(messages=['unexpected property', 'unexpected property'], children={})})})}), 17: ValidationError(messages=[], children={'accounts': ValidationError(messages=[], children={1: ValidationError(messages=[], children={'isSigner': ValidationError(messages=['unexpected property'], children={}), 'accounts': ValidationError(messages=['missing property'], children={}), 'isMut': ValidationError(messages=['unexpected property'], children={}), 'isOptional': ValidationError(messages=['unexpected property', 'unexpected property'], children={})})})}), 18: ValidationError(messages=[], children={'accounts': ValidationError(messages=[], children={1: ValidationError(messages=[], children={'isSigner': ValidationError(messages=['unexpected property'], children={}), 'accounts': ValidationError(messages=['missing property'], children={}), 'isMut': ValidationError(messages=['unexpected property'], children={}), 'isOptional': ValidationError(messages=['unexpected property', 'unexpected property'], children={})})})})})})

And its the same for all idls I have tried. Not sure what the cause of this issue is

@kevinheavey
Copy link
Owner

Looks like an old version of AnchorPy, can you try the latest version?

@topeolatunji19
Copy link
Author

topeolatunji19 commented May 3, 2023

Done that, and now I get an error that says solders.SerdeJSONError: unknown variant `hashMap`, expected one of `bool`, `u8`, `i8`, `u16`, `i16`, `u32`, `i32`, `f32`, `u64`, `i64`, `f64`, `u128`, `i128`, `bytes`, `string`, `publicKey`, `defined`, `option`, `vec`, `array` at line 4419 column 7

@kevinheavey
Copy link
Owner

Same error as this then? #114

@topeolatunji19
Copy link
Author

Yes exactly

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

No branches or pull requests

2 participants