@@ -30,7 +30,7 @@ impl MboMsg {
3030 side,
3131 ts_recv,
3232 flags = None ,
33- channel_id = 0 ,
33+ channel_id = None ,
3434 ts_in_delta = 0 ,
3535 sequence = 0 ,
3636 ) ) ]
@@ -45,7 +45,7 @@ impl MboMsg {
4545 side : Side ,
4646 ts_recv : u64 ,
4747 flags : Option < FlagSet > ,
48- channel_id : u8 ,
48+ channel_id : Option < u8 > ,
4949 ts_in_delta : i32 ,
5050 sequence : u32 ,
5151 ) -> PyResult < Self > {
@@ -55,7 +55,7 @@ impl MboMsg {
5555 price,
5656 size,
5757 flags : flags. unwrap_or_default ( ) ,
58- channel_id,
58+ channel_id : channel_id . unwrap_or ( u8 :: MAX ) ,
5959 action : action as u8 as c_char ,
6060 side : side as u8 as c_char ,
6161 ts_recv,
@@ -1538,7 +1538,7 @@ impl InstrumentDefMsg {
15381538 raw_instrument_id = 0 ,
15391539 leg_price = UNDEF_PRICE ,
15401540 leg_delta = UNDEF_PRICE ,
1541- inst_attrib_value = 0 ,
1541+ inst_attrib_value = None ,
15421542 underlying_id = 0 ,
15431543 market_depth_implied = None ,
15441544 market_depth = None ,
@@ -1560,7 +1560,7 @@ impl InstrumentDefMsg {
15601560 appl_id = None ,
15611561 maturity_year = None ,
15621562 decay_start_date = None ,
1563- channel_id = 0 ,
1563+ channel_id = None ,
15641564 leg_count = 0 ,
15651565 leg_index = 0 ,
15661566 currency = "" ,
@@ -1612,7 +1612,7 @@ impl InstrumentDefMsg {
16121612 raw_instrument_id : u64 ,
16131613 leg_price : i64 ,
16141614 leg_delta : i64 ,
1615- inst_attrib_value : i32 ,
1615+ inst_attrib_value : Option < i32 > ,
16161616 underlying_id : u32 ,
16171617 market_depth_implied : Option < i32 > ,
16181618 market_depth : Option < i32 > ,
@@ -1634,7 +1634,7 @@ impl InstrumentDefMsg {
16341634 appl_id : Option < i16 > ,
16351635 maturity_year : Option < u16 > ,
16361636 decay_start_date : Option < u16 > ,
1637- channel_id : u16 ,
1637+ channel_id : Option < u16 > ,
16381638 leg_count : u16 ,
16391639 leg_index : u16 ,
16401640 currency : & str ,
@@ -1684,7 +1684,7 @@ impl InstrumentDefMsg {
16841684 raw_instrument_id,
16851685 leg_price,
16861686 leg_delta,
1687- inst_attrib_value,
1687+ inst_attrib_value : inst_attrib_value . unwrap_or ( i32 :: MAX ) ,
16881688 underlying_id,
16891689 market_depth_implied : market_depth_implied. unwrap_or ( i32:: MAX ) ,
16901690 market_depth : market_depth. unwrap_or ( i32:: MAX ) ,
@@ -1706,7 +1706,7 @@ impl InstrumentDefMsg {
17061706 appl_id : appl_id. unwrap_or ( i16:: MAX ) ,
17071707 maturity_year : maturity_year. unwrap_or ( u16:: MAX ) ,
17081708 decay_start_date : decay_start_date. unwrap_or ( u16:: MAX ) ,
1709- channel_id,
1709+ channel_id : channel_id . unwrap_or ( u16 :: MAX ) ,
17101710 leg_count,
17111711 leg_index,
17121712 currency : str_to_c_chars ( currency) ?,
@@ -2280,7 +2280,7 @@ impl StatMsg {
22802280 stat_type,
22812281 sequence = 0 ,
22822282 ts_in_delta = 0 ,
2283- channel_id = 0 ,
2283+ channel_id = None ,
22842284 update_action = None ,
22852285 stat_flags = 0 ,
22862286 ) ) ]
@@ -2295,7 +2295,7 @@ impl StatMsg {
22952295 stat_type : StatType ,
22962296 sequence : u32 ,
22972297 ts_in_delta : i32 ,
2298- channel_id : u16 ,
2298+ channel_id : Option < u16 > ,
22992299 update_action : Option < StatUpdateAction > ,
23002300 stat_flags : u8 ,
23012301 ) -> PyResult < Self > {
@@ -2308,7 +2308,7 @@ impl StatMsg {
23082308 sequence,
23092309 ts_in_delta,
23102310 stat_type : stat_type as u16 ,
2311- channel_id,
2311+ channel_id : channel_id . unwrap_or ( u16 :: MAX ) ,
23122312 update_action : update_action. unwrap_or_default ( ) as u8 ,
23132313 stat_flags,
23142314 _reserved : Default :: default ( ) ,
@@ -3363,7 +3363,7 @@ impl v1::StatMsg {
33633363 stat_type,
33643364 sequence = 0 ,
33653365 ts_in_delta = 0 ,
3366- channel_id = 0 ,
3366+ channel_id = None ,
33673367 update_action = None ,
33683368 stat_flags = 0 ,
33693369 ) ) ]
@@ -3378,7 +3378,7 @@ impl v1::StatMsg {
33783378 stat_type : StatType ,
33793379 sequence : u32 ,
33803380 ts_in_delta : i32 ,
3381- channel_id : u16 ,
3381+ channel_id : Option < u16 > ,
33823382 update_action : Option < StatUpdateAction > ,
33833383 stat_flags : u8 ,
33843384 ) -> PyResult < Self > {
@@ -3391,7 +3391,7 @@ impl v1::StatMsg {
33913391 sequence,
33923392 ts_in_delta,
33933393 stat_type : stat_type as u16 ,
3394- channel_id,
3394+ channel_id : channel_id . unwrap_or ( u16 :: MAX ) ,
33953395 update_action : update_action. unwrap_or_default ( ) as u8 ,
33963396 stat_flags,
33973397 _reserved : Default :: default ( ) ,
0 commit comments