Release 0.5.44 #547
StevenBtw
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
[0.5.44] - 2026-10-04
Durability and consistency release. Crash-safe checkpoints and WAL recovery, indexes and constraints that survive a reopen, schema checks on every write path, per-graph conflicts and grants, commit and rollback in O(changes), and fixes for shortest paths, variable-length edges, list comprehensions, subqueries,
OPTIONAL MATCHandMERGE. Plus graph handles, upserts by key and write counters.Changed
grafeo-engine): the direct write methods returnResult(create_node,create_edge,set_node_property,delete_node, the batch calls and the rest, onGrafeoDBandSession). Each call commits on its own with the checks of a query, so writing to a missing entity or endpoint, or deleting a node that still has edges, now fails. The bindings raise these errors.grafeo-core): the mutation operators take aGraphWriterinstead ofwith_transaction_context,with_validatorandwith_write_tracker;SetPropertyOperator::with_labelsandwith_edge_typeare gone.grafeo-core): operators that only order, cut, deduplicate or compare rows take no output schema (LimitOperator,SkipOperator,LimitSkipOperator,SortOperator,TopKOperator,DistinctOperator,ShuffleOperator,ExceptOperator,IntersectOperator).grafeo-core): a sort key'sNullOrderno longer flips for a descending key (SortKey::descendingsetsNullsFirst), andvalue_utils::compare_values_with_nullsis replaced bycompare_sort_values.grafeo-core):FilterExpression::ExistsSubqueryandCountSubqueryhaveend_varandedge_var, andExistsSubqueryreadsmin_hopsandmax_hops.grafeo-engine): the transaction manager's write and read sets holdGraphEntity(graph plus node or edge), the logicalExpandOphas aquantifiedfield, andRdfPlanner::with_walis no longer public.grafeo-engine):ChangeEventhas agraphfield (Nonefor the default graph), andCdcLogkeys its events by graph and entity, withhistory_inandhistory_since_infor a named graph.grafeo-adapters): the GQLQueryClause::InlineCallhasscopeandcombinedfields, and the CypherClause::CallSubqueryis a struct variant withquery,scope,unionsandunion_all.labelsis now always the labels after the change, and the newbefore_labelsholds the previous ones.WITHwithout a name; aCALLsubquery that returns an outer variable or reads one it does not import (CALL () { ... }, a CypherCALL { ... }without an importingWITH); an importingWITHwith aWHERE, alias,ORDER BY,SKIPorLIMIT;UNIONmixed withUNION ALL; and a Cypher query that ends with aCALLsubquery that returns rows (add aRETURNafter it). Before, they gave wrong or silently null results, or failed with an internal error (see Fixed).Fixed
Every query result in the differential test corpus that differs from 0.5.43 is listed, with its reason, in
scripts/difftest/reviewed/0.5.44.txt.compact()left data out of the.grafeofile: the schema, indexes and RDF data were dropped (also atclose()), the periodic checkpoint wrote the pre-compaction store, andasync_write_snapshot()wrote little or nothing. Every checkpoint now writes the whole database..grafeofile that no longer opened (#418). Checkpoints now write to<file>.checkpointfirst, so the last good state stays readable; this needs free disk space for a second copy of the file.close()(#395). Each call is now durable when it returns, and batch calls are recovered completely or not at all..grafeofile.wal_checkpoint()lost data in WAL-directory databases (#419). It now only syncs the WAL there, and open replays every WAL file.DurabilityMode::Adaptivenever synced the WAL, so it behaved likeNoSync, and backups missed writes made while they ran; those now land in this backup or the next.create_graph()/drop_graph()were lost on WAL replay (#421, #422). An unknown WAL record now fails the open instead of being skipped.DROP CONSTRAINTdid nothing (#420). Constraints are now stored by name:CREATEandDROP CONSTRAINTsupportIF NOT EXISTS/IF EXISTS,SHOW CONSTRAINTSlists them, and unnamed ones get a name such asCity_name_not_null. Constraints from 0.5.43 files have no name and cannot be dropped by name..grafeodatabase orto_memory()lost its indexes (lookups on a reopened file scanned every node, #459), andto_memory()also dropped the schema, constraints and property history. WAL-directory databases still lose their indexes until 0.5.45 (#401).rdfprofile kept no data across a reopen (#544); the facade'srdfprofile now includes the LPG store.compact()missed parts of the database: SPARQL writes were lost, CDC missed queries, the selected graph was ignored, andget_node,node_count,info(),schema()and similar did not see pre-compaction data (or panicked on awith_storedatabase). Queries aftercompact()are still not written to the WAL, so a crash loses them; direct calls are logged.use_graph()skipped the grant check, read-only grants allowed writes, and read-only transactions, roles and databases let non-GQL languages and the direct API write. A session whose graph was dropped also fell back to the default graph; it now fails.SET,REMOVEand label changes on a node or edge deleted earlier in the statement or transaction (now... does not exist or has been deleted in this transaction, as in openCypher), writes from a session reading at an earlier epoch (set_viewing_epoch,execute_at_epoch), and writes aftercompact()on a database opened read-only. All of these now fail.SET,REMOVE,SET n:LabelandMERGEdid not check property types,NOT NULL,UNIQUE,NODE KEY, edge types, endpoint labels orDEFAULTvalues,UNIQUEdid not hold within a transaction, and multi-propertyUNIQUEandNODE KEYwere checked one property at a time. Every write is now checked likeINSERT, and a failedALTER NODE TYPEorALTER EDGE TYPEapplies all or none.execute(query, params)in Python and Node.js could insert a duplicateUNIQUEvalue. They now run exactly like the same statement with literals.$e(INSERT (:P {e: $e})) or failed with an internal error, and now fails withMissing parameter: $ebefore it writes anything; unaliased columns were named after a parameter's value (RETURN $xgave a column5) and are now named after the query text; andPROFILEwas ignored when parameters were passed (#460).temporalfeature (as in the Python and Node.js packages);REMOVE n.pandSET n.p = NULLnow remove the property.NodeRecord::props_countis now always 0), every hundredth commit scanned the whole store, and concurrent writes could deadlock withtiered-storage.id()or an indexed property scanned every node (#454, #356), once per row for keys likeUNWIND $rows AS row MATCH (n {id: row.id}), and with a label (MATCH (n:File {id: 'x'})) every node of that label was collected. They now seek directly, also forINlists and edge endpoints.LIKEpatterns were compiled for every row (#458); each is now compiled once.0, or read another entity's properties (#482): afterORDER BY,SKIP,LIMIT,DISTINCT, a laterUNIONbranch, a secondMATCH,OPTIONAL MATCH,EXISTS,CALL,UNWIND, grouping or a write, a returned edge could be0, a node or edge a raw ID, and a property could come from the entity of the other kind with the same ID (MATCH (a)-[r]->(b) RETURN r ORDER BY r.w).collect()and group keys returned nodes and edges as IDs,nodes(p)andrelationships(p)returned internal ids,UNWINDof them or of a function call afterMATCHreturned no rows, andEXCEPTandINTERSECTover nodes or edges returned the wrong rows. Nodes, edges and lists of them now keep their kind through every clause, also in Gremlinunion(outE(), out()).keys(r)of an edge returned null; it now lists the edge's keys, andkeys()of a node or edge returns them sorted, likeproperties().MATCH (r) MATCH ()-[r]->()); it now fails with an error that names the variable.ORDER BYover values of different types failed or depended on the input order: values of different types compared as equal, numbers among them and around NaN came out of order, lists and maps were not ordered, and such a sort (also inpercentileContandpercentileDisc) could fail withdoes not correctly implement a total order(aPanicExceptionin Python).ORDER BYnow uses the openCypher total order: maps, lists, paths, temporal values, strings, booleans, numbers, then null; integers and floats compare exactly and NaN sorts after infinity.ORDER BYfixes: GQLNULLS FIRSTandNULLS LASTwere reversed withDESC,RETURN * ORDER BY ...failed withVariable '*' not found in input, and sort keys could show up as extra columns (RETURN r AS e ORDER BY e.wreturned ane_wcolumn).MATCH (a)-->(b)-->(a)) returned every two-hop path instead of the cycles, and a pattern through a bound edge (MATCH ()-[r]->() MATCH (x)-[r]->(y)) matched every edge of its shape, also afterWITH, inCALLsubqueries, in stored procedures and after a shortest path. Both now use what the variable holds.*1..1,*1, GQL{1,1}) bound a single edge, sosize(rs)returned null. The variable is now the list of the path's edges.->+finds the shortest cycle, and the path must fit the quantifier.WITHin one statement (#479, #480): aMATCHafter a write missed the written data (and when it found nothing, the write did not run), and a GQLMATCHafterWITHfailed withVariable '...' not found in input. Clauses now read the rows the earlier ones pass on.EXISTSandCOUNTsubqueries gave wrong answers (#543): they checked only a path's first edge (missing multi-hop matches and minimums like*2..), ignored the rest of their pattern (EXISTS { MATCH (a)-[:KNOWS]->(b), (c:Robot) }held without anyRobot), used only their start node from the row (EXISTS { MATCH (b)-[:KNOWS]->(a) }held wheneverbknew anyone), ignored a tie to the row through a value ({id: s.id}, an innerWHERE), could run inWHEREbefore their variables were bound, and counted edges the query could not see. Each row now gets its own answer from the whole pattern, and a null node makesEXISTSfalse andCOUNT0.EXISTS,COUNTandVALUE, eachMATCHclause matched on its own; anEXISTSthat starts withOPTIONAL MATCHfiltered rows;VALUE { ... RETURN count(x) }ignored its argument andDISTINCT; and aVALUEsubquery that is not a count gave every row the same answer, or failed inWHEREandWITH. They now behave as the same clauses do outside a subquery.OPTIONAL MATCHat the start of a query and inEXISTSandCOUNTfailed; it now runs, with one row of nulls when nothing matches.CALLsubqueries saw the wrong outer variables: a GQLCALLdid not see the outer row, so every row got every match; an importingWITH(in GQL, the firstWITHof the body) ignored itsWHEREandWITH a AS bimported the wrong value; and a CypherCALLwithout an importingWITHread outer variables as null. A GQLCALLnow sees every outer variable and itsWITHis an ordinary one, a CypherCALLsees those its importingWITHlists, and the scope clauseCALL (a, b) { ... }(CALL (*),CALL ()), which failed to parse, names them in both languages.CALLsubquery returned were copies of their properties: a laterMATCHfrom them failed or matched everything, andid(b)andtype(r)were null.RETURN *in aCALLalso returned nothing, and a two-edge chain in aCALLno rows. The subquery now passes on the nodes and edges themselves, andRETURN *returns the variables it binds.CALLbodies rejectedORDER BY,SKIP,LIMIT,UNION,DELETE,MERGE,REMOVE,FOREACHand a nestedCALL; they now run, as in openCypher (an orderedLIMITgives the top rows per outer row). A GQLCALLbody takesUNION,EXCEPT,INTERSECTandOTHERWISE.OPTIONAL MATCHcondition that reads a variable bound before it dropped rows: inMATCH (a)-[:KNOWS]->(b) OPTIONAL MATCH (b)-[:KNOWS]->(c) WHERE c.age > a.age, abwhose matches all failed the condition lost its row instead of keeping it with nulls. The condition now decides which matches count, in GQL and Cypher.MERGEbound only the first of several matches: with two(:Tag {k: 1})nodes,MERGE (t:Tag {k: 1}) SET t.seen = trueset one of them. As in openCypher,MERGEnow binds every match, one row each, also for relationships and inupsert_edges.NEXTdid not pass rows on: the statement afterNEXTmatched from every node and returned the first statement's columns too. It now reads the rows the one before returns, and only the lastRETURNis the result.history(id)andchanges_betweenreturned the events of every graph's entity with that id. Each event now names its graph (graph, also in Python and Node.js),historyreads the database's default graph or the session's current graph, andchanges_betweenreturns every graph's events.WITHleft out failed with an internal error (MATCH (a) WITH 1 AS x RETURN a.name); it now fails withUndefined variable 'a'.RETURN size([(a)-->(b) | b])); it now runs..grafeofile, a WAL directory or a compacted database did not see the type of an edge it had created until the commit.reduce()lost items (#538) when the expression called a function, read a property of arelationships(p)item or used another row variable.EXCEPT,INTERSECTandOTHERWISEdid not check their branches' columns (#481), and SQL/PGQ checked none of its set operations; they now fail likeUNION.=~matched any part of the string; it now has to match the whole string, as in openCypher.MATCH ()-[r]->(n:A:B).INSERTwith unlabeled or already bound endpoints failed withUndefined variableor attached edges to the wrong node.LOAD CSVrow returned whole was null instead of the row's map.toString()returned an internal form for temporal values, lists and maps; it now gives ISO 8601 text and literal form.^chains or runs of signs orNOTs could overflow the parser stack.Deriva
Changes for Deriva, which generates ArchiMate models from software repositories and keeps its graph in an embedded Grafeo database through the Python binding.
grafeo.features()andgrafeo.build_info(): the compiled-in languages and capabilities, plus version, git commit and build profile.n.meta.route(also chained) in GQL and Cypher; a missing key gives null.set_graph(), likeexecute().db.graph(name)scopes queries, the direct API and transactions to one graph, usable side by side and across threads.INSERT, and advance the epoch, sochanges_betweenandget_node_at_epochsee them in order.result.countersreports nodes, edges, properties and labels created, set or removed.upsert_nodes(labels, rows, key="id")andupsert_edges(...)create or update many entities by a key property and report created, updated and skipped rows.shuffle_unorderedtest option: returns rows withoutORDER BYin random order, to catch code that relies on an order that is not guaranteed.WHERE:WHERE (d)-[:CONTAINS]->()andWHERE NOT (d)-->().Internal
CI Gatecheck to require before merging, and aPolicyjob for crate boundaries, toolchain pins and public-text rules.PR Policycheck applies the contribution rules in CONTRIBUTING.md.scripts/difftestruns a GQL and Cypher query corpus on the previous release and on a release build of a commit, and fails on any changed result that was not reviewed for the release; it also compares GQL with Cypher within one run.What's Changed
Full Changelog: v0.5.43...v0.5.44
This discussion was created from the release Release 0.5.44.
All reactions