Skip to content

Commit

Permalink
Update gh-pages to output generated at a7a5851
Browse files Browse the repository at this point in the history
  • Loading branch information
cjdsellers committed Jan 21, 2024
1 parent f9a72fd commit ecb2e79
Show file tree
Hide file tree
Showing 1,618 changed files with 3,881 additions and 5,180 deletions.
Binary file modified nightly/.doctrees/api_reference/accounting.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/adapters/betfair.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/adapters/binance.doctree
Binary file not shown.
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/analysis.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/backtest.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/cache.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/common.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/config.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/core.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/data.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/execution.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/indicators.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/live.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/book.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/data.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/events.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/identifiers.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/instruments.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/objects.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/orders.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/position.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/model/tick_scheme.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/persistence.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/portfolio.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/risk.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/serialization.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/system.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/api_reference/trading.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/concepts/adapters.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/concepts/instruments.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/concepts/logging.doctree
Binary file not shown.
Binary file modified nightly/.doctrees/environment.pickle
Binary file not shown.
3 changes: 0 additions & 3 deletions nightly/_sources/concepts/adapters.md.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ from nautilus_trader.adapters.binance.common.enums import BinanceAccountType
from nautilus_trader.adapters.binance.factories import get_cached_binance_http_client
from nautilus_trader.adapters.binance.futures.providers import BinanceFuturesInstrumentProvider
from nautilus_trader.common.clock import LiveClock
from nautilus_trader.common.logging import Logger


clock = LiveClock()
Expand All @@ -37,7 +36,6 @@ account_type = BinanceAccountType.USDT_FUTURE
client = get_cached_binance_http_client(
loop=asyncio.get_event_loop(),
clock=clock,
logger=Logger(),
account_type=account_type,
key=os.getenv("BINANCE_FUTURES_TESTNET_API_KEY"),
secret=os.getenv("BINANCE_FUTURES_TESTNET_API_SECRET"),
Expand All @@ -47,7 +45,6 @@ await client.connect()

provider = BinanceFuturesInstrumentProvider(
client=client,
logger=Logger(),
account_type=BinanceAccountType.USDT_FUTURE,
)

Expand Down
5 changes: 1 addition & 4 deletions nightly/_sources/concepts/instruments.md.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,7 @@ Exchange specific instruments can be discovered from live exchange data using an
from nautilus_trader.adapters.binance.spot.providers import BinanceSpotInstrumentProvider
from nautilus_trader.model.identifiers import InstrumentId

provider = BinanceSpotInstrumentProvider(
client=binance_http_client,
logger=live_logger,
)
provider = BinanceSpotInstrumentProvider(client=binance_http_client)
await self.provider.load_all_async()

btcusdt = InstrumentId.from_str("BTCUSDT.BINANCE")
Expand Down
32 changes: 25 additions & 7 deletions nightly/_sources/concepts/logging.md.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Logging

The platform provides logging for both backtesting and live trading using a high-performance logger implemented in Rust
using the `log` crate.
The logger operates in a separate thread and uses a multi-producer single consumer (MPSC) channel to receive log messages.
The platform provides logging for both backtesting and live trading using a high-performance logging system implemented in Rust
with a standardized facade from the `log` crate.
The core logger operates in a separate thread and uses a multi-producer single consumer (MPSC) channel to receive log messages.
This design ensures that the main thread is not blocked by log string formatting or file I/O operations.

```{note}
Expand All @@ -20,7 +20,8 @@ Infrastructure such as [vector](https://github.com/vectordotdev/vector) can be c
Logging can be configured by importing the `LoggingConfig` object.
By default, log events with an 'INFO' `LogLevel` and higher are written to stdout/stderr.

Log level (`LogLevel`) values include:
Log level (`LogLevel`) values include (and generally match Rusts `tracing` level filters):
- 'OFF'
- 'DEBUG'
- 'INFO'
- 'WARNING' or 'WARN'
Expand All @@ -41,9 +42,6 @@ Logging can be configured in the following ways:
- Bypass logging completely
- Print Rust config to stdout at initialization

```{warning}
Only one logger (with Rust backed logging system) can be initialized per process.
```

### Standard output logging
Log messages are written to the console via stdout/stderr writers. The minimum log level can be configured using the `log_level` parameter.
Expand Down Expand Up @@ -104,3 +102,23 @@ these color codes may not be appropriate as they can appear as raw text.
To accommodate for such scenarios, the `LoggingConfig.log_colors` option can be set to `false`.
Disabling `log_colors` will prevent the addition of ANSI color codes to the log messages, ensuring
compatibility across different environments where color rendering is not supported.

### Using a Logger directly

It's possible to use `Logger` objects directly, and these can be initialized anywhere (very similar to the Python built-in `logging` API).

If you ***aren't*** using an object which already initializes a `NautilusKernel` (and logging) such as `BacktestEngine` or `TradingNode`,
then you can initialize a logging in the following way:
```python
from nautilus_trader.common.logging import init_logging
from nautilus_trader.common.logging import Logger

init_logging()
logger = Logger("MyLogger")
```

There are many configuration options for the `init_logging` call, please see its docstring for further details.

```{warning}
Only one logging system can be initialized per process with an `init_logging` call.
```
10 changes: 5 additions & 5 deletions nightly/api_reference/accounting.html
Original file line number Diff line number Diff line change
Expand Up @@ -9502,10 +9502,10 @@ <h1 id="api-reference-accounting--page-root">
<em class="sig-param">
<span class="n">
<span class="pre">
LoggerAdapter
Logger
</span>
<span class="pre">
log
logger
</span>
</span>
</em>
Expand Down Expand Up @@ -9565,12 +9565,12 @@ <h1 id="api-reference-accounting--page-root">
<li>
<p>
<strong>
log
logger
</strong>
(
<a class="reference internal" href="common.html#nautilus_trader.common.logging.LoggerAdapter" title="nautilus_trader.common.logging.LoggerAdapter">
<a class="reference internal" href="common.html#nautilus_trader.common.logging.Logger" title="nautilus_trader.common.logging.Logger">
<em>
LoggerAdapter
Logger
</em>
</a>
) – The logger for the manager.
Expand Down
Loading

0 comments on commit ecb2e79

Please sign in to comment.