¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

No response from TWS after moving from 973.2g to 981 or 985


 

I'm trying to move from 973.2g to a later version.? I am able to connect and receive several data farm messages, but my requests for account updates and other services are ignored.

Does anyone have an idea of what's going on?

Without any prior warning, TWS terminated on me this morning 40 minutes before the market open with a message that 973.2g is no longer supported.? They used to give me several weeks of warning.? Fortunately 973.2g was working on another computer so I was able to get up & running 5 minutes before the market opened.

I'm using an old c api interface.? There is no activity on the port after submitting the account update request.? It's as if TWS is completely ignoring the request.? If I submit an order on TWS it is not sent to my program.

Any ideas?


 

Do you have api logging turned on?? Check the api.day.id.log file to see if the request is sent.


Nick
 

IB sometimes sets a new minimum allowable TWS version but I don't remember them doing that with Api versions. I can't seem to find release notes that talk about minimum versions but maybe someone has seen something about recent minimum version changes.

On 8/20/2021 5:52 PM, Frank Bell via groups.io wrote:
I'm trying to move from 973.2g to a later version.? I am able to connect and receive several data farm messages, but my requests for account updates and other services are ignored.

Does anyone have an idea of what's going on?


 

I do have api message logging turned on.? There are no entries when I use 981 or later.? I do get them with 973.2g.


 

To the best of my knowledge they've never set a minimum api level.? I don't think that's it.? There's something really basic wrong.

On Friday, August 20, 2021, 06:32:31 PM EDT, Nick <news1000@...> wrote:


IB sometimes sets a new minimum allowable TWS version but I don't
remember them doing that with Api versions. I can't seem to find release
notes that talk about minimum versions but maybe someone has seen
something about recent minimum version changes.


On 8/20/2021 5:52 PM, Frank Bell via groups.io wrote:
> I'm trying to move from 973.2g to a later version.? I am able to
> connect and receive several data farm messages, but my requests for
> account updates and other services are ignored.
>
> Does anyone have an idea of what's going on?







 

Well, there are a couple error codes that indicate that TWS or the client API are out of date:

  • 357??? Your client version is out of date.
  • 503??? The TWS is out of date and must be upgraded.
Any chance you get one of those?
There have been a few API changes lately, such as increasing size fields from int (lots or 100) to long (shares) in 985 that may require a more selective version combination between client and TWS.
´³¨¹°ù²µ±ð²Ô


 

No, I log all errors and the only one I get is 2158, a data farm connection is ok message.

On Friday, August 20, 2021, 07:28:32 PM EDT, ´³¨¹°ù²µ±ð²Ô Reinold via groups.io <twsapiongroupsio@...> wrote:


Well, there are a couple error codes that indicate that TWS or the client API are out of date:

  • 357??? Your client version is out of date.
  • 503??? The TWS is out of date and must be upgraded.
Any chance you get one of those?
There have been a few API changes lately, such as increasing size fields from int (lots or 100) to long (shares) in 985 that may require a more selective version combination between client and TWS.
´³¨¹°ù²µ±ð²Ô


 

On Fri, Aug 20, 2021 at 07:04 PM, Frank Bell wrote:
I do have api message logging turned on.? There are no entries when I use 981 or later.? I do get them with 973.2g.

You should at least have up to the error messages like,

06:45:08:822 -> ---74-2--1-2104-Market data farm connection is OK:cashfarm-

If that's not in your api log file and you say you get the connection messages in your program and you think your logging is on, something is wrong.

I doubt your problem was like mine but when I got the same upgrade message my program didn't work because I use 7496/7 in gateway and had to go change it.? The defaults I noticed were
-read only api
-port 4002 (Gateway)
-allow api clients
-from local host only

?


 

In these cases I like to get "a second opinion" (as in use a completely different client) to see whether the problem is on the client or server side. My goto client is Richard King's "Contract Inspector". Just fire it up, connect to your TWS and grab some contract details. It that works, focus on your API. If not, something is out of balance with the TWS or the network between client and TWS.


 

I get the data farm connection error messages with 973.2g, but can find no api message log file with 981 or 985.? I did find some api.0.date.time.ibgzenc files, which are not text. "Create api message log file" is checked and logging level is "detail."

I use ports 7496, 7497, and 7942.? None work with 981 or 985.

On Friday, August 20, 2021, 08:26:27 PM EDT, btw <newguyanon@...> wrote:


On Fri, Aug 20, 2021 at 07:04 PM, Frank Bell wrote:
I do have api message logging turned on.? There are no entries when I use 981 or later.? I do get them with 973.2g.

You should at least have up to the error messages like,

06:45:08:822 -> ---74-2--1-2104-Market data farm connection is OK:cashfarm-

If that's not in your api log file and you say you get the connection messages in your program and you think your logging is on, something is wrong.

I doubt your problem was like mine but when I got the same upgrade message my program didn't work because I use 7496/7 in gateway and had to go change it.? The defaults I noticed were
-read only api
-port 4002 (Gateway)
-allow api clients
-from local host only

?


 

Log files are encrypted but you can go to Account -> Diagnostics -> ApiLogs in TWS to decrypt them.


On Fri, Aug 20, 2021 at 08:53 PM, Frank Bell wrote:
ibgzenc


 

Thanks Jurgen.? It probably would have taken me ages to figure out how to look at the log.

The logs gave me enough information to identify a deadlock in my code.? The event sequence must have changed slightly revealing the bug.? Now all have to do is figure out a fix.

Thanks All, your help has been much appreciated.

Frank


On Friday, August 20, 2021, 10:19:23 PM EDT, ´³¨¹°ù²µ±ð²Ô Reinold via groups.io <twsapiongroupsio@...> wrote:


Log files are encrypted but you can go to Account -> Diagnostics -> ApiLogs in TWS to decrypt them.


On Fri, Aug 20, 2021 at 08:53 PM, Frank Bell wrote:
ibgzenc


 

Are you sure to retire IBC?
For a reliable ? 24/7-Setup its still necessary. After a shutdown for whatever a reason, you get a clean start.

In ib-container ()? its included in the cron-facility.
This leads to a very robust IB-Gateway-Implementation.


Nick
 

I don't remember the details now, but at some point TWS started sending an additional (unrequested) message upon connection, I think ManagedAccounts. I had to update my library to parse this message since I hadn't needed it previously. This was before the 'V100' protocol so there were no length headers that allowed a client to skip over messages it wasn't interested in.

One of the sneakier aspects of using the TWS APi is that you can't assume anything about the order of messages. Hopefully it won't be too much of an effort to get back going.

On 8/20/2021 11:14 PM, Frank Bell via groups.io wrote:
The logs gave me enough information to identify a deadlock in my code.? The event sequence must have changed slightly revealing the bug.? Now all have to do is figure out a fix.