Skip to content

Commit

Permalink
[DXFC-413] Incorrect date handling when system calendar is set to Bud…
Browse files Browse the repository at this point in the history
…dhist calendar
  • Loading branch information
AnatolyKalin authored Feb 21, 2025
2 parents e86421d + 5060020 commit 54b9764
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
2 changes: 2 additions & 0 deletions ReleaseNotes.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
* [DXFC-413] Incorrect date handling when system calendar is set to Buddhist calendar

Version 8.8.2
* [DXFC-400] Fixed a bug with passing a UNICODE path to a file as a parameter of the logging initialization and settings loading function.
- For the changes to work reliably, you need to set the default encoding to UTF-8, for example, as indicated by the link:
Expand Down
10 changes: 5 additions & 5 deletions dxf_native/src/CandleDataConnection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Net;
using System.Text;
Expand Down Expand Up @@ -126,11 +127,10 @@ private static string CreateQuery(IEnumerable<CandleSymbol> symbols, DateTime fr
{
return "records=Candle&" +
$"symbols={string.Join(",", symbols).Replace("&", "[%26]")}&" +
$"start={fromTime.ToUniversalTime():yyyyMMdd-HHmmss}Z&" +
$"stop={toTime.ToUniversalTime():yyyyMMdd-HHmmss}Z&" +
$"start={fromTime.ToUniversalTime().ToString("yyyyMMdd-HHmmss", CultureInfo.InvariantCulture)}Z&" +
$"stop={toTime.ToUniversalTime().ToString("yyyyMMdd-HHmmss", CultureInfo.InvariantCulture)}Z&" +
"format=binary&" +
"compression=zip&" +
"skipServerTimeCheck";
"compression=zip";
}
}
}
}
10 changes: 5 additions & 5 deletions dxf_native/src/TimeAndSaleDataConnection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

using System;
using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Net;
using System.Text;
Expand Down Expand Up @@ -125,11 +126,10 @@ private static string CreateQuery(IEnumerable<string> symbols, DateTime fromTime
{
return "records=TimeAndSale&" +
$"symbols={string.Join(",", symbols).Replace("&", "[%26]")}&" +
$"start={fromTime.ToUniversalTime():yyyyMMdd-HHmmss}Z&" +
$"stop={toTime.ToUniversalTime():yyyyMMdd-HHmmss}Z&" +
$"start={fromTime.ToUniversalTime().ToString("yyyyMMdd-HHmmss", CultureInfo.InvariantCulture)}Z&" +
$"stop={toTime.ToUniversalTime().ToString("yyyyMMdd-HHmmss", CultureInfo.InvariantCulture)}Z&" +
"format=binary&" +
"compression=zip&" +
"skipServerTimeCheck";
"compression=zip";
}
}
}
}

0 comments on commit 54b9764

Please sign in to comment.