Skip to content

[N3 and N4] TokensTracker getnep17balances error #928

Closed

Description

@vncoelho

When balances are 0 it results correct.

requestJson = "{ \"jsonrpc\": \"2.0\", \"id\": 5, \"method\": \"getnep17balances\", \"params\": [\"" + adddressToGet + "\"] }";
Otherwise, it returns error

Object { jsonrpc: "2.0", id: 5, error: {…} }
​
error: Object { code: -2147467261, message: "Object reference not set to an instance of an object." }
​​
code: -2147467261
​​
message: "Object reference not set to an instance of an object."
​​
<prototype>: Object { … }
​
id: 5
​
jsonrpc: "2.0"

Activity

  1. vncoelho commented on Nov 26, 2025

    @vncoelho
    MemberAuthor
    Image
  2. changed the title [-][N4] TokensTracker getnep17balances error[/-] [+][N3 and N4] TokensTracker getnep17balances error[/+] on Nov 27, 2025
  3. vncoelho commented on Nov 27, 2025

    @vncoelho
    MemberAuthor

    updated to both branches, N3 and N4 with problems.

    Trying to verify

  4. vncoelho commented on Nov 27, 2025

    @vncoelho
    MemberAuthor
    neo> FATAL [19:34:32.113] 	System.IO.IOException
    Failed to bind to address http://0.0.0.0:30333: address already in use.
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.AddressBinder.BindEndpointAsync(ListenOptions endpoint, AddressBindContext context, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.ListenOptions.BindAsync(AddressBindContext context, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.AddressBinder.EndpointsStrategy.BindAsync(AddressBindContext context, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServerImpl.BindAsync(CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServerImpl.StartAsync[TContext](IHttpApplication`1 application, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken)
       at Microsoft.Extensions.Hosting.Internal.Host.<StartAsync>b__14_1(IHostedService service, CancellationToken token)
       at Microsoft.Extensions.Hosting.Internal.Host.ForeachService[T](IEnumerable`1 services, CancellationToken token, Boolean concurrent, Boolean abortOnFirstException, List`1 exceptions, Func`3 operation)
       at Microsoft.Extensions.Hosting.Internal.Host.StartAsync(CancellationToken cancellationToken)
       at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.Start(IHost host)
       at Neo.Plugins.RpcServer.RpcServer.StartRpcServer()
       at Neo.Plugins.RpcServer.RpcServerPlugin.OnSystemLoaded(NeoSystem system)
       at Neo.NeoSystem..ctor(ProtocolSettings settings, IStoreProvider storageProvider, String storagePath) in /opt/neo/src/Neo/NeoSystem.cs:line 153
       at Neo.NeoSystem..ctor(ProtocolSettings settings, String storageProvider, String storagePath) in /opt/neo/src/Neo/NeoSystem.cs:line 128
       at Neo.CLI.MainService.Start(CommandLineOptions options) in /opt/neo-node/src/Neo.CLI/CLI/MainService.cs:line 370
       at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__124_1(Object state)
       at System.Threading.ThreadPoolWorkQueue.Dispatch()
       at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()
       at System.Threading.Thread.StartCallback()
    
    Microsoft.AspNetCore.Connections.AddressInUseException
    Address already in use
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketConnectionListener.Bind()
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketTransportFactory.BindAsync(EndPoint endpoint, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure.TransportManager.BindAsync(EndPoint endPoint, ConnectionDelegate connectionDelegate, EndpointConfig endpointConfig, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServerImpl.<>c__DisplayClass28_0`1.<<StartAsync>g__OnBind|0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.AddressBinder.BindEndpointAsync(ListenOptions endpoint, AddressBindContext context, CancellationToken cancellationToken)
    
    System.Net.Sockets.SocketException
    Address already in use
       at System.Net.Sockets.Socket.UpdateStatusAfterSocketErrorAndThrowException(SocketError error, Boolean disconnectOnFailure, String callerName)
       at System.Net.Sockets.Socket.DoBind(EndPoint endPointSnapshot, SocketAddress socketAddress)
       at System.Net.Sockets.Socket.Bind(EndPoint localEP)
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketTransportOptions.CreateDefaultBoundListenSocket(EndPoint endpoint)
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketConnectionListener.Bind()
    
    Unhandled exception. System.IO.IOException: Failed to bind to address http://0.0.0.0:30333: address already in use.
     ---> Microsoft.AspNetCore.Connections.AddressInUseException: Address already in use
     ---> System.Net.Sockets.SocketException (98): Address already in use
       at System.Net.Sockets.Socket.UpdateStatusAfterSocketErrorAndThrowException(SocketError error, Boolean disconnectOnFailure, String callerName)
       at System.Net.Sockets.Socket.DoBind(EndPoint endPointSnapshot, SocketAddress socketAddress)
       at System.Net.Sockets.Socket.Bind(EndPoint localEP)
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketTransportOptions.CreateDefaultBoundListenSocket(EndPoint endpoint)
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketConnectionListener.Bind()
       --- End of inner exception stack trace ---
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketConnectionListener.Bind()
       at Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets.SocketTransportFactory.BindAsync(EndPoint endpoint, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure.TransportManager.BindAsync(EndPoint endPoint, ConnectionDelegate connectionDelegate, EndpointConfig endpointConfig, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServerImpl.<>c__DisplayClass28_0`1.<<StartAsync>g__OnBind|0>d.MoveNext()
    --- End of stack trace from previous location ---
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.AddressBinder.BindEndpointAsync(ListenOptions endpoint, AddressBindContext context, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.AddressBinder.BindEndpointAsync(ListenOptions endpoint, AddressBindContext context, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.ListenOptions.BindAsync(AddressBindContext context, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.AddressBinder.EndpointsStrategy.BindAsync(AddressBindContext context, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServerImpl.BindAsync(CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Server.Kestrel.Core.KestrelServerImpl.StartAsync[TContext](IHttpApplication`1 application, CancellationToken cancellationToken)
       at Microsoft.AspNetCore.Hosting.GenericWebHostService.StartAsync(CancellationToken cancellationToken)
       at Microsoft.Extensions.Hosting.Internal.Host.<StartAsync>b__14_1(IHostedService service, CancellationToken token)
       at Microsoft.Extensions.Hosting.Internal.Host.ForeachService[T](IEnumerable`1 services, CancellationToken token, Boolean concurrent, Boolean abortOnFirstException, List`1 exceptions, Func`3 operation)
       at Microsoft.Extensions.Hosting.Internal.Host.StartAsync(CancellationToken cancellationToken)
       at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.Start(IHost host)
       at Neo.Plugins.RpcServer.RpcServer.StartRpcServer()
       at Neo.Plugins.RpcServer.RpcServerPlugin.OnSystemLoaded(NeoSystem system)
       at Neo.NeoSystem..ctor(ProtocolSettings settings, IStoreProvider storageProvider, String storagePath) in /opt/neo/src/Neo/NeoSystem.cs:line 153
       at Neo.NeoSystem..ctor(ProtocolSettings settings, String storageProvider, String storagePath) in /opt/neo/src/Neo/NeoSystem.cs:line 128
       at Neo.CLI.MainService.Start(CommandLineOptions options) in /opt/neo-node/src/Neo.CLI/CLI/MainService.cs:line 370
       at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__124_1(Object state)
       at System.Threading.ThreadPoolWorkQueue.Dispatch()
       at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()
       at System.Threading.Thread.StartCallback()
    /opt/start_node.sh: line 2:   174 Aborted                 (core dumped) ( cd /opt/node/Neo.CLI/; dotnet neo-cli.dll )
  5. shargon commented on Nov 27, 2025

    @shargon
    Member

    This errors say that you have this port already open in your computer

  6. vncoelho commented on Nov 27, 2025

    @vncoelho
    MemberAuthor

    This errors say that you have this port already open in your computer

    This is another error here, I discovered what it is, I copied all *dlls from TokenTracker, it duplicated RpcServer.dll and caused this error.
    I will open another issue for this one. But the other remains

  7. vncoelho commented on Nov 27, 2025

    @vncoelho
    MemberAuthor

    I do know still what is causing TokensTracker getnep17balances to not function properly.
    I am not getting its result correctly

    root@a348be105d7c:/opt/node/Neo.CLI/TokenBalanceData# ls
    000013.log  000017.sst  CURRENT  IDENTITY  LOCK  LOG  LOG.old.1764272761829119  LOG.old.1764272831791423  MANIFEST-000014  OPTIONS-000011  OPTIONS-000016

    folder is being created

  8. superboyiii commented on Dec 1, 2025

    @superboyiii
    Member

    @shargon Victor is right, the same issue to me. Based on master-n3

    Image
  9. cschuchardt88 commented on Jan 8, 2026

    @cschuchardt88
    Member

    @vncoelho Problem is with RPC Server. Talk to @Wi1l-B0t or @Jim8y for method params binder.

    Image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions