Skip to content

Commit

Permalink
change notional format for to_dict function in instruments
Browse files Browse the repository at this point in the history
  • Loading branch information
filipmacek committed Apr 26, 2024
1 parent d78d1b2 commit 7b4d0a5
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions nautilus_trader/model/instruments/base.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -318,8 +318,8 @@ cdef class Instrument(Data):
"lot_size": str(obj.lot_size) if obj.lot_size is not None else None,
"max_quantity": str(obj.max_quantity) if obj.max_quantity is not None else None,
"min_quantity": str(obj.min_quantity) if obj.min_quantity is not None else None,
"max_notional": obj.max_notional.to_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_str() if obj.min_notional is not None else None,
"max_notional": obj.max_notional.to_raw_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_raw_str() if obj.min_notional is not None else None,
"max_price": str(obj.max_price) if obj.max_price is not None else None,
"min_price": str(obj.min_price) if obj.min_price is not None else None,
"margin_init": str(obj.margin_init),
Expand Down
4 changes: 2 additions & 2 deletions nautilus_trader/model/instruments/cfd.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -236,8 +236,8 @@ cdef class Cfd(Instrument):
"lot_size": str(obj.lot_size) if obj.lot_size is not None else None,
"max_quantity": str(obj.max_quantity) if obj.max_quantity is not None else None,
"min_quantity": str(obj.min_quantity) if obj.min_quantity is not None else None,
"max_notional": obj.max_notional.to_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_str() if obj.min_notional is not None else None,
"max_notional": obj.max_notional.to_raw_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_raw_str() if obj.min_notional is not None else None,
"max_price": str(obj.max_price) if obj.max_price is not None else None,
"min_price": str(obj.min_price) if obj.min_price is not None else None,
"margin_init": str(obj.margin_init),
Expand Down
4 changes: 2 additions & 2 deletions nautilus_trader/model/instruments/commodity.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -225,8 +225,8 @@ cdef class Commodity(Instrument):
"lot_size": str(obj.lot_size) if obj.lot_size is not None else None,
"max_quantity": str(obj.max_quantity) if obj.max_quantity is not None else None,
"min_quantity": str(obj.min_quantity) if obj.min_quantity is not None else None,
"max_notional": obj.max_notional.to_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_str() if obj.min_notional is not None else None,
"max_notional": obj.max_notional.to_raw_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_raw_str() if obj.min_notional is not None else None,
"max_price": str(obj.max_price) if obj.max_price is not None else None,
"min_price": str(obj.min_price) if obj.min_price is not None else None,
"margin_init": str(obj.margin_init),
Expand Down
4 changes: 2 additions & 2 deletions nautilus_trader/model/instruments/crypto_future.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,8 @@ cdef class CryptoFuture(Instrument):
"lot_size": str(obj.lot_size),
"max_quantity": str(obj.max_quantity) if obj.max_quantity is not None else None,
"min_quantity": str(obj.min_quantity) if obj.min_quantity is not None else None,
"max_notional": obj.max_notional.to_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_str() if obj.min_notional is not None else None,
"max_notional": obj.max_notional.to_raw_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_raw_str() if obj.min_notional is not None else None,
"max_price": str(obj.max_price) if obj.max_price is not None else None,
"min_price": str(obj.min_price) if obj.min_price is not None else None,
"margin_init": str(obj.margin_init),
Expand Down
4 changes: 2 additions & 2 deletions nautilus_trader/model/instruments/crypto_perpetual.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,8 @@ cdef class CryptoPerpetual(Instrument):
"lot_size": str(obj.lot_size),
"max_quantity": str(obj.max_quantity) if obj.max_quantity is not None else None,
"min_quantity": str(obj.min_quantity) if obj.min_quantity is not None else None,
"max_notional": obj.max_notional.to_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_str() if obj.min_notional is not None else None,
"max_notional": obj.max_notional.to_raw_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_raw_str() if obj.min_notional is not None else None,
"max_price": str(obj.max_price) if obj.max_price is not None else None,
"min_price": str(obj.min_price) if obj.min_price is not None else None,
"margin_init": str(obj.margin_init),
Expand Down
4 changes: 2 additions & 2 deletions nautilus_trader/model/instruments/currency_pair.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -244,8 +244,8 @@ cdef class CurrencyPair(Instrument):
"lot_size": str(obj.lot_size) if obj.lot_size is not None else None,
"max_quantity": str(obj.max_quantity) if obj.max_quantity is not None else None,
"min_quantity": str(obj.min_quantity) if obj.min_quantity is not None else None,
"max_notional": obj.max_notional.to_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_str() if obj.min_notional is not None else None,
"max_notional": obj.max_notional.to_raw_str() if obj.max_notional is not None else None,
"min_notional": obj.min_notional.to_raw_str() if obj.min_notional is not None else None,
"max_price": str(obj.max_price) if obj.max_price is not None else None,
"min_price": str(obj.min_price) if obj.min_price is not None else None,
"margin_init": str(obj.margin_init),
Expand Down

0 comments on commit 7b4d0a5

Please sign in to comment.