[ts-gen] Fix for select exec
Bill Pippin
pippin at owlriver.net
Tue Oct 6 18:45:43 EDT 2009
Ken,
About the silent regression for the select exec command, which is
intended to trigger a request for execution reports:
> I can't figure out how to "select exec..." ... I've tried ...
> None of these seem to work, and I'm out of ideas.
First off, I've pushed a new release that fixes the problem, so
feel free to download it and try it out.
Thanks again for your bug report. No one else had seen this ---
exec reports arrive unsolicited after submitted orders execute,
so evidently most scripts are not sensitive to the problem ---
and I'm now working to improve the regression test setup to
catch this problem, about which more in a later post.
By the way, about my earlier concern that the execution report
requests as submitted by the shim were too vague: using the
IB sample client, I've verified that just about anything without
specifically wrong data, including a mixture of only zeroes and
blanks, works. Our form of the filter requires a symbol and
earliest time, which is reasonably specific.
Now, for explanations and details:
As noted previously, the exec report command silently stopped
working somewhere along the line with one of the IB tws releases
of this year. Using the the IB sample client sources, I can
verify that non-null time filter values --- and the shim's exec
report command requires a non-blank time value, if only 00:00:00
--- work only with the newer event version 3, and have stopped
working for event version 2.
>From the NEWS file:
* Fix execution reports request format problem by incrementing
the event version from 2 to 3, so that the select exec cmd
again works; it had silently stopped working. Thanks to Ken
for finding this bug.
Note in the following explanation that the request execution
report format has been constant since api level 9, so that
the actual format has been effectively constant over time;
that the date-time attribute of the filter is actually a
time value, even though comments in the sample client
sources claim that a yyyymmdd-hh:mm:ss string is required;
and that the only symptom for a variety of invalid inputs
is no return exec reports, rather than some more specific
error message. Note also that event versions are per event,
are often but not always small integers, and differ radically
from, but should be correlated with, the api level, currently
now in the 40s.
The increase in event version is to compensate for a silent
upstream slippage, whereby the IB tws used to accept exec
report requests, a non-blank time filter attribute at event
version 2, and now only accepts non blank times for event
version 3. This has been verified using the IB sample
client sources; if the time attribute of the filter is blank
(wildcard), or the version is 3, the request works to trigger
execution reports, and otherwise not.
Thanks,
Bill
More information about the ts-general
mailing list