GithubHelp home page GithubHelp logo

bmresearch / solnet.anchor Goto Github PK

View Code? Open in Web Editor NEW
12.0 12.0 12.0 170 KB

C# Client code generation tools for Solana Anchor programs!

License: MIT License

C# 99.70% PowerShell 0.18% Shell 0.12%

solnet.anchor's People

Contributors

tiago18c avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

solnet.anchor's Issues

Value cannot be null (parameter 'source') when running idl.json created via Devnet

When running the anchorgen command with the json file the following error is thrown:

Unhandled exception. System.ArgumentNullException: Value cannot be null. (Parameter 'source')
at System.Linq.ThrowHelper.ThrowArgumentNullException(ExceptionArgument argument)
at System.Linq.Enumerable.Select[TSource,TResult](IEnumerable1 source, Func2 selector)
at Solnet.Anchor.ClientGenerator.GenerateGetAccounts(Idl idl) in /home/runner/work/Solnet.Anchor/Solnet.Anchor/Solnet.Anchor/ClientGenerator.cs:line 1524
at Solnet.Anchor.ClientGenerator.GenerateClientSyntaxTree(Idl idl) in /home/runner/work/Solnet.Anchor/Solnet.Anchor/Solnet.Anchor/ClientGenerator.cs:line 904
at Solnet.Anchor.ClientGenerator.GenerateSyntaxTree(Idl idl) in /home/runner/work/Solnet.Anchor/Solnet.Anchor/Solnet.Anchor/ClientGenerator.cs:line 71
at Solnet.Anchor.ClientGenerator.GenerateCode(Idl idl) in /home/runner/work/Solnet.Anchor/Solnet.Anchor/Solnet.Anchor/ClientGenerator.cs:line 84
at AnchorSourceGenerator.<>c.

b__0_1(CommandLineOptions opts) in /home/runner/work/Solnet.Anchor/Solnet.Anchor/Solnet.Anchor.Tool/AnchorSourceGenerator.cs:line 56
at CommandLine.ParserResultExtensions.MapResult[TSource,TResult](ParserResult1 result, Func2 parsedFunc, Func`2 notParsedFunc)
at AnchorSourceGenerator.Main(String[] args) in /home/runner/work/Solnet.Anchor/Solnet.Anchor/Solnet.Anchor.Tool/AnchorSourceGenerator.cs:line 19

[Bug]

Describe the bug
dotnet anchorgen crushes when there are docs section in the type

To Reproduce
In rust code add docs to any account by triple slash. Whan anchor generate idl, it will add "docs" to json

Expected behavior
Generator should ignore docs or, better, add docs to generated account model

Screenshots
image

[Bug]

I want to install the new version,
first of all, I decided to update the installed version of Solnet.Anchor.Tool, so vs code terminal stuck, I waited for a while but nothing happened.
after that, I decided to remove the installed version and install it again, so the result was the same and the terminal is stuck without any result.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.