Unicode characters should be valid in IRIs, and this works today except when used as an initial character after the namespace.
This works:
{"@id": "ex:aஃ", ...}
This halts the db:
{"@id": "ex:ஃb", ...}
Pending test that will fail is here (know that you'll have to kill the REPL and restart if you run test, it is completely unresponsive): https://github.com/fluree/db/blob/07128d2047882313b69fa14464472631c305c03b/test/fluree/db/transact/transact_test.clj#L551C1-L583C43
What I've found is that the transaction in the failed test above will make it all the way to fluree.db.flake.transact/final-db here: https://github.com/fluree/db/blob/07128d2047882313b69fa14464472631c305c03b/src/clj/fluree/db/flake/transact.cljc#L94C1-L117C20
However, something is terribly wrong with new-flakes in this fn. You can (count new-flakes), but any attempt to print/log/perform logic on new-flakes creates the stall.
Clearly the flake(s) are bad, and my guess is logging the flakes creates an error condition in our print methods for flakes:
|
#?(:clj (defmethod print-method Flake [^Flake f, ^java.io.Writer w] |
|
(.write w (str "#fluree/Flake ")) |
|
(binding [*out* w] |
|
(pr [(.-s f) (.-p f) (.-o f) (.-dt f) (.-t f) (.-op f) (.-m f)])))) |
|
|
|
#?(:clj (defmethod pprint/simple-dispatch Flake [^Flake f] |
|
(pr f))) |
such that the JVM/REPL is completely blocked.
My thought on next step is to (a) try to update print method so we can at least see the flake issue to fix it, and/or start trying to diagnose the parts in flake creation process before the flake is created to see if the issue can be discovered, which is done here:
|
(defn build-flake |
|
([db-vol t matched-triple] |
|
(build-flake db-vol t nil matched-triple)) |
|
([db-vol t reasoned [s-mch p-mch o-mch]] |
|
(let [m (where/get-meta o-mch) |
|
s-iri (where/get-iri s-mch) |
|
sid (generate-sid! db-vol s-iri) |
|
p-iri (where/get-iri p-mch) |
|
pid (generate-sid! db-vol p-iri)] |
|
(cond-> (if (where/matched-iri? o-mch) |
|
(create-iri-reference-flake db-vol sid pid o-mch t m) |
|
(create-scalar-flake db-vol p-iri sid pid o-mch t m)) |
|
reasoned (with-meta {:reasoned reasoned}))))) |
This relates to issue: #918 and PR that added the test: #923
Unicode characters should be valid in IRIs, and this works today except when used as an initial character after the namespace.
This works:
{"@id": "ex:aஃ", ...}
This halts the db:
{"@id": "ex:ஃb", ...}
Pending test that will fail is here (know that you'll have to kill the REPL and restart if you run test, it is completely unresponsive): https://github.com/fluree/db/blob/07128d2047882313b69fa14464472631c305c03b/test/fluree/db/transact/transact_test.clj#L551C1-L583C43
What I've found is that the transaction in the failed test above will make it all the way to
fluree.db.flake.transact/final-dbhere: https://github.com/fluree/db/blob/07128d2047882313b69fa14464472631c305c03b/src/clj/fluree/db/flake/transact.cljc#L94C1-L117C20However, something is terribly wrong with
new-flakesin this fn. You can(count new-flakes), but any attempt to print/log/perform logic onnew-flakescreates the stall.Clearly the flake(s) are bad, and my guess is logging the flakes creates an error condition in our print methods for flakes:
db/src/clj/fluree/db/flake.cljc
Lines 131 to 137 in 07128d2
My thought on next step is to (a) try to update print method so we can at least see the flake issue to fix it, and/or start trying to diagnose the parts in flake creation process before the flake is created to see if the issue can be discovered, which is done here:
db/src/clj/fluree/db/query/exec/update.cljc
Lines 81 to 93 in 07128d2
This relates to issue: #918 and PR that added the test: #923