Skip to content

Releases

Voyager OGM v0.5.0-alpha.2

Pre-release

Choose a tag to compare

@github-actions github-actions released this 27 Nov 17:06
v0.5.0-alpha.2
78dce2a

Second alpha of the 0.5 line. It fixes the value differences the new value conformance pack (#299) found, so the same value comes back with the same Python type from the official client, the bridge, the native backend and Arrow/Polars on every engine. It also moves to DuckDB 2.x with Python 3.14 support for every engine client, and polishes the voyager CLI.

Highlights of 0.5.0-alpha.2:

  • Bolt: native sessions negotiate Bolt 5.x with Memgraph, so zoned datetimes keep their exact instant, including DST fold (#414). Spatial values come back as voyager_ogm.Point (#419). Memgraph Arrow/Polars temporals are correct (#420).
  • PostgreSQL and Apache AGE: dicts and nested values bind as jsonb, and a new voyager_ogm.Json(...) wrapper forces JSON (#421). Floats round-trip exactly through JSON (#422). Multidimensional and mixed-depth array results decode natively (#432, #440).
  • Bridges: UUID, offset-aware times, ZoneInfo datetimes, Duration and JSON parameters are adapted for the Bolt, FalkorDB and DuckDB bridges (#418, #423).
  • DuckDB 2.0.1: DuckDB 2.0.1 is now required, and duckdb, psycopg, falkordb and neomodel install on Python 3.14 (#417). The DuckDB bridge has typed Arrow/Polars exports (#424). TIMETZ and INTERVAL edge cases, including nested values, are fixed, and every statement runs once (#439, #442). DuckPGQ live tests now run in CI.
  • CLI: compile and validate accept the spec vector envelope, and validate --check-expected is new (#416). Memgraph and FalkorDB index introspection is fixed (#429, #430). -h and --help agree (#431).

Breaking changes (details in the entries below):

  • Native Bolt (Neo4j, Memgraph) returns spatial values as voyager_ogm.Point instead of dict, and Arrow/Polars point columns are a struct (srid, x, y, z) (#419).
  • DuckDB bridge Arrow/Polars column types:
    • UUID is 16-byte binary tagged arrow.uuid;
    • HUGEINT is decimal128(38,0);
    • TIMETZ is ISO text;
    • JSON is tagged JSON text (#424).
  • DuckDB 2.0.1 is the minimum, and DuckPGQ installs with INSTALL duckpgq FROM community; (#417).

Added

  • CLI Spec Vector Envelope Support (#416): voyager compile and voyager validate now unwrap Query Spec vector envelopes ({"spec": {"spec_version": 1, ...}, ...}) from spec/vectors/ files or stdin while keeping bare specs and compile text stdout unchanged, marking "envelope_unwrapped": true in compile --format json, adding a hint mentioning "spec_version": 1 and the envelope form when neither spec_version nor a spec object is present, and adding --check-expected to voyager validate to verify vector expected outputs or errors.

Changed

  • CI live DuckPGQ coverage (#442): the Python CI workflow now caches DuckDB extensions and runs INSTALL duckpgq FROM community on supported platforms so the embedded DuckPGQ and live DuckPGQ test suites execute on Linux (and supported macOS ARM64/Windows runners) instead of skipping, while skipping with a clear message on unsupported platforms.
  • DuckDB 2.0.1 minimum and Python 3.14 engine clients (#417): the minimum supported DuckDB version is now 2.0.1: the duckdb extra requires duckdb>=2.0.1, the dev dependency group pins duckdb==2.0.1, and both install on Python 3.14 from the abi3 wheels. The < 3.14 markers are gone from the duckdb, age/psycopg[binary], falkordb and neomodel dependencies because their current releases support 3.14. DuckDB 2.0 only parses CREATE PROPERTY GRAPH and GRAPH_TABLE after the per-connection SET active_grammar_extensions = ['duckpgq']; opt-in, so DuckDbBridge.ensure_duckpgq() now runs it after LOAD duckpgq; (including when the caller already loaded the extension), and the embedded DuckPGQ tests, PGQ conformance corpus and live harnesses do the same.
  • Consistent CLI -h and --help Summaries (#431): aligned the top-level voyager command and all subcommands (doctor, introspect, compile, validate) so -h and --help start with the same summary sentence and describe user-facing behaviour without naming internal crates or functions.

Fixed

  • DuckDB TIMETZ/INTERVAL edge cases, nested temporal values and DuckPGQ grammar extension (#442):
    • DuckDbBridge.execute() now retains TIMETZ UTC offsets when a result also contains INTERVAL values (and keeps HUGEINT as Python int and UUID as uuid.UUID) by projecting TIMETZ to ISO text before reading Arrow month_day_nano_interval.
    • DuckDbBridge.execute(), execute_to_arrow(), and execute_to_polars() (including inside Session.transaction()) now run DML RETURNING and multi-statement SQL through the single-execution con.sql() relation path, preserving both TIMETZ offsets and calendar INTERVAL months with one execution.
    • Nested TIMETZ and INTERVAL values inside STRUCT, MAP, LIST, ARRAY, and UNION columns now preserve TIMETZ offsets and calendar INTERVAL months across execute(), Arrow, and Polars (even when no top-level INTERVAL column is present), while preserving Arrow Map/Struct/List schemas on empty, mixed-row, and 0-row results.
    • _duckdb_timetz_text_iso() now parses and validates DuckDB/ISO TIMETZ text (±HH[:MM[:SS]], Z, ±HHMM[SS]) via datetime.time.fromisoformat() and raises ValueError/TypeError on unrecognized or naive inputs instead of passing them through.
    • DuckDbBridge.ensure_duckpgq() now reads current_setting('active_grammar_extensions') and appends 'duckpgq' instead of overwriting other enabled grammar extensions.
  • DuckDB TIMETZ columns with calendar INTERVAL exports (#439): DuckDbBridge.execute_to_arrow() and execute_to_polars() now keep DuckDB's Arrow export when a result contains a TIMETZ column, projecting only the TIMETZ / TIMETZ[] columns to ISO text tagged voyager.type=time_tz instead of rebuilding the whole result from DB-API rows, so INTERVAL columns keep month_day_nano_interval calendar months (for example 1 year 2 months stays 14 months instead of 420 days). A single query statement now runs exactly once as a lazy relation (columns and types come from the relation, then one materialization), so volatile expressions such as nextval() advance once; DML and multi-statement input keep the eager single-execution DB-API path. The same path applies inside Session.transaction().
  • Native PostgreSQL mixed-depth array columns (#440): native Session.execute() no longer raises when a PostgreSQL array column's non-empty rows have different depths; the column falls back to the JSON-encoded representation tagged voyager.encoding=json (with raw per-row values for execute()), so it returns per-row shapes like psycopg and PostgresBridge, including NULL elements, empty arrays and typed elements. numeric elements stay decimal.Decimal and uuid elements stay uuid.UUID in execute(), matching psycopg, while execute_to_arrow() / execute_to_polars() expose the documented JSON text column. Single-depth columns keep their typed nested List columns (#432).
  • Native PostgreSQL multidimensional array results (#432): Session(..., backend="native") now decodes 2-D and 3-D PostgreSQL array columns into nested Python lists, matching psycopg and PostgresBridge, including NULL elements, empty arrays and non-default lower bounds (which are ignored like psycopg). execute_to_arrow() and execute_to_polars() expose the same values as nested List columns for every element type the 1-D decoder supports (integer, float, numeric, text, boolean, date, timestamp, timestamptz, uuid and jsonb). The value conformance pack covers nested arrays on PostgreSQL 19.
  • PostgreSQL JSON parameter encoding, native and bridge (#421): Python dicts and voyager_ogm.Json(...) values bind as jsonb on the native driver and PostgresBridge. Lists keep the array behaviour psycopg has: lists of scalars stay typed SQL arrays, a list of dicts becomes jsonb[] (one JSON element per dict), and nested lists become multidimensional arrays. A placeholder explicitly cast to json/jsonb (for example $v::jsonb) binds any list as one JSON document, so an empty list becomes [] and never the JSON object {}; without such a cast an empty list remains an empty SQL array literal for array-typed slots. Json(...) is the escape hatch for forcing JSON in any context, including JSON null, scalar lists and ragged nested lists, and is unwrapped for AGE, Bolt, FalkorDB and DuckDB. The value conformance pack no longer records the PostgreSQL JSON parameter differences.
  • Float precision through JSON text (#422): serde_json now parses with float_roundtrip, so native PostgreSQL jsonb results and Apache AGE agtype parameters, results and nested list/map values round-trip f64 exactly (including subnormal values and 1.7976931348623157e+308). Non-finite JSON numbers written inside containers are emitted as NaN/Infinity/-Infinity, and reading accepts those tokens plus out-of-range numeric literals (returning Python inf/-inf, like psycopg) instead of raising number out of range. The value conformance pack no longer records the PostgreSQL and Apache AGE float differences.
  • Bolt 5.x version range negotiation and 4.4 UTC fallback (#414): BOLT_PROPOSED_VERSIONS now proposes Bolt 5.4..=5.0 and 4.4..=4.2 ranges so Memgraph negotiates Bolt 5.2 (sending HELLO without bolt_agent for 5.1..=5.2 followed by LOGON) and uses UTC temporal tags (0x49/0x69), preserving fold=1 DST instants and emitting typed Timestamp / pl.Datetime columns with timezones. Bolt 4.4 connections request patch_bolt: ["utc"] and keep the legacy 0x46/0x66 path when unpatched. Exposes negotiated protocol version on AsyncConnection, NativeClient, and PyNativeClient.protocol_version_sync(). Native Memgraph nodes and relationships now also carry element_id (a Bolt 5 field), matching the bridge.
  • **Native Bo...
Read more

Voyager OGM v0.5.0-alpha.1

Pre-release

Choose a tag to compare

@github-actions github-actions released this 27 Nov 06:22
v0.5.0-alpha.1
bc8ecba

First alpha of the 0.5 line. The theme is a portable query interchange format and the same values everywhere: Query Spec v1 with a JSON Schema, reference vectors and a conformance corpus, a working voyager CLI, live schema introspection, and native backends that return the same Python types as the bridges and the official clients.

Highlights of 0.5.0-alpha.1:

  • Query Spec v1: a Rust consumer (#289) with a JSON Schema, reference vectors (#188), strict validation with INVALID_SPEC and a JSON Pointer (#187), a revision and compatibility policy (#292), and serialisation from the fluent API (#189).
  • Conformance corpus: packs P0-P4 (#253-#258) run live on Neo4j, Memgraph, FalkorDB, Apache AGE and PostgreSQL 19 through three lanes, official clients, Voyager bridges and native (#297). A generated value conformance pack (#299) compares values and Python types across every path.
  • CLI v1: voyager doctor, compile, validate and introspect (#119, #265), released as binaries for six targets, through cargo binstall and as the voyager-cli wheel, with voy as a short alias (#133).
  • Same values on every backend: typed native parameters (#391) and stdlib result types with the new voyager_ogm.Duration (#395); GraphNode, GraphRelationship and GraphPath results (#372); decoded Apache AGE results (#353).
  • Models and schema: field value constraints (#282), declarative relationship navigation (#121), model schema export (#125), table DDL for SQL/PGQ (#327).
  • TLS for the native drivers (#219).

Breaking changes (details in the entries below):

  • Result values: native backends return stdlib Python types and Duration instead of strings (#395); native PostgreSQL parameters are typed, so comparing a text column with a UUID or datetime parameter needs a cast (#391); Rust QueryResult is #[non_exhaustive].
  • Entities: whole nodes, relationships and paths come back as GraphNode / GraphRelationship / GraphPath on every engine (#372); Apache AGE results are decoded (#353) and a single whole entity is keyed by its variable (#285); AGE and SQL/PGQ column aliases keep their case (#377).
  • Query Spec v1 is strict: one spelling per construct (#292), invalid, dropped or misattached clauses raise INVALID_SPEC (#187), and references the emission order cannot honour are rejected (#271).
  • Fluent API: variable scope is checked before compiling (#287) and aggregations must sit in a projection (#272).
  • Models: Field nullability is inferred from the type annotation (#332).
  • SQL/PGQ property-graph DDL names tables and edge keys consistently (#325); SQL/PGQ on PostgreSQL is experimental (#373).
  • The FalkorDB driver bridge honours the graph name from graph_name= or the URI (#339).

Added

  • Value Conformance Pack (#299): a live, Hypothesis-generated differential test pack (packages/python/tests/values/) runs 19 value kinds through every engine (Neo4j, Memgraph, FalkorDB, Apache AGE, PostgreSQL 19, DuckDB) and compares value and Python type across the official client, the bridge, the native backend and native execute_to_arrow() / execute_to_polars(), as a parameter, stored as a property or column, nested in lists and maps, as node and relationship properties, and inside a transaction. just values-live [engine] [--seed N] [--examples N] [--exploratory] runs it (fixed seed by default, an opt-in exploratory profile), a failure prints a per-stage trace (Python value, Voyager parameter, wire encoding, server type, Arrow type, Python result), every run writes an engine x backend x value-kind matrix to target/values-conformance/, and known_differences.json records each accepted difference with a reason (and issue number for bugs); an entry that stops occurring fails the run. Adds the diagnostic voyager_ogm._voyager_rs.inspect_native_wire() and the hypothesis dev dependency.
  • Query Spec v1 Revisioning and Compatibility Policy (#292): Query Spec v1 now has a revision alongside its major version. Documents may carry an optional integer spec_revision (minimum 1) at the root and in nested specs; a missing or null value means revision 1, today's format. The Rust core is the source of truth through voyager_ogm::spec::SPEC_VERSION and voyager_ogm::spec::SPEC_REVISION, Python exposes voyager_ogm.QUERY_SPEC_VERSION / voyager_ogm.QUERY_SPEC_REVISION, and voyager doctor prints the supported query spec: v1 revision 1. A document that requires a newer revision is rejected with INVALID_SPEC at /spec_revision and a message naming the supported revision. Query.to_spec_dict() and Expression.to_spec_dict() now emit spec_revision, so exported documents are self-describing. The schema keeps its stable v1 $id and records the revision in a new x-spec-revision annotation; spec/README.md gains a "Compatibility and versioning" section covering the major + revision rule, what counts as an addition versus a break, the 1.0.0 guarantee (0.x may still break, with each change bumping the revision and listed as breaking), the pre-optimisation export guarantee, and the revision-bump checklist.
  • Multi-Platform CLI Release Binaries, cargo-binstall Metadata, and voyager-cli Python Wheel (#133): .github/workflows/release.yml now builds, smoke-tests, and attests standalone voyager archives (voyager-cli-v<version>-<target>.tar.gz / .zip) across six targets (x86_64-unknown-linux-gnu, static x86_64-unknown-linux-musl with rustls/ring, aarch64-unknown-linux-gnu, aarch64-apple-darwin, x86_64-apple-darwin, and x86_64-pc-windows-msvc), attaches them with SHA256SUMS and actions/attest-build-provenance provenance to the GitHub Release, adds [package.metadata.binstall] to crates/voyager-cli/Cargo.toml for cargo binstall voyager-cli, and builds/publishes the lockstep voyager-cli Python wheel (packages/cli/pyproject.toml, bindings = "bin") wired into voyager-ogm[cli] and verified by scripts/check_version_sync.py. The Linux -gnu binaries are linked against glibc 2.28, the same baseline as the manylinux_2_28 wheels. The CLI is a single voyager binary: the archives add the short alias voy as a symlink (a voy.cmd shim on Windows), while cargo install, cargo binstall and the wheel install voyager only.
  • Live Corpus Voyager Lanes (#297): the live conformance corpus now runs each scenario through three lanes: official (today's engine clients and the AGE/SQL-PGQ Session reference path), bridge (Session over the Python bridges) and native (Session(..., backend="native") over voyager-drivers for Neo4j, Memgraph, FalkorDB, Apache AGE and PostgreSQL 19 SQL/PGQ). Fixtures load through the same official loaders, so only statement execution differs. just corpus-live [engine] [lane] selects one engine/lane or all, defaults to the previous official-only behaviour, and prints a per-lane/per-engine pass/fail/skip summary. Differences are compared structurally (scenario, lane, engine, column, expected, actual) against canonical rows.json values including node labels and relationship types. Reviewed differences live in spec/corpus/known-lane-differences.json; an unexplained difference fails, and an entry that no longer matches fails with "known lane difference is fixed, remove from ...". spec/corpus/README.md documents the lanes, the list and the commands.
  • Result Column Names on ExecutionResult (#378): Session.execute() and AsyncSession.execute() results (ExecutionResult, and result.mappings()) now expose a read-only columns property (tuple[str, ...]) and a keys() method (list[str]) in projection order, populated from driver metadata (Bolt keys, FalkorDB header, PostgreSQL/Apache AGE and DuckDB/Relate cursor description, and the native Arrow schema on ArrowStream) even when zero rows are returned, and empty for write statements without RETURN/RETURNING. ExecutionResult.to_polars(), ExecutionResult.to_arrow(), Session.execute_to_polars(), and Session.execute_to_arrow() (sync and async, bridge and native) now preserve those column names on empty results.
  • Reference Cypher Override for Recording Known-Diff Corpus Rows (#307): scenario.json now supports an optional reference_cypher object (statement, reason, and optional params), validated against scenario.schema.json and only allowed when targets.cypher.status is not supported. just corpus-record-rows runs reference_cypher.statement on Neo4j to reproduce rows.json and refuses to silently fall back to a known-diff compiled Cypher statement when reference_cypher is absent.
  • Relational Table DDL Generation for SQL/PGQ (#327): SchemaManager.generate_table_ddl(*models, dialect="postgres"|"duckdb") generates CREATE TABLE IF NOT EXISTS statements for vertex and edge tables using the #325 naming rule, endpoint foreign keys, dialect-specific type mapping, and surrogate primary keys on edge tables to allow parallel edges (or declared primary keys when defined). SchemaManager.generate_pgq_schema_ddl(graph_name, *models, dialect="postgres"|"duckdb") emits tables, sequences, constraints, indexes, and property-graph DDL in run order for PostgreSQL 19 and DuckPGQ.
  • Declarative Relationship Navigation on Node Models (#121): RelationshipTo and RelationshipFrom declare outgoing and incoming relationship attributes on Node models. Targets and optional relationship models accept classes or strings, string forward references (including circular model references) resolve on first use, and an unknown name raises a clear LookupError. Class access returns the descriptor; instance access returns a manager and never queries. The sync manager's .all() / .filter(...) and the AsyncSession manager's awaitable equivalents match the source by primary key, traverse in the declared direction, filter fluently, project one column per declared target property with stable aliases, and hydrate targe...
Read more

Voyager OGM v0.4.3

Choose a tag to compare

@github-actions github-actions released this 23 Nov 21:26
v0.4.3
fae2ea7

Deprecated

  • Unquoted SQL/PGQ labels: from 0.5.0, SQL/PGQ quotes labels in the generated CREATE PROPERTY GRAPH DDL and in queries (IS "Person"), so labels are case-exact as in Cypher and reserved words such as User and Order work as labels. A property graph created with unquoted mixed-case labels will need to be re-created with DROP PROPERTY GRAPH and the DDL from SchemaManager.generate_pgq_ddl(...); tables and data are not affected. 0.4.x keeps unquoted labels.

Fixed

  • SQL/PGQ and DuckPGQ IN with a list or list parameter (#303): the emitter now writes x IN (a, b) for a literal list and x = ANY($p) for a list parameter (NOT IN (a, b) / x <> ALL($p) when negated); an empty literal list compiles to FALSE (TRUE for NOT IN). The DuckDB bridge rewrites the parameter forms to a scalar IN (...) tuple because DuckPGQ's GRAPH_TABLE grammar has no ANY/ALL.
  • SQL/PGQ and DuckPGQ XOR lowering (#304): XOR now compiles to ((a) OR (b)) AND NOT ((a) AND (b)) instead of the unsupported keyword, preserving the three-valued result when either side is NULL.
  • SQL/PGQ string predicate placeholder escaping in PostgresBridge (#305): PostgresBridge._format_pgq_statement now escapes literal % characters as %% when query parameters are bound positionally as %s, preventing psycopg from misinterpreting LIKE wildcard patterns (such as in STARTS WITH, ENDS WITH, and CONTAINS) as invalid formatting placeholders.
  • SQL/PGQ string predicates match the search value literally (#318): STARTS WITH, ENDS WITH and CONTAINS compile to starts_with, right/length and strpos instead of LIKE, so %, _ and \ in the search value are no longer wildcards on PostgreSQL 19 and DuckPGQ.
  • SQL/PGQ ORDER BY on expressions outside GRAPH_TABLE (#319): ordering expressions that are not returned columns are now evaluated inside GRAPH_TABLE COLUMNS under an internal alias and selected only as returned columns in the outer query, so pattern variables are in scope on PostgreSQL 19 and DuckPGQ.
  • SQL/PGQ ORDER BY on non-returned properties (#320): ordering by a property that is not projected now exposes it in GRAPH_TABLE COLUMNS under an internal alias, avoiding missing-column errors in the outer query on PostgreSQL 19 and DuckPGQ.

Security

  • Credentials no longer appear in Debug output (#326): Auth, ParsedUri and ConnectionConfig format with a hand-written Debug that shows a configured password or token as "***" (and an empty one as None), redacting URI userinfo and credential-named query parameters, and a malformed-URI error no longer echoes the password. Serialised configurations still contain the secret so they round-trip, and the type docs say so.

Voyager OGM v0.4.2

Choose a tag to compare

@github-actions github-actions released this 22 Nov 17:19
v0.4.2
f255b41

Fixed

  • SQL/PGQ parameter binding in Python bridges (#226): PostgresBridge._format_pgq_statement now binds GRAPH_TABLE parameters positionally as %s placeholders like standard SQL instead of interpolating parameter values directly into the SQL statement, supporting prepared statements, duplicate parameter names, and preventing injection from hostile values. DuckDbBridge safely encodes values for GRAPH_TABLE queries as typed SQL literals (strings with quote-doubling, ints, floats including 'nan'::DOUBLE / 'inf'::DOUBLE, booleans, NULL, dates, datetimes, times, lists, and maps) and raises TypeError for unsupported parameter types, working around DuckPGQ's lack of prepared parameter support inside table function ASTs.

  • Native PostgreSQL list parameter encoding (#283): prepare_postgres_statement and value_to_text in the native PostgreSQL driver now encode JSON array parameters as PostgreSQL array literal text ({elem,elem}) with double-quoting and backslash-escaping for strings, NULL for null elements, nested arrays, unquoted numbers and booleans, and quoted JSON text for nested maps, instead of sending JSON text ([...]). This enables list parameters to be bound where PostgreSQL expects an array (such as = ANY($1) or array columns in plain SQL and GRAPH_TABLE), matching the behaviour of the psycopg bridge while preserving JSON encoding for top-level maps and Apache AGE parameter maps.

  • Apache AGE queries returning several nodes or relationships (#285): the AGE column definition list repeated entity for every whole node or relationship (AS (entity agtype, entity agtype, ...)), so PostgreSQL rejected the query with column name "entity" specified more than once. When a query returns several whole nodes or relationships, their columns are now named after the returned variables (AS (a agtype, r agtype, b agtype)), and any repeated column name gets a numeric suffix (name, name_1, ...). A query returning a single whole node or relationship still keys it entity, so code reading row["entity"] keeps working.

  • Compile-time validation of unsupported pattern and column constructs (#286): AgeEmitter and SqlPgqEmitter (shared by DuckPGQ) now reject unsupported graph patterns and projections at compile time with UnsupportedFeature across both the fluent builder and compile_query_from_spec: Apache AGE rejects node patterns with multiple labels and relationship patterns with alternative types, while SQL/PGQ rejects node patterns with multiple labels (conjunction), node and relationship expressions using negation, conjunction, grouping, or wildcard, and whole node or relationship variables in the COLUMNS clause. Valid single-label node patterns, node label disjunction (IS A | B), SQL/PGQ relationship type alternation (-[r IS KNOWS | HATES]->), and property column projections remain supported and unchanged.

  • Query.set() no longer drops arguments silently (#295): set(), on_create_set() and on_match_set() skipped arguments they did not recognise, so the query was compiled without the SET and the write never happened. They now raise VoyagerError (INVALID_CLAUSE) for:

    • keyword arguments without a variable prefix (city="Berlin", p={"city": "Berlin"}) or with an empty part ("p.", ".city");
    • positional values that are not an assignment such as p.city == value or a Node. This includes comparisons such as p.city > 10, which were written as SET p.city = 10.

    Code passing such arguments now gets an error instead of a query without the SET. The supported forms compile as before, and a Node with no changed fields is still a no-op. on_create_set() / on_match_set() also accept a Node with changed fields, like set().

  • Inequality compiles to <> (#301): neq, ne, != and <> inputs now emit <> instead of != on Cypher, Apache AGE, ISO GQL and SQL/PGQ, so Neo4j, FalkorDB and Apache AGE accept the statement.

  • not_in compiles to NOT (x IN list) (#302): .not_in(...) and Query Spec not_in now emit NOT (x IN list) on Cypher, Apache AGE and ISO GQL; SQL/PGQ keeps infix NOT IN for now (#303).

Security

  • url updated to 2.5.9 (RUSTSEC-2026-0592): url 2.5.8 and earlier can overflow the stack in Url::origin() on nested blob: URLs. Voyager does not call Url::origin(); the update clears the advisory for builds that use the lockfile.

Voyager OGM v0.4.1

Choose a tag to compare

@github-actions github-actions released this 21 Nov 09:00
v0.4.1
8bbe6b3

Changed

  • README installation guide: added an Installation section covering PyPI and uv installs, optional extras, supported Python versions and platforms, the crates.io crates and Cargo features, the voyager CLI, pre-release installs, and the Rust MSRV. Added PyPI, Python, crates.io, and docs.rs badges and converted relative links to absolute GitHub URLs so the README renders correctly on PyPI.
  • Crate README badges: added crates.io, docs.rs, CI, license, and MSRV badges to the voyager-ogm, voyager-drivers, and voyager-cli READMEs, and split multi-command install snippets into one command per code block.
  • Pre-releases publish to crates.io: release tags with a pre-release suffix (-alpha.N, -beta.N, -rc.N) now publish the Rust crates to crates.io as well as the Python package to TestPyPI; PyPI still receives stable releases only.
  • Maintenance-branch releases: releases can now be prepared and tagged from release/X.Y branches (cut from the vX.Y.0 tag) so patch fixes still ship after main moves to the next minor. just release-prepare and just release-tag validate the base line and version (a release/X.Y base accepts only X.Y.N), CI runs on release/**, and the release workflow refuses tags not reachable from main or the matching release branch and marks a tag Latest only when it is the highest v* version.

Fixed

  • PyPI package page: voyager-ogm now uses a Python-focused packages/python/README.md as its PyPI long description instead of the repository-wide root README.
  • ISO GQL quantified edges (#267): a path with a single quantified edge now emits the same per-edge form as multi-edge paths ((a:Person)-[r:KNOWS]->{1,3}(b:Person)) instead of wrapping the whole path (((a:Person)-[r:KNOWS]->(b:Person)){1,3}), preserving endpoint labels, direction, edge properties, open bounds and path variables. Hop bounds with max_hops < min_hops are now rejected by the builder with INVALID_CLAUSE for every dialect and both the Rust and Python APIs.
  • ISO GQL unsupported constructs (#269): ISO GQL now raises UNSUPPORTED_FEATURE instead of silently dropping or changing the meaning of LOAD CSV, DETACH DELETE, MERGE with distinct ON CREATE SET / ON MATCH SET assignments, and the regular-expression operator =~. Behaviour change: queries that previously compiled to incomplete or semantically different GQL now fail with a clear error. MERGE with empty or identical ON CREATE SET / ON MATCH SET assignments continues to emit UPSERT ... SET. This includes Session saves with dialect="iso_gql" of models that have create-only defaults: they previously compiled to a single SET that overwrote create-only fields (such as creation timestamps) on every update, and now raise instead.
  • SQL/PGQ emitter silent drops (#268): OPTIONAL MATCH, LOAD CSV, EXISTS/COUNT subqueries, list and pattern comprehensions, and the =~ regex operator now raise a clear UnsupportedFeature error in the SQL/PGQ and DuckPGQ dialects instead of being silently dropped, emitting invalid syntax, or leaking a Rust AST debug dump. RETURN DISTINCT now emits SELECT DISTINCT, and a query with no projections raises a clear error instead of emitting COLUMNS ().
  • SQL/PGQ graph name validation (security, #270): the graph name interpolated into GRAPH_TABLE (...) is now validated as a plain identifier (ASCII letters, digits, and underscores, 1-63 characters) in the emitter, covering the fluent API and compile_query_from_spec(graph_name=...), so names containing SQL metacharacters, quotes, semicolons, spaces, or an empty name are rejected instead of being written into the statement.

Security

  • Identifier injection (#186): every identifier written into emitted query text (node and edge variables, labels, relationship types, property names, aliases, path, unwind, and let variables, delete targets, parameter names, function and procedure names, and procedure yield items) is now validated at a single pre-emission choke point shared by the Cypher, AGE, ISO GQL, and SQL/PGQ emitters, so both the fluent API and compile_query_from_spec reject values that are not plain identifiers (_ or a Unicode letter first, then Unicode letters, digits, or _; function and procedure names may join identifiers with single dots). Behaviour change: names containing spaces, quotes, backticks, parentheses, braces, $, /, -, ;, or empty names now raise INVALID_CLAUSE instead of being written into the query; delimited (backtick-quoted) identifiers are not supported in this patch. Valid Unicode labels and existing generated aliases such as _person_0, p0, and apoc.coll.sum are unchanged. Expression depth is also carried through exists/count/nested-spec re-entry, so deeply nested subqueries raise the existing depth error instead of exhausting the stack.

Voyager OGM v0.4.0

Choose a tag to compare

@github-actions github-actions released this 20 Nov 18:10
v0.4.0
4bec6ad

First stable release of the 0.4 line: the first release on PyPI (voyager-ogm) and the first stable release on crates.io (voyager-ogm, voyager-drivers, voyager-cli, which carried 0.4.0-alpha.8 as their initial version). It consolidates the 0.4.0-alpha.5 to 0.4.0-alpha.8 pre-releases below; see those sections for the full list.

Highlights of the 0.4 line:

  • One query, many engines: a fluent query builder (Python and Rust) with rich expressions, subqueries, a rule-based optimizer and query profiling, compiled to openCypher (Neo4j, Memgraph, FalkorDB), ISO GQL, SQL:2023 PGQ (PostgreSQL 19, DuckDB) and Apache AGE.
  • Native drivers: voyager-drivers speaks Bolt, the PostgreSQL wire protocol and Redis/RESP directly, with pooling, real transactions and bound parameters; protocols are opt-in Cargo features.
  • OGM workflow: Node / Relationship models with field defaults, description metadata and module-qualified identity; Query.create_relationship / merge_relationship; identity map, unit of work and real database transactions (session.transaction()); bulk ingestion that keeps properties a row does not supply.
  • Schema and search: multi-dialect constraint and index DDL, full-text and vector indexes, temporal and spatial types, and a schema registry with snapshots.
  • Data tooling: Arrow / Polars results, NetworkX export, file and cloud-storage ingestion, an embedded Relate bridge and an interactive graph viewer.
  • Packaging: pip install voyager-ogm works with only polars and pyarrow; optional integrations install as extras. Linux wheels target manylinux_2_28; releases are published through trusted publishing.

Breaking changes in the 0.4 line are marked Breaking in the sections below (notably session.transaction() now opening a real database transaction, the voyager-net -> voyager-drivers rename, and removed legacy builder aliases).

Changed

  • License texts in crate packages (#247): voyager-ogm, voyager-drivers and voyager-cli now ship LICENSE-MIT and LICENSE-APACHE in their crates.io packages (symlinked to the repository root files), and the voyager-ogm README status line no longer names a specific version.
  • crates.io and docs.rs documentation (#245): rewrote the voyager-ogm, voyager-drivers, voyager-cli, and voyager-pyo3 crate READMEs, shared the voyager-ogm and voyager-drivers READMEs as their crate docs, added a just test-doc doctest gate (in just test / just ci and CI), refreshed CONTRIBUTING.md, and moved the benchmark charts into benchmarks/README.md after removing the main README's Performance & Benchmarks section.

Voyager OGM v0.4.0-alpha.8

Pre-release

Choose a tag to compare

@github-actions github-actions released this 20 Nov 12:52
v0.4.0-alpha.8
5b5c8f7

Fixed

  • Base install import failure (#239): import voyager_ogm no longer requires SQLAlchemy or any other optional extra. SQLAlchemy-backed names are resolved lazily and raise an ImportError naming voyager-ogm[sqlalchemy] when used without the extra; optional bridge, analytics, and hybrid helpers name their extra too. Added a base-only wheel smoke test to CI and the release workflow.
  • Portable Linux wheels (#240): Linux x86_64 and aarch64 wheels are now built against manylinux_2_28 in the matching container instead of the runner host, and the release workflow verifies every Linux wheel filename carries that tag before publishing.

Voyager OGM v0.4.0-alpha.7

Pre-release

Choose a tag to compare

@github-actions github-actions released this 20 Nov 10:30
v0.4.0-alpha.7
4fb432f

Warning

Known issue: import voyager_ogm fails with ImportError: cannot import name 'GraphTableClause' unless SQLAlchemy is installed. Install with pip install "voyager-ogm[sqlalchemy]" (or pip install sqlalchemy) when using these wheels. The Linux x86_64 wheel also requires glibc 2.34 or newer. Both are fixed in the next pre-release.

Added

  • Driver Cargo Features and Feature-Matrix CI (#218):
    • Added bolt, postgres, redis, arrow and testkit Cargo features to voyager-drivers; bolt, postgres, redis and arrow are on by default, so default builds and the Python package are unchanged, while testkit stays opt-in.
    • A URI or client that targets a protocol whose feature is disabled now returns a clear NetError naming the missing feature instead of failing to compile or panicking.
    • Declared required-features on the driver tests, benches, examples and binaries, and made voyager-pyo3 / voyager-cli enable the features they use explicitly.
    • Added a Feature Combinations CI job and a matching just check-features recipe that clippy-check the core feature combinations and each driver protocol alone.
  • Description Metadata for Fields, Nodes, and Relationships (#210):
    • Added optional description: str | None = None parameter to Field() descriptor and description attribute to Field instances.
    • Added support for model-level description metadata via __description__ class attribute on Node and Relationship models.
    • Carried descriptions through schema registration into native FieldDescriptor, NodeSchema, and RelationshipSchema structs in Rust and exposed them via PyO3 dictionary bindings.
    • Updated schema snapshot serialization to include "description" fields in JSON snapshots when present, omitting them when None via serde skip_serializing_if so existing snapshot JSON remains byte-identical.
    • Ensured backward compatibility: older snapshots without description keys deserialize cleanly via serde default with description: None.
  • Fluent Relationship Creation Between Bound Nodes (#192):
    • Added Query.create_relationship(source, rel, target, *, variable=None) to emit CREATE (source)-[:TYPE {props}]->(target) between aliases already bound by MATCH or an earlier CREATE.
    • Added Query.merge_relationship(source, rel, target, *, variable=None) with the existing MERGE key policy: key properties inline, shared properties on create and match, and default-filled properties on create only. When non-key properties need ON CREATE SET / ON MATCH SET, the relationship alias is taken from the instance or generated automatically, so variable= is not required.
    • Added native Rust builder methods QueryBuilder::create_relationship and QueryBuilder::merge_relationship that validate bound endpoint aliases, parameterize relationship properties, and emit for openCypher, ISO GQL (INSERT / UPSERT), and Apache AGE.
    • Relationship direction is honored; undirected relationships are created or merged as outgoing from source to target because Cypher requires a direction. An optional relationship variable alias allows the edge to be returned.
  • Bridge Authentication Credentials Parameter (#193):
    • Added keyword-only auth: tuple[str, str] | Any | None = None parameter to create_bridge() across all overloads.
    • Bolt schemes accept (username, password) tuples and custom auth tokens (e.g. bearer_auth) passed directly to GraphDatabase.driver / AsyncGraphDatabase.driver.
    • PostgreSQL and Apache AGE schemes accept (username, password) tuples passed as user= / password= connect keyword arguments; invalid types raise TypeError.
    • FalkorDB and Redis schemes accept (username, password) tuples passed as username= / password= keyword arguments to FalkorDB.from_url.
    • Explicit auth= takes precedence over credentials in URI strings.
  • Unified Examples Learning Path, OGM-First Modernization, and Rust Parity (#172):
    • Streamlined Python examples into a single progressive beginner-to-advanced learning path (01 to 31) with OGM-first declarative modeling, mutation DSL, and consistent setup and offline skip handling.
    • Added idiomatic Rust examples covering schema DDL and index emission (08), mutation builder (09), bulk ingestion compilation (10), transactions and unit of work (11), vector/full-text search query building (12), and live engine execution (live_connect_and_query).
    • Added new Python examples covering real engine bridges via create_bridge() and mock fallbacks, embedded Relate (relate://), bulk ingestion, transactions with savepoints and identity map, multi-engine live execution (Memgraph, FalkorDB, Apache AGE), vector and full-text search, mutation DSL, and standalone AsyncSession / HybridSession.
    • Added just examples-live recipe and updated examples-python and examples-rust to run all offline examples.
  • Embedded Relate Database Bridge (#157):
    • Added RelateBridge and AsyncRelateBridge in voyager_ogm.bridge, exported from voyager_ogm, for in-process, zero-network execution against embedded Relate databases (relatedb.ai).
    • Added auto-instantiation support in create_bridge() for relate:// and relatedb:// URI schemes and connection instance auto-detection.
    • Added the relate optional dependency extra (pip install "voyager-ogm[relate]", relate-db>=1.0.0).
    • Added Relate-compatible parameter and result adaptation: spatial Point and duration conversion, nested dict/list parameter mapping, and node/relationship record normalization.
    • Added sync and async bulk batch ingestion plus ping() liveness and explicit connection close on both bridges.
    • Added a Relate compatibility test suite covering schema creation, CRUD, traversal, aggregation, and parameter round-trips.
  • NetworkX Graph Analytics Export Bridge (#117):
    • Added direct, high-performance .to_networkx() graph export on ExecutionResult, QueryResult, and top-level module voyager_ogm.to_networkx.
    • Added fluent session.query(...) and async_session.query(...) builders supporting direct .where(...).to_networkx() chaining.
    • Supported directed (DiGraph, MultiDiGraph) and undirected (Graph, MultiGraph) graph generation with node/edge attribute filtering and relationship type preservation.
    • Added explicit node_only=True escape hatch and source_col="" support to disable automatic tabular edge heuristic detection.
    • Added analytics optional dependency extra (pip install "voyager-ogm[analytics]").
  • File, S3, and Azure Cloud Ingestion Loaders (#110):
    • Added zero-copy, lazy-scanned cloud and local file loaders directly on Session, AsyncSession, and top-level module APIs (ingest_parquet, ingest_csv, ingest_parquet_relationships, ingest_csv_relationships).
    • Added create_parquet_ingest_plan, create_csv_ingest_plan, create_parquet_rel_ingest_plan, and create_csv_rel_ingest_plan with support for "create" / "upsert" modes, field remapping, and multi-cloud authentication via Polars storage_options.
  • Session Liveness Probes and Health Monitoring (#118):
    • Added Session.ping(), AsyncSession.ping(), Session.health(), and AsyncSession.health() for fast backend liveness verification and diagnostics.
    • Added SessionHealth diagnostic dataclass capturing roundtrip latency, backend mode, and circuit breaker status.
  • Full-Text Index DDL Generation and Query Integration (#113):
    • Added declarative FullTextIndex(properties, name=None, analyzer="standard") configuration to voyager_ogm.schema and re-exported in voyager_ogm (with TextIndex and fulltext_index developer ergonomics aliases).
    • Added model metadata reflection on Node and Relationship subclasses via __fulltext_indexes__.
    • Implemented multi-dialect full-text index DDL generation and drop statements in voyager-ogm:
      • Neo4j 5+ / openCypher: CREATE FULLTEXT INDEX {index_name} IF NOT EXISTS FOR (n:{label}) ON EACH [n.{p1}, ...] OPTIONS {indexConfig: {fulltext.analyzer: '{analyzer}'}} (and FOR ()-[r:{type}]-() ON EACH [r.{p1}, ...]) with DROP INDEX {index_name} IF EXISTS.
      • Memgraph (MAGE Tantivy): CREATE TEXT INDEX {index_name} ON :{label_or_type}({props}); for nodes and CREATE TEXT EDGE INDEX ... for relationships, with DROP TEXT INDEX {index_name};.
      • DuckDB (fts): PRAGMA create_fts_index('{table}', '{pk}', '{props}'); and PRAGMA drop_fts_index('{table}');.
      • FalkorDB (RediSearch): CREATE FULLTEXT INDEX FOR (n:{label}) ON (n.{p1}, ...) (and FOR ()-[r:{type}]-() ON (r.{p1}, ...)) with matching DROP FULLTEXT INDEX statements.
      • Apache AGE / PostgreSQL (GIN): GIN index creation on to_tsvector over concatenated properties and DROP INDEX IF EXISTS {index_name}; (verified via compiled DDL snapshot tests).
    • Centralized canonical full-text index naming authority (canonical_fulltext_index_name) in voyager-ogm, exposed via PyO3 to Python to prevent dual bookkeeping.
    • Added full-text search query builder Query.fulltext_search(index_or_model, query_string, yield_node="node", yield_score="score", dialect="cypher") (with Query.text_search alias):
      • openCypher: routes to db.index.fulltext.queryNodes and db.index.fulltext.queryRelationships.
      • Memgraph: routes to text_search.search_all (or text_search.search for field queries with automatic Tantivy data.<field> property mapping) and text_search.search_all_edges (or text_search.search_edges).
      • FalkorDB: routes to db.idx.fulltext.queryNodes and db.idx.fulltext.queryRelationships.
    • Added convenience session facades on Session.fulltext_search() / Session.text_search() and AsyncSession.fulltext_search() / AsyncSession.text_search().
    • Added model search entrypoints Node.text_search() / fulltext_search() and Relationship.text_search() /...
Read more