v1.138.0

nautechsystems/nautilus_traderv1.138.0Feb 13, 2022by github-actions[bot]

AI Summary

Beta release standardizing terminology, renaming 'working' orders to 'open' orders and 'ExecutionId' to 'TradeId'.

Key Highlights

  • Renamed 'working' orders to 'open' orders
  • Renamed ExecutionId to TradeId
  • Introduced trailing stop order types

Breaking Changes

  • Renamed working to open (and completed to closed)
  • Renamed ExecutionId to TradeId
  • Renamed trigger to trigger_price
  • Removed active order concept

New Features

  • TradeId type enforcement
  • TrailingOffsetType enum
  • TrailingStopMarketOrder and TrailingStopLimitOrder
  • allow_cash_positions config option

Full Release Notes

# NautilusTrader 1.138.0 Beta

## Release Notes

Released on 15th February 2022 (UTC).

**This release contains numerous method, parameter and property name changes**

For consistency and standardization with other protocols, the `ExecutionId` type 
has been renamed to `TradeId` as they express the same concept with a more 
standardized terminology. In the interests of enforcing correctness and 
safety this type is now utilized for the `TradeTick.trade_id`.

### Breaking Changes
- Renamed `working` orders to `open` orders including all associated methods and params.
- Renamed `completed` orders to `closed` orders including all associated methods and params.
- Removed `active` order concept (often confused with `open`).
- Renamed `trigger` to `trigger_price`.
- Renamed `StopMarketOrder.price` to `StopMarketOrder.trigger_price`.
- Renamed all params related to a `StopMarketOrders` `price` to `trigger_price`.
- Renamed `ExecutionId` to `TradeId`.
- Renamed `execution_id` to `trade_id`.
- Renamed `Order.trade_id` to `Order.last_trade_id` (for clarity).
- Renamed other variations and references of 'execution ID' to 'trade ID'.
- Renamed `contingency` to `contingency_type`.

### Enhancements
- Introduced the `TradeId` type to enforce `trade_id` typing.
- Improve handling of unleveraged cash asset positions including Crypto and Fiat spot currency instruments.
- Added `ExecEngineConfig` option `allow_cash_positions` (`False` by default).
- Added `TrailingOffsetType` enum.
- Added `TrailingStopMarketOrder`.
- Added `TrailingStopLimitOrder`.
- Added trailing order factory methods.
- Added `trigger_type` param to stop orders.
- Added `TriggerType` enum.
- Large refactoring of order base and impl classes.
- Overhaul of execution reports.
- Overhaul of execution state reconciliation.

### Fixes
- Fixed WebSocket base reconnect handling.