Skip to main content

EXPECTED_ENGINE_VERSION

Constant EXPECTED_ENGINE_VERSION 

Source
pub const EXPECTED_ENGINE_VERSION: Option<&str>;
Expand description

The chdb-core release this build fetched, without the leading v.

None when the build linked a library it did not fetch — a CHDB_LIB_DIR build, a copy already installed on the machine, a docs.rs build. The pinned version says nothing about an artifact that came from somewhere else, so this reports nothing rather than reporting the pin. ENGINE_SOURCE says where the library came from, and engine_version asks the library itself.

use chdb_rust::version::{engine_version, EXPECTED_ENGINE_VERSION};

// A build that fetched its own engine can check the two agree.
if let Some(expected) = EXPECTED_ENGINE_VERSION {
    assert_eq!(expected, engine_version()?);
}