Skip to content

Commit 3e9a200

Browse files
ADD: Dataset for DBEQ summary
1 parent dd450ef commit 3e9a200

File tree

2 files changed

+27
-0
lines changed

2 files changed

+27
-0
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## 0.38.1 - TBD
4+
5+
#### Enhancements
6+
- Added new publisher value for `DBEQ.SUMMARY`
7+
38
## 0.38.0 - 2024-07-23
49

510
This release adds a new feature to the `Live` client for automatically reconnecting when an unexpected disconnection occurs.

databento/common/publishers.py

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -496,6 +496,8 @@ class Dataset(StringyMixin, str, Enum):
496496
Databento Equities Max.
497497
XNAS_BASIC
498498
Nasdaq Basic (NLS+QBBO).
499+
DBEQ_SUMMARY
500+
Databento Equities Summary.
499501
500502
"""
501503

@@ -530,6 +532,7 @@ class Dataset(StringyMixin, str, Enum):
530532
NDEX_IMPACT = "NDEX.IMPACT"
531533
DBEQ_MAX = "DBEQ.MAX"
532534
XNAS_BASIC = "XNAS.BASIC"
535+
DBEQ_SUMMARY = "DBEQ.SUMMARY"
533536

534537
@classmethod
535538
def from_int(cls, value: int) -> Dataset:
@@ -598,6 +601,8 @@ def from_int(cls, value: int) -> Dataset:
598601
return Dataset.DBEQ_MAX
599602
if value == 31:
600603
return Dataset.XNAS_BASIC
604+
if value == 32:
605+
return Dataset.DBEQ_SUMMARY
601606
raise ValueError(f"Integer value {value} does not correspond with any Dataset variant")
602607

603608
def to_int(self) -> int:
@@ -666,6 +671,8 @@ def to_int(self) -> int:
666671
return 30
667672
if self == Dataset.XNAS_BASIC:
668673
return 31
674+
if self == Dataset.DBEQ_SUMMARY:
675+
return 32
669676
raise ValueError("Invalid Dataset")
670677

671678
@property
@@ -735,6 +742,8 @@ def description(self) -> str:
735742
return "Databento Equities Max"
736743
if self == Dataset.XNAS_BASIC:
737744
return "Nasdaq Basic (NLS+QBBO)"
745+
if self == Dataset.DBEQ_SUMMARY:
746+
return "Databento Equities Summary"
738747
raise ValueError("Unexpected Dataset value")
739748

740749

@@ -922,6 +931,8 @@ class Publisher(StringyMixin, str, Enum):
922931
Nasdaq Basic - Nasdaq BX.
923932
XNAS_BASIC_XPSX
924933
Nasdaq Basic - Nasdaq PSX.
934+
DBEQ_SUMMARY_DBEQ
935+
Databento Equities Summary.
925936
926937
"""
927938

@@ -1014,6 +1025,7 @@ class Publisher(StringyMixin, str, Enum):
10141025
XNAS_NLS_XPSX = "XNAS.NLS.XPSX"
10151026
XNAS_BASIC_XBOS = "XNAS.BASIC.XBOS"
10161027
XNAS_BASIC_XPSX = "XNAS.BASIC.XPSX"
1028+
DBEQ_SUMMARY_DBEQ = "DBEQ.SUMMARY.DBEQ"
10171029

10181030
@classmethod
10191031
def from_int(cls, value: int) -> Publisher:
@@ -1198,6 +1210,8 @@ def from_int(cls, value: int) -> Publisher:
11981210
return Publisher.XNAS_BASIC_XBOS
11991211
if value == 89:
12001212
return Publisher.XNAS_BASIC_XPSX
1213+
if value == 90:
1214+
return Publisher.DBEQ_SUMMARY_DBEQ
12011215
raise ValueError(f"Integer value {value} does not correspond with any Publisher variant")
12021216

12031217
def to_int(self) -> int:
@@ -1382,6 +1396,8 @@ def to_int(self) -> int:
13821396
return 88
13831397
if self == Publisher.XNAS_BASIC_XPSX:
13841398
return 89
1399+
if self == Publisher.DBEQ_SUMMARY_DBEQ:
1400+
return 90
13851401
raise ValueError("Invalid Publisher")
13861402

13871403
@property
@@ -1567,6 +1583,8 @@ def venue(self) -> Venue:
15671583
return Venue.XBOS
15681584
if self == Publisher.XNAS_BASIC_XPSX:
15691585
return Venue.XPSX
1586+
if self == Publisher.DBEQ_SUMMARY_DBEQ:
1587+
return Venue.DBEQ
15701588
raise ValueError("Unexpected Publisher value")
15711589

15721590
@property
@@ -1752,6 +1770,8 @@ def dataset(self) -> Dataset:
17521770
return Dataset.XNAS_BASIC
17531771
if self == Publisher.XNAS_BASIC_XPSX:
17541772
return Dataset.XNAS_BASIC
1773+
if self == Publisher.DBEQ_SUMMARY_DBEQ:
1774+
return Dataset.DBEQ_SUMMARY
17551775
raise ValueError("Unexpected Publisher value")
17561776

17571777
@property
@@ -1937,4 +1957,6 @@ def description(self) -> str:
19371957
return "Nasdaq Basic - Nasdaq BX"
19381958
if self == Publisher.XNAS_BASIC_XPSX:
19391959
return "Nasdaq Basic - Nasdaq PSX"
1960+
if self == Publisher.DBEQ_SUMMARY_DBEQ:
1961+
return "Databento Equities Summary"
19401962
raise ValueError("Unexpected Publisher value")

0 commit comments

Comments
 (0)