nautechsystems / nautilus_trader

A high-performance algorithmic trading platform and event-driven backtester
https://nautilustrader.io
GNU Lesser General Public License v3.0
1.7k stars 398 forks source link

type error loading Databento MBO file when using DatabentoDataLoader #1728

Closed anegrean closed 1 week ago

anegrean commented 1 week ago

Bug Report

I tried loading a databento mbo.dbn.zst file with historical data using DatabentoDataLoader and got this error:

TypeError: DatabentoDataLoader.load_order_book_deltas() got an unexpected keyword argument 'include_trades'

Expected Behavior

Seems to be a bug when using the as_legacy_cython=False parameter for from_dbn_file()

Actual Behavior

Should load data.

Steps to Reproduce the Problem

Run with db_fpath pointing to Databento mbo.dbn.zst file:

db_mbo_data = loader.from_dbn_file( path = db_fpath, as_legacy_cython=False, # This will load Rust pyo3 objects to write to the catalog (we could use legacy Cython objects, but this is slightly more efficient) )

Data loads fine if as_legacy_cython=True

Specifications

cjdsellers commented 1 week ago

Hi @anegrean

Thanks for the report!

This is now fixed on develop branch, will make it into nightly later and will be in the next release (likely next week).