databento-dbn 0.41.0__cp311-cp311-win_amd64.whl → 0.42.0__cp311-cp311-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of databento-dbn might be problematic. Click here for more details.

Binary file
databento_dbn/_lib.pyi CHANGED
@@ -1,4 +1,4 @@
1
- # ruff: noqa: UP007 PYI021 PYI011 PYI014
1
+ # ruff: noqa: UP007, PYI021, PYI011
2
2
  from __future__ import annotations
3
3
 
4
4
  import datetime as dt
@@ -326,6 +326,44 @@ class Record(SupportsBytes):
326
326
 
327
327
  """
328
328
 
329
+ @property
330
+ def ts_index(self) -> int:
331
+ """
332
+ The raw primary timestamp for the record as the number of nanoseconds since the
333
+ UNIX epoch. For records that define a `ts_recv` and `ts_event`, this method will
334
+ return the appropriate timestamp for indexing based on the record's type.
335
+
336
+ This timestamp should be used for sorting records as well as indexing into any
337
+ symbology data structure.
338
+
339
+ See `ts_event` https://databento.com/docs/standards-and-conventions/common-fields-enums-types#ts-event.
340
+ See `ts_recv` https://databento.com/docs/standards-and-conventions/common-fields-enums-types#ts-recv.
341
+
342
+ Returns
343
+ -------
344
+ int
345
+
346
+ """
347
+
348
+ @property
349
+ def pretty_ts_index(self) -> dt.datetime | None:
350
+ """
351
+ The primary timestamp for the record as the expressed as a datetime or a
352
+ `pandas.Timestamp`, if available. For records that define a `ts_recv` and `ts_event`,
353
+ this method will return the appropriate timestamp for indexing based on the record's type.
354
+
355
+ This timestamp should be used for sorting records as well as indexing into any
356
+ symbology data structure.
357
+
358
+ See `ts_event` https://databento.com/docs/standards-and-conventions/common-fields-enums-types#ts-event.
359
+ See `ts_recv` https://databento.com/docs/standards-and-conventions/common-fields-enums-types#ts-recv.
360
+
361
+ Returns
362
+ -------
363
+ datetime.datetime
364
+
365
+ """
366
+
329
367
  @property
330
368
  def pretty_ts_event(self) -> dt.datetime | None:
331
369
  """
@@ -1324,7 +1362,7 @@ class MBOMsg(Record):
1324
1362
  side: Side,
1325
1363
  ts_recv: int,
1326
1364
  flags: int | None = None,
1327
- channel_id: int = 0,
1365
+ channel_id: int | None = None,
1328
1366
  ts_in_delta: int = 0,
1329
1367
  sequence: int = 0,
1330
1368
  ) -> None: ...
@@ -3016,7 +3054,7 @@ class InstrumentDefMsg(Record):
3016
3054
  raw_instrument_id: int = 0,
3017
3055
  leg_price: int = UNDEF_PRICE,
3018
3056
  leg_delta: int = UNDEF_PRICE,
3019
- inst_attrib_value: int = 0,
3057
+ inst_attrib_value: int | None = None,
3020
3058
  underlying_id: int = 0,
3021
3059
  market_depth_implied: int | None = None,
3022
3060
  market_depth: int | None = None,
@@ -3038,7 +3076,7 @@ class InstrumentDefMsg(Record):
3038
3076
  appl_id: int | None = None,
3039
3077
  maturity_year: int | None = None,
3040
3078
  decay_start_date: int | None = None,
3041
- channel_id: int = 0,
3079
+ channel_id: int | None = None,
3042
3080
  leg_count: int = 0,
3043
3081
  leg_index: int = 0,
3044
3082
  currency: str = "",
@@ -4559,7 +4597,7 @@ class StatMsg(Record):
4559
4597
  stat_type: StatType,
4560
4598
  sequence: int = 0,
4561
4599
  ts_in_delta: int = 0,
4562
- channel_id: int = 0,
4600
+ channel_id: int | None = None,
4563
4601
  update_action: StatUpdateAction | None = None,
4564
4602
  stat_flags: int = 0,
4565
4603
  ) -> None: ...
@@ -5965,7 +6003,7 @@ class StatMsgV1(Record):
5965
6003
  stat_type: StatType,
5966
6004
  sequence: int = 0,
5967
6005
  ts_in_delta: int = 0,
5968
- channel_id: int = 0,
6006
+ channel_id: int | None = None,
5969
6007
  update_action: StatUpdateAction | None = None,
5970
6008
  stat_flags: int = 0,
5971
6009
  ) -> None: ...
@@ -7346,7 +7384,7 @@ class Transcoder:
7346
7384
  pretty_px : bool, default True
7347
7385
  Whether to serialize fixed-precision prices as decimal strings. Only applicable
7348
7386
  to CSV and JSON.
7349
- pretty_ts : bool, default Tru | Nonee
7387
+ pretty_ts : bool, default True | None
7350
7388
  Whether to serialize nanosecond UNIX timestamps as ISO8601 datetime strings.
7351
7389
  Only applicable to CSV and JSON.
7352
7390
  map_symbols : bool, default None
databento_dbn/v1.py CHANGED
@@ -1,4 +1,4 @@
1
- # ruff: noqa: F401, F811
1
+ # ruff: noqa: F401
2
2
  from ._lib import BBOMsg
3
3
  from ._lib import CBBOMsg
4
4
  from ._lib import CMBP1Msg
databento_dbn/v2.py CHANGED
@@ -1,4 +1,4 @@
1
- # ruff: noqa: F401, F811
1
+ # ruff: noqa: F401
2
2
  from ._lib import BBOMsg
3
3
  from ._lib import CBBOMsg
4
4
  from ._lib import CMBP1Msg
databento_dbn/v3.py CHANGED
@@ -1,4 +1,4 @@
1
- # ruff: noqa: F401, F811
1
+ # ruff: noqa: F401
2
2
  from ._lib import BBOMsg
3
3
  from ._lib import CBBOMsg
4
4
  from ._lib import CMBP1Msg
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: databento-dbn
3
- Version: 0.41.0
3
+ Version: 0.42.0
4
4
  Classifier: Programming Language :: Rust
5
5
  Classifier: Programming Language :: Python :: Implementation :: CPython
6
6
  Summary: Python bindings for encoding and decoding Databento Binary Encoding (DBN)
@@ -0,0 +1,10 @@
1
+ databento_dbn-0.42.0.dist-info/METADATA,sha256=PoVJt3o20u2ssYDnIzuHwgHy1it0KDtAGuxZDzLB38U,2111
2
+ databento_dbn-0.42.0.dist-info/WHEEL,sha256=YCZ9Vxhf2aXNyfoR2QH-PPqnUr48Igr9zjgnGhp3xTc,96
3
+ databento_dbn/__init__.py,sha256=u__7ZrT9051pRmM0mp2wq4w-hoKP-pGlawQZ8E3Q0To,1179
4
+ databento_dbn/_lib.cp311-win_amd64.pyd,sha256=BgnZYNbvX6ouXSvWy1M2445R6eSmeyUI9_IlgnmLGMY,4009472
5
+ databento_dbn/_lib.pyi,sha256=HJJm84veAhBs1qD-MBTn2wazYGUzpwttO9hHcdb7AAI,170053
6
+ databento_dbn/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
+ databento_dbn/v1.py,sha256=4CLL86Pbm_MI_b8lqVBDvNlK4t6IuxDBFnIU-OGoNlc,676
8
+ databento_dbn/v2.py,sha256=TBxZGEuQ0T6lBVyg4uzulI5LfN0NYeibFtU-QV89f1s,625
9
+ databento_dbn/v3.py,sha256=MYHJ-QhODEXasQmhmHjd6ZL1nkigHjpHtXCYdBKC67w,590
10
+ databento_dbn-0.42.0.dist-info/RECORD,,
@@ -1,4 +1,4 @@
1
1
  Wheel-Version: 1.0
2
- Generator: maturin (1.9.3)
2
+ Generator: maturin (1.9.4)
3
3
  Root-Is-Purelib: false
4
4
  Tag: cp311-cp311-win_amd64
@@ -1,10 +0,0 @@
1
- databento_dbn-0.41.0.dist-info/METADATA,sha256=52BkLZOubLAIW1rkO_bK4kNT4i28NPqW92-_ahbhFs8,2111
2
- databento_dbn-0.41.0.dist-info/WHEEL,sha256=Ncll1xfKuKRSH9zs2vSEuHQoNZLcJWpzadJbiEni0qk,96
3
- databento_dbn/__init__.py,sha256=u__7ZrT9051pRmM0mp2wq4w-hoKP-pGlawQZ8E3Q0To,1179
4
- databento_dbn/_lib.cp311-win_amd64.pyd,sha256=nU5JCOKKh13dIm5-9VxeNEgt1PQRengRHgUrgheInjg,4133888
5
- databento_dbn/_lib.pyi,sha256=M3m4Au4FzAKBOudjnnn_Got7lopfKpWGEqOMtpgFQd4,168479
6
- databento_dbn/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
- databento_dbn/v1.py,sha256=J4ivA_575uWlPeOp4pqdGY2Gi7WSRE4UYIIWC1QQuts,682
8
- databento_dbn/v2.py,sha256=KfTrfuWkUazDDL3pJqPfSmxxun0neHPJLOIuoimwIVk,631
9
- databento_dbn/v3.py,sha256=dNZ5OeR4_WaB0zEfkjcf6tHIlkKhJXGATal8_-pifu4,596
10
- databento_dbn-0.41.0.dist-info/RECORD,,