Open domvoe opened 1 year ago
Difficult to say without a way to reproduce. Here are some thoughts that first come to mind:
I typically see that error when TWS suddenly and unilaterally closes the connection. This used to be a common occurrence before TWS 10.16 due to violating pacing rules (e.g. generating more than 50 requests per second). However, since TWS 10.16 this shouldn't happen with default settings. More on pacing errors in this comment.
Other reasons might cause a disconnection. Check the DATA
tab on the upper right corner of TWS to make sure the client is still connected.
Some other network hiccups might garble the incoming messages queue and put it in an irrecoverable state. By tracing back the very first error message that appears might give some clues on the origin of the problem.
If reporting back, additional information can be useful such as OS, TWS version, rib
version and any other error messages.
Thanks a lot for your fast reply.
The last days I tested the TWS option which was referenced in the first bullet point. The system is now running more stable, but sometimes the error is still popping up.
I use Windows and the recent versions of TWS (10.20) and rib (0.19). The random behaviour makes the debugging hard. But I will still try and let you know in case I find something relevant.
Again many thanks for your help.
I used to get this error when I tried to open a connection via ic$connect that was already open (e.g. had not been properly closed earlier) with the same parameters (clientId, port)
Many thanks sharing this package.
I already use it a while and randomly get the follwing error: Error in readBin(private$socket, raw(), n = len) : invalid 'n' argument
The strange thing ist that this error is showing up randomly, i.e. when I run the same code 10 times in a row it can be that no error is showing up, but the next time each other request is showing the error.
Do you have an idea how this can happen? Your help is really appreciated.
Here is an example code snippet with reponse from the console: