Skip to content

Commit 855c661

Browse files
author
Jack Culhane
committed
ADD: Add three IntelligentCross MICs to Venue list
1 parent 1583310 commit 855c661

File tree

2 files changed

+28
-0
lines changed

2 files changed

+28
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ This release adds support for Python v3.13.
66

77
#### Enhancements
88
- Added support for Python 3.13
9+
- Added new IntelligentCross venues `ASPN`, `ASMT`, and `ASPI`
910

1011
#### Deprecations
1112
- Deprecated `packaging` parameter for `Historical.batch.submit_job` which will be removed in a future release

databento/common/publishers.py

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,12 @@ class Venue(StringyMixin, str, Enum):
102102
Long-Term Stock Exchange, Inc..
103103
XOFF
104104
Off-Exchange Transactions - Listed Instruments.
105+
ASPN
106+
IntelligentCross ASPEN Intelligent Bid/Offer.
107+
ASMT
108+
IntelligentCross ASPEN Maker/Taker.
109+
ASPI
110+
IntelligentCross ASPEN Inverted.
105111
106112
"""
107113

@@ -148,6 +154,9 @@ class Venue(StringyMixin, str, Enum):
148154
SPHR = "SPHR"
149155
LTSE = "LTSE"
150156
XOFF = "XOFF"
157+
ASPN = "ASPN"
158+
ASMT = "ASMT"
159+
ASPI = "ASPI"
151160

152161
@classmethod
153162
def from_int(cls, value: int) -> Venue:
@@ -240,6 +249,12 @@ def from_int(cls, value: int) -> Venue:
240249
return Venue.LTSE
241250
if value == 43:
242251
return Venue.XOFF
252+
if value == 44:
253+
return Venue.ASPN
254+
if value == 45:
255+
return Venue.ASMT
256+
if value == 46:
257+
return Venue.ASPI
243258
raise ValueError(f"Integer value {value} does not correspond with any Venue variant")
244259

245260
def to_int(self) -> int:
@@ -332,6 +347,12 @@ def to_int(self) -> int:
332347
return 42
333348
if self == Venue.XOFF:
334349
return 43
350+
if self == Venue.ASPN:
351+
return 44
352+
if self == Venue.ASMT:
353+
return 45
354+
if self == Venue.ASPI:
355+
return 46
335356
raise ValueError("Invalid Venue")
336357

337358
@property
@@ -425,6 +446,12 @@ def description(self) -> str:
425446
return "Long-Term Stock Exchange, Inc."
426447
if self == Venue.XOFF:
427448
return "Off-Exchange Transactions - Listed Instruments"
449+
if self == Venue.ASPN:
450+
return "IntelligentCross ASPEN Intelligent Bid/Offer"
451+
if self == Venue.ASMT:
452+
return "IntelligentCross ASPEN Maker/Taker"
453+
if self == Venue.ASPI:
454+
return "IntelligentCross ASPEN Inverted"
428455
raise ValueError("Unexpected Venue value")
429456

430457

0 commit comments

Comments
 (0)