You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bulk import's TriG reader rejects [ … ], ( … ) and bare { … } blocks that insert accepts #1930
Bulk import refuses valid TriG that a TriG insert or /upsert of the same document accepts. Inside a GRAPH block it rejects an anonymous blank node [ … ] and a collection ( … ), and it rejects a bare { … } block. For example, importing
fails with Parse error: expected object, found '['. The same triples load as plain Turtle, and since #2008 the transaction write paths (TriG insert, /upsert, graph sync, graph insert) load them inside a block too, so this issue is now about bulk import alone.
This matters for loading tool specs and ontologies exported by other RDF tools, which routinely use [ … ] and ( … ) inside graph blocks.
Cause
Bulk import still reads TriG with its own block parser, parse_trig_phase1 in fluree-db-transact/src/parse/trig_meta.rs. It has no arm for [ or (, and no bare-block case. The transaction write paths moved off it in #2008, onto the locator and segment parser in fluree-db-transact/src/parse/rdf_text/, which hands each block's tokens to the full Turtle parser.
Fix
Move bulk import onto the same rdf_text locator and segment parser, so a file imported and the same file inserted are read identically. That reader already handles what a ledger write needs: the <#txn-meta> block, graph names kept as written, and blank-node labels scoped to the whole document.
We chose it over the document reader Dialect::TriG (behind rdf::parse and fluree.parse, #2042) because import's job is to store what an insert of the file would store. The two readers share the Turtle parser and differ only in how they find blocks and what they refuse.
parse_trig_phase1 is also used by testsuite-sparql's result reader, so it may stay for that.
changed the title [-]TriG GRAPH blocks reject anonymous blank nodes [ … ] on /upsert and import[/-][+]Bulk import's TriG reader rejects [ … ], ( … ) and bare { … } blocks that insert accepts[/+]on Oct 13, 2026
Activity
docs: TriG on insert
[-]TriG GRAPH blocks reject anonymous blank nodes [ … ] on /upsert and import[/-][+]Bulk import's TriG reader rejects [ … ], ( … ) and bare { … } blocks that insert accepts[/+]docs(transactions): RDF text is read once, the same way on every lane