mathpaquette / IQFeed.CSharpApiClient

IQFeed.CSharpApiClient is fastest and the most well-designed C# DTN IQFeed socket API connector available
MIT License
121 stars 42 forks source link

Changed HistoricalDataTimeFormat to match API docs #33

Closed hunterfries closed 5 years ago

mathpaquette commented 5 years ago

@hunterfries in reality build is failing cause unit tests are disabled on AppVeyor. The SS custom format doesnt exist in C# but indeed hours are wrongly formatted.

hunterfries commented 5 years ago

I will update the format accordingly.

mathpaquette commented 5 years ago

@hunterfries, I think the problem is more related to Culture.Invariant because for timespan there's no HH SS format

https://docs.microsoft.com/en-us/dotnet/standard/base-types/custom-timespan-format-strings#the-hh-custom-format-specifier

mathpaquette commented 5 years ago

@hunterfries gimme your culture info.

hunterfries commented 5 years ago

en-US

Sent from my iPhone

On Mar 17, 2019, at 9:00 PM, Mathieu Paquette notifications@github.com<mailto:notifications@github.com> wrote:

@hunterfrieshttps://github.com/hunterfries gimme your culture info.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/mathpaquette/IQFeed.CSharpApiClient/pull/33#issuecomment-473734924, or mute the threadhttps://github.com/notifications/unsubscribe-auth/Ad2icAOmiRA9RqbazJy8AfGOr3g7v9Q3ks5vXuUjgaJpZM4b4iS6.

mathpaquette commented 5 years ago

@hunterfries the problem is somewhere else.

jphiggs commented 5 years ago

Not sure if this is related to @hunterfries' issue but over the weekend I was getting an IQFeed exception when using the BasicHistorical Example for Historical.ReqHistoryIntervalDaysAsync. The inner exception was "Invalid number of parameters'. That didn't occur with the other 2 historical requests in step 5 for that example. The exception also does not occur if I hard code the IQFeed request to var request = $"HID,AAPL,300,5,100,,,,,,{IQFeedDefault.ProtocolTerminatingCharacters}"; in the historical request formatter. Bottom line is that the formatter will include 7 commas for the optional parameters in the request and that is correct according to the IQFeed documenation, but the exception occurs with seven commas and works with 6. There are also several of the ApiClient tests that are failing for historical requests.