Keyboard Shortcuts
ctrl + shift + ? :
Show all keyboard shortcuts
ctrl + g :
Navigate to a group
ctrl + shift + f :
Find
ctrl + / :
Quick actions
esc to dismiss
Likes
- Twsapi
- Messages
Search
Re: Delay of about a minute or so for the API orders to show up on TWS
Nick
¿ªÔÆÌåÓýValid point. There are enough active traders here that anything widespread would probably get a mention. It could be something affecting only certain instruments. Hope it all goes back to normal for you. On 3/24/2022 11:53 AM, Lou Dudka wrote:
HI Nick, |
Delay of about a minute or so for the API orders to show up on TWS
HI Nick,
I agree that not to much emphasis should be placed on paper trades. However, in all my experience over the years, IB paper has been a fairly accurate barometer of live trading. I'm only noting this because I feel IB made some changes that are affect others .... Thanks, as always, and Be Well, Lou Dudka |
Re: Delay of about a minute or so for the API orders to show up on TWS
Nick
¿ªÔÆÌåÓýEveryone has different experiences but I don't think you can make meaningful connections between fills on paper account and live. You just don't know what would have happened on live. If you are seeing a paper account behave different than usual it
might mean something, but again, doesn't tell you what would have
happened on live. On 3/24/2022 11:37 AM, Lou Dudka wrote:
And yes, the order is for 2300 shrs, but I should've received at least a partial fill. |
Delay of about a minute or so for the API orders to show up on TWS
HI All,
I experienced a no-fill (as of now) on the paper trading system today on a STPLMT bracket entry order: OSTK 2330 Shrs short TRIG: 48.22? LMT: 48.22 The trigger fired at about 9:40 AM and hasn't filled, though it looks like it should.? Not a big deal, since is paper, but a bit concerning bc of problems others are having ... Thanks, as always, and Be Well, Lou Dudka |
Re: Delay of about a minute or so for the API orders to show up on TWS
Nick
The first step is to enable api logging and look to see when the order arrived at TWS. This will give clues as to whether the issue is in TWS or on the client side.
toggle quoted message
Show quoted text
On 3/23/2022 9:16 PM, Ketan via groups.io wrote:
On live account, today, I experienced API order not showing up on TWS for quite some time, and by which time, the targeted price moved away. |
Re: Connection disconnects immediately after connect with PACEAPI enabled
¿ªÔÆÌåÓý
Waiting for the nextValidID callback before calling other API seems to have fixed the issue.? Thanks for your help.
From: [email protected] <[email protected]> on behalf of ´³¨¹°ù²µ±ð²Ô Reinold via groups.io <TwsApiOnGroupsIo@...>
Sent: Tuesday, March 22, 2022 8:17 PM To: [email protected] <[email protected]> Subject: Re: [TWS API] Connection disconnects immediately after connect with PACEAPI enabled ?
Crow,
the issue with your code is not the .setConnectOptions("+PACEAPI") call. It is rather the location (timing) of the reqPosition() and reqMarketDataType() calls. You might want to reread the section in the API Reference Guide. You should not send any request toe TWS API until you have received the BApi.EWrapper.nextValidID callback. That is your indication that all API components have been initialized properly and messages can flow in both directions. Your code calls reqPosition() and reqMarketDataType() before that callback has arrived. There are other areas that can be improved. The ApiContoller.java file in the IBKR API distribution is a very good example of how you might want to structure your interface with the TWS API. ´³¨¹°ù²µ±ð²Ô |
Delay of about a minute or so for the API orders to show up on TWS
On live account, today, I experienced API order not showing up on TWS for quite some time, and by which time, the targeted price moved away.
And similar order, entered through TWS interface executes right away. Please share if there are ways in which to mitigate latencies from API to TWS. Thanks, Ketan |
Re: Re-login failures with TWS auto-restart option.
Hi ´³¨¹°ù²µ±ð²Ô,
Thanks for the reply! I'm running stand-alone older TWS version Build 981.3c, Jun 29, 2021.? Win7. Old dual-processor Lenovo E545, 12GB RAM, 256GB SSD. It's not a deal breaker since I'm usually around to check.? I'll keep you updated if it happens again, especially this week. Thanks, as always, and be well, Lou Dudka |
Re: Re-login failures with TWS auto-restart option.
That's about the time when our TWS restarts take place as well, Lou and we did not have an issue for a long time (maybe a couple years).
toggle quoted message
Show quoted text
Are you running "standalone/offline" versions of TWS or the automatically updating versions? Auto restart may fail if TWS decides that it needs to auto-update as well. And it looks like new TWS versions must have been released within the last day or two (e.g. since i last checked on Sunday). . We run standalone versions only. ´³¨¹°ù²µ±ð²Ô On Wed, Mar 23, 2022 at 05:44 PM, Lou Dudka wrote: I had the problem today Monday 03/23/22 at about 5:20 and 5:25 PM NYT when both the paper and production systems are supposed auto-restart.? Both instances of TWS are running on the same box to save data access fees.? Lots of cycles available. |
Re: Re-login failures with TWS auto-restart option.
Hi Mark,
Thanks for the input. Can't swear to it, but yeah, the "soft token" error might be it. I just rebooted the computer yesterday evening about six, so it shouldn't complain about the Sunday re-boot. I had the problem today Monday 03/23/22 at about 5:20 and 5:25 PM NYT when both the paper and production systems are supposed auto-restart.? Both instances of TWS are running on the same box to save data access fees.? Lots of cycles available. Thanks, as always, and be well, Lou Dudka |
Re: Re-login failures with TWS auto-restart option.
I get a? "soft token" error where it complains about expecting a different token every sunday. I assume this is when it expires the week long session token. Is that what you are seeing? Best wishes, M On Wed, 23 Mar 2022 at 21:38, Lou Dudka <loududka@...> wrote: Hi All, -- +44 (0) 7528 551604? Gulfstream Software - Winner Risk Management Awards 2010 This message is subject to : |
Re-login failures with TWS auto-restart option.
Hi All,
I've been experiencing problems with the TWS auto-restart options, I'm getting some type of "token error" and have to completely shut down TWS and manually re-start it and manually log on.? It's sporadic, maybe every couple of days and has been happening for the last week or so. This is on both production and paper accounts.? Haven't changed anything (to the best of this fading memory). Anyone else experiencing this problem? Thanks, as always, and be well, Lou Dudka |
Re: Connection disconnects immediately after connect with PACEAPI enabled
Crow,
the issue with your code is not the .setConnectOptions("+PACEAPI") call. It is rather the location (timing) of the reqPosition() and reqMarketDataType() calls. You might want to reread the section in the API Reference Guide. You should not send any request toe TWS API until you have received the BApi.EWrapper.nextValidID callback. That is your indication that all API components have been initialized properly and messages can flow in both directions. Your code calls reqPosition() and reqMarketDataType() before that callback has arrived. There are other areas that can be improved. The ApiContoller.java file in the IBKR API distribution is a very good example of how you might want to structure your interface with the TWS API. ´³¨¹°ù²µ±ð²Ô |
Connection disconnects immediately after connect with PACEAPI enabled
¿ªÔÆÌåÓý
The attached Java sample will connect to TWS, but then immediately disconnect (printing "Connection Closed") when I have?m_client.setConnectOptions("+PACEAPI"); uncommented.? After that, I can reconnect without issue even with +PACEAPI present.? So it only
happens on the first time (until I restart TWS Gateway / Desktop). If I do not have +PACEAPI enabled, there is no issue.? Anyone see what I am doing wrong?
|
Re: TWS 50/sec limit
Nick
I believe the OP is asking if the limit can avoided, not whether the error can be avoided. Pacing the requests does not avoid the limit but does avoid the error.
toggle quoted message
Show quoted text
On 3/22/2022 1:49 PM, Bob Rosum wrote:
It is possible to avoid this limit error, I have done so in my platform by throttling the messages sent to the gateway by inserting a delay between each message |
to navigate to use esc to dismiss