From 672d969688fe03d6ce33c564278275890d991c4e Mon Sep 17 00:00:00 2001 From: Chris Sellers Date: Thu, 25 Jul 2024 22:36:40 +1000 Subject: [PATCH 1/3] ADD: Add and rename symbology types --- CHANGELOG.md | 11 ++++++++- python/python/databento_dbn/_lib.pyi | 26 ++++++++++++++++---- rust/dbn/src/enums.rs | 36 +++++++++++++++++++++++----- 3 files changed, 62 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f9d5539..6f845e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,15 @@ # Changelog -## 0.19.2 - TBD +## 0.20.0 - TBD + +### Enhancements +- Added new `SType` variants for reference data: `Isin`, `UsCode`, `BbgCompId`, `BbgCompTicker`, `Figi`, `FigiTicker` + +### Breaking changes +- Renamed `SType::Nasdaq` variant to `SType::NasdaqSymbol` +- Renamed `SType::Cms` variant to `SType::CmsSymbol` + +## 0.19.2 - 2024-07-23 ### Bug fixes - Fixed issue where `AsyncDynReader` would only decode the first frame of multi-frame diff --git a/python/python/databento_dbn/_lib.pyi b/python/python/databento_dbn/_lib.pyi index d14a287..4ffdff4 100644 --- a/python/python/databento_dbn/_lib.pyi +++ b/python/python/databento_dbn/_lib.pyi @@ -221,10 +221,22 @@ class SType(Enum): PARENT A Databento-specific symbology for referring to a group of symbols by one "parent" symbol, e.g. ES.FUT to refer to all ES futures. - NASDAQ + NASDAQ_SYMBOL Symbology for US equities using NASDAQ Integrated suffix conventions. - CMS + CMS_SYMBOL Symbology for US equities using CMS suffix conventions. + ISIN + Symbology using International Security Identification Numbers (ISIN) - ISO 6166. + US_CODE + Symbology using US domestic Committee on Uniform Securities Identification Procedure (CUSIP) codes. + BBG_COMP_ID + Symbology using Bloomberg composite global IDs. + BBG_COMP_TICKER + Symbology using Bloomberg composite tickers. + FIGI + Symbology using Bloomberg FIGI exchange level IDs. + FIGI_TICKER + Symbology using Bloomberg exchange level tickers. """ @@ -232,8 +244,14 @@ class SType(Enum): RAW_SYMBOL: str CONTINUOUS: str PARENT: str - NASDAQ: str - CMS: str + NASDAQ_SYMBOL: str + CMS_SYMBOL: str + ISIN: str + US_CODE: str + BBG_COMP_ID: str + BBG_COMP_TICKER: str + FIGI: str + FIGI_TICKER: str @classmethod def from_str(cls, value: str) -> SType: ... diff --git a/rust/dbn/src/enums.rs b/rust/dbn/src/enums.rs index 1153e04..4636e38 100644 --- a/rust/dbn/src/enums.rs +++ b/rust/dbn/src/enums.rs @@ -232,9 +232,21 @@ pub enum SType { /// "parent" symbol, e.g. ES.FUT to refer to all ES futures. Parent = 4, /// Symbology for US equities using NASDAQ Integrated suffix conventions. - Nasdaq = 5, + NasdaqSymbol = 5, /// Symbology for US equities using CMS suffix conventions. - Cms = 6, + CmsSymbol = 6, + /// Symbology using International Security Identification Numbers (ISIN) - ISO 6166. + Isin = 7, + /// Symbology using US domestic Committee on Uniform Securities Identification Procedure (CUSIP) codes. + UsCode = 8, + /// Symbology using Bloomberg composite global IDs. + BbgCompId = 9, + /// Symbology using Bloomberg composite tickers. + BbgCompTicker = 10, + /// Symbology using Bloomberg FIGI exchange level IDs. + Figi = 11, + /// Symbology using Bloomberg exchange level tickers. + FigiTicker = 12, } impl std::str::FromStr for SType { @@ -247,8 +259,14 @@ impl std::str::FromStr for SType { "smart" => Ok(SType::Smart), "continuous" => Ok(SType::Continuous), "parent" => Ok(SType::Parent), - "nasdaq" => Ok(SType::Nasdaq), - "cms" => Ok(SType::Cms), + "nasdaq_symbol" | "nasdaq" => Ok(SType::NasdaqSymbol), + "cms_symbol" | "cms" => Ok(SType::CmsSymbol), + "isin" => Ok(SType::Isin), + "us_code" => Ok(SType::UsCode), + "bbg_comp_id" => Ok(SType::BbgCompId), + "bbg_comp_ticker" => Ok(SType::BbgCompTicker), + "figi" => Ok(SType::Figi), + "figi_ticker" => Ok(SType::FigiTicker), _ => Err(crate::Error::conversion::(s.to_owned())), } } @@ -270,8 +288,14 @@ impl SType { SType::Smart => "smart", SType::Continuous => "continuous", SType::Parent => "parent", - SType::Nasdaq => "nasdaq", - SType::Cms => "cms", + SType::NasdaqSymbol => "nasdaq_symbol", + SType::CmsSymbol => "cms_symbol", + SType::Isin => "isin", + SType::UsCode => "us_code", + SType::BbgCompId => "bbg_comp_id", + SType::BbgCompTicker => "bbg_comp_ticker", + SType::Figi => "figi", + SType::FigiTicker => "figi_ticker", } } } From dbb60f8b68fd692b0ef24c150b54affbd4aac69f Mon Sep 17 00:00:00 2001 From: Renan Gemignani Date: Tue, 30 Jul 2024 14:26:53 +0200 Subject: [PATCH 2/3] ADD: Dataset for DBEQ summary --- CHANGELOG.md | 1 + rust/dbn/src/publishers.rs | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f845e8..b1e4155 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ ### Enhancements - Added new `SType` variants for reference data: `Isin`, `UsCode`, `BbgCompId`, `BbgCompTicker`, `Figi`, `FigiTicker` +- Added new publisher value for `DBEQ.SUMMARY` ### Breaking changes - Renamed `SType::Nasdaq` variant to `SType::NasdaqSymbol` diff --git a/rust/dbn/src/publishers.rs b/rust/dbn/src/publishers.rs index 57d8774..21771ce 100644 --- a/rust/dbn/src/publishers.rs +++ b/rust/dbn/src/publishers.rs @@ -287,10 +287,12 @@ pub enum Dataset { DbeqMax = 30, /// Nasdaq Basic (NLS+QBBO) XnasBasic = 31, + /// Databento Equities Summary + DbeqSummary = 32, } /// The number of Dataset variants. -pub const DATASET_COUNT: usize = 31; +pub const DATASET_COUNT: usize = 32; impl Dataset { /// Convert a Dataset to its `str` representation. @@ -329,6 +331,7 @@ impl Dataset { Self::NdexImpact => "NDEX.IMPACT", Self::DbeqMax => "DBEQ.MAX", Self::XnasBasic => "XNAS.BASIC", + Self::DbeqSummary => "DBEQ.SUMMARY", } } } @@ -383,6 +386,7 @@ impl std::str::FromStr for Dataset { "NDEX.IMPACT" => Ok(Self::NdexImpact), "DBEQ.MAX" => Ok(Self::DbeqMax), "XNAS.BASIC" => Ok(Self::XnasBasic), + "DBEQ.SUMMARY" => Ok(Self::DbeqSummary), _ => Err(Error::conversion::(s)), } } @@ -571,10 +575,12 @@ pub enum Publisher { XnasBasicXbos = 88, /// Nasdaq Basic - Nasdaq PSX XnasBasicXpsx = 89, + /// Databento Equities Summary + DbeqSummaryDbeq = 90, } /// The number of Publisher variants. -pub const PUBLISHER_COUNT: usize = 89; +pub const PUBLISHER_COUNT: usize = 90; impl Publisher { /// Convert a Publisher to its `str` representation. @@ -669,6 +675,7 @@ impl Publisher { Self::XnasNlsXpsx => "XNAS.NLS.XPSX", Self::XnasBasicXbos => "XNAS.BASIC.XBOS", Self::XnasBasicXpsx => "XNAS.BASIC.XPSX", + Self::DbeqSummaryDbeq => "DBEQ.SUMMARY.DBEQ", } } @@ -764,6 +771,7 @@ impl Publisher { Self::XnasNlsXpsx => Venue::Xpsx, Self::XnasBasicXbos => Venue::Xbos, Self::XnasBasicXpsx => Venue::Xpsx, + Self::DbeqSummaryDbeq => Venue::Dbeq, } } @@ -859,6 +867,7 @@ impl Publisher { Self::XnasNlsXpsx => Dataset::XnasNls, Self::XnasBasicXbos => Dataset::XnasBasic, Self::XnasBasicXpsx => Dataset::XnasBasic, + Self::DbeqSummaryDbeq => Dataset::DbeqSummary, } } @@ -956,6 +965,7 @@ impl Publisher { (Dataset::XnasNls, Venue::Xpsx) => Ok(Self::XnasNlsXpsx), (Dataset::XnasBasic, Venue::Xbos) => Ok(Self::XnasBasicXbos), (Dataset::XnasBasic, Venue::Xpsx) => Ok(Self::XnasBasicXpsx), + (Dataset::DbeqSummary, Venue::Dbeq) => Ok(Self::DbeqSummaryDbeq), _ => Err(Error::conversion::(format!("({dataset}, {venue})"))), } } @@ -1067,6 +1077,7 @@ impl std::str::FromStr for Publisher { "XNAS.NLS.XPSX" => Ok(Self::XnasNlsXpsx), "XNAS.BASIC.XBOS" => Ok(Self::XnasBasicXbos), "XNAS.BASIC.XPSX" => Ok(Self::XnasBasicXpsx), + "DBEQ.SUMMARY.DBEQ" => Ok(Self::DbeqSummaryDbeq), _ => Err(Error::conversion::(s)), } } From 23275871e62a32bbff9b1ccbf0acfc56d7ae7bc2 Mon Sep 17 00:00:00 2001 From: Carter Green Date: Tue, 30 Jul 2024 11:25:31 -0500 Subject: [PATCH 3/3] VER: Release 0.20.0 --- CHANGELOG.md | 2 +- Cargo.lock | 10 +++++----- Cargo.toml | 2 +- python/pyproject.toml | 4 ++-- rust/dbn-cli/Cargo.toml | 2 +- rust/dbn/Cargo.toml | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b1e4155..34171d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## 0.20.0 - TBD +## 0.20.0 - 2024-07-30 ### Enhancements - Added new `SType` variants for reference data: `Isin`, `UsCode`, `BbgCompId`, `BbgCompTicker`, `Figi`, `FigiTicker` diff --git a/Cargo.lock b/Cargo.lock index fd9eab9..12b00fe 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -256,7 +256,7 @@ dependencies = [ [[package]] name = "databento-dbn" -version = "0.19.2" +version = "0.20.0" dependencies = [ "dbn", "pyo3", @@ -267,7 +267,7 @@ dependencies = [ [[package]] name = "dbn" -version = "0.19.2" +version = "0.20.0" dependencies = [ "async-compression", "csv", @@ -289,7 +289,7 @@ dependencies = [ [[package]] name = "dbn-c" -version = "0.19.2" +version = "0.20.0" dependencies = [ "anyhow", "cbindgen", @@ -299,7 +299,7 @@ dependencies = [ [[package]] name = "dbn-cli" -version = "0.19.2" +version = "0.20.0" dependencies = [ "anyhow", "assert_cmd", @@ -314,7 +314,7 @@ dependencies = [ [[package]] name = "dbn-macros" -version = "0.19.2" +version = "0.20.0" dependencies = [ "csv", "dbn", diff --git a/Cargo.toml b/Cargo.toml index 81bf2cb..d19d16f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ resolver = "2" [workspace.package] authors = ["Databento "] edition = "2021" -version = "0.19.2" +version = "0.20.0" documentation = "https://docs.databento.com" repository = "https://github.com/databento/dbn" license = "Apache-2.0" diff --git a/python/pyproject.toml b/python/pyproject.toml index ff43497..ac968e2 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "databento-dbn" -version = "0.19.2" +version = "0.20.0" description = "Python bindings for encoding and decoding Databento Binary Encoding (DBN)" authors = ["Databento "] license = "Apache-2.0" @@ -17,7 +17,7 @@ build-backend = "maturin" [project] name = "databento-dbn" -version = "0.19.2" +version = "0.20.0" authors = [ { name = "Databento", email = "support@databento.com" } ] diff --git a/rust/dbn-cli/Cargo.toml b/rust/dbn-cli/Cargo.toml index 93c5c4b..c686f23 100644 --- a/rust/dbn-cli/Cargo.toml +++ b/rust/dbn-cli/Cargo.toml @@ -16,7 +16,7 @@ name = "dbn" path = "src/main.rs" [dependencies] -dbn = { path = "../dbn", version = "=0.19.2", default-features = false } +dbn = { path = "../dbn", version = "=0.20.0", default-features = false } anyhow = { workspace = true } clap = { version = "4.5", features = ["derive", "wrap_help"] } diff --git a/rust/dbn/Cargo.toml b/rust/dbn/Cargo.toml index 2cd10a5..84d5d49 100644 --- a/rust/dbn/Cargo.toml +++ b/rust/dbn/Cargo.toml @@ -25,7 +25,7 @@ serde = ["dep:serde", "time/parsing", "time/serde"] trivial_copy = [] [dependencies] -dbn-macros = { version = "=0.19.2", path = "../dbn-macros" } +dbn-macros = { version = "=0.20.0", path = "../dbn-macros" } async-compression = { version = "0.4.11", features = ["tokio", "zstd"], optional = true } csv = { workspace = true }