-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
feat: Add has_one relations inference so you don't need to pass accounts that are referenced by a has_one #2160
feat: Add has_one relations inference so you don't need to pass accounts that are referenced by a has_one #2160
Conversation
@ChewingGlass is attempting to deploy a commit to the coral-xyz Team on Vercel. A member of the Team first needs to authorize it. |
Nooahhhhh |
lang/syn/src/idl/file.rs
Outdated
@@ -18,6 +18,7 @@ pub fn parse( | |||
filename: impl AsRef<Path>, | |||
version: String, | |||
seeds_feature: bool, | |||
relations_feature: bool, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we combine this with the seeds_feature ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The nomenclature isn't accurate but the intention is the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Up to you. You mean keep the same name? seeds = true
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the package-lock.json file and the yarn error log.
…s/anchor into feature/relations-derivation
…nts that are referenced by a has_one (coral-xyz#2160)
This is similar to PDA inference. In typescript, you can now avoid passing to
.accounts()
accounts that can be resolved by fetching and pulling fields off of provided public keys.Also added a few handy methods I'd like to see. Can remove if needed.
See the tests/ repo for more details.