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

FIX: Neo.Network.RPC.Utility.RuleExpressionFromJson #791

Closed
Devel484 opened this issue Feb 20, 2023 · 0 comments · Fixed by #794
Closed

FIX: Neo.Network.RPC.Utility.RuleExpressionFromJson #791

Devel484 opened this issue Feb 20, 2023 · 0 comments · Fixed by #794

Comments

@Devel484
Copy link

Describe the bug
Fetching a block on testnet causes a crash in RPC Client.

Neo.Network.RPC.Models.RpcTransaction
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
   at Neo.Network.RPC.Utility.RuleExpressionFromJson(JObject json, ProtocolSettings protocolSettings)
   at Neo.Network.RPC.Utility.RuleFromJson(JObject json, ProtocolSettings protocolSettings)
   at Neo.Network.RPC.Utility.<>c__DisplayClass11_0.<SignerFromJson>b__0(JToken p)
   at System.Linq.Enumerable.SelectIListIterator`2.ToArray()
   at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
   at Neo.Network.RPC.Utility.SignerFromJson(JObject json, ProtocolSettings protocolSettings)
   at Neo.Network.RPC.Utility.<>c__DisplayClass9_0.<TransactionFromJson>b__0(JToken p)
   at System.Linq.Enumerable.SelectIListIterator`2.ToArray()
   at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
   at Neo.Network.RPC.Utility.TransactionFromJson(JObject json, ProtocolSettings protocolSettings)
   at Neo.Network.RPC.Utility.<>c__DisplayClass6_0.<BlockFromJson>b__0(JToken p)
   at System.Linq.Enumerable.SelectIListIterator`2.ToArray()
   at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
   at Neo.Network.RPC.Utility.BlockFromJson(JObject json, ProtocolSettings protocolSettings)
   at Neo.Network.RPC.Models.RpcBlock.FromJson(JObject json, ProtocolSettings protocolSettings)
   at Neo.Network.RPC.RpcClient.GetBlockAsync(String hashOrIndex)

To Reproduce
Steps to reproduce the behavior:

  1. Use N3 RPC 3.5.0
  2. Use any N3 Node(e.g. http://seed1t5.neo.org:20332)
  3. Query block 1048534
var block = await rpc.GetBlockAsync("1048534");
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

Successfully merging a pull request may close this issue.

1 participant