File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44The format is based on [ Keep a Changelog] ( https://keepachangelog.com/en/1.0.0/ ) ,
55and this project adheres to [ Semantic Versioning] ( https://semver.org/spec/v2.0.0.html ) .
66
7+ # [ 3.0.8] 2025-07-15
8+
9+ - fix: subscribe candlesticks with ` Period::Day ` .
10+
711# [ 3.0.7] 2025-06-09
812
913- add ` AccountBalance.frozen_transaction_fees `
Original file line number Diff line number Diff line change @@ -672,23 +672,8 @@ impl Core {
672672 let mut tails = HashMap :: new ( ) ;
673673
674674 for candlestick in resp. candlesticks {
675- let time = OffsetDateTime :: from_unix_timestamp ( candlestick. timestamp )
676- . map_err ( |err| Error :: parse_field_error ( "timestamp" , err) ) ?
677- . to_timezone ( market. timezone ) ;
678- let ts = match market. candlestick_trade_session ( time) {
679- Some ( ts) => ts,
680- None => {
681- tracing:: error!(
682- symbol = symbol,
683- time = time
684- . format( & time:: format_description:: well_known:: Rfc3339 )
685- . unwrap( ) ,
686- "unknown trade session"
687- ) ;
688- return Err ( Error :: UnknownTradeSession { symbol, time } ) ;
689- }
690- } ;
691- let candlestick = candlestick. try_into ( ) ?;
675+ let candlestick: Candlestick = candlestick. try_into ( ) ?;
676+ let ts = convert_trade_session ( candlestick. trade_session ) ;
692677 let index = candlesticks. len ( ) ;
693678 candlesticks. push ( candlestick) ;
694679 tails. insert ( ts, TailCandlestick { index, candlestick } ) ;
You can’t perform that action at this time.
0 commit comments