Repository navigation
Read compiled Cypher's rows and a node's held properties on Oracle as text, so a node updated in place is read on Oracle 23.26.4 - #616
Merged
Conversation
…lace is read on Oracle 23.26.4 (#609) python-oracledb's thin mode can't read OSON version 2 (DPY-3021), which Oracle 23.26.4 can send for a document updated in place even encoded again. Ask the shared compiler for text (oracleReadsAsText, oracleRowsAsText), as Drivine for TypeScript does, and read each row from Oracle's extended JSON.
…e() of a node updated in place work on Oracle 23.26.4 (#609)
…he compiled-row readers without a database (#609)
…em, and fix the in-place test's spec and flat-bag expectation (#609)
# Conflicts: # tests/golden/VERSION
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #609.
On Oracle 23.26.4 a node updated in place could not be read back: python-oracledb's thin mode can't read OSON version 2 (
DPY-3021, oracle/python-oracledb#622, open, in every release to 26.2.0), and Oracle 23.26.4 sends it for a document updated in place even after re-encoding it withJSON_TRANSFORM(…, KEEP '$'). A compiled Cypher read that returned such a node failed, and so did a write that returned one, after the write was kept.Fix
oracleReadsAsTextandoracleRowsAsText, as Drivine for TypeScript asks: a read's rows come back a CLOB each, a write's all in one row as a list. The host reads each from Oracle's extended JSON (OracleResultMapper.map_compiled_rows): floats as marked ({"$numberDouble": 2.5}, NaN, the infinities), whole numbers in full, the store layout through the module, forqueryand a cursor, async and sync. The driver never decodes a document.NullPolicy.CLEAR, andupdate(), of a model with a property bag or open labels first reads what the node holds; that read is nowJSON_SERIALIZE(n.props RETURNING CLOB EXTENDED) AS "props:json". The statement is a golden one, changed with Drivine for TypeScript in Read the held properties on Oracle as text, the statement drivine-python writes too drivine#923;tests/goldenis copied from its merge commit.The Oracle image the suite pins (23.26.3) stays pinned here; unpinning is its own change.
Measured
tests/integration/oracle/test_oracle_updated_in_place.py(and its sync twin): nodes updated in place eleven ways, then each read, node-returning write,MERGE, cursor,CLEARsave andupdate()from the issue's table.DPY-3021(reads, writes,MERGE)The
CLEARsave andupdate()cases didn't fail on main in this run, where the issue's measurement had 14 of 48 failing; their read is made text all the same.Checks
queryand a cursor (async and sync), of a compiled write's one row of text, of_graphasking for text on Oracle only, and of a:jsoncolumn read from extended JSON.tests/integrationwithORACLE_TESTS=true, through the lock, at 01be97f (on main with compiler 0.56.0): 4,975 passed, 0 failed, 289 skipped, 6 xfailed. The new test on Oracle 23.26.4: 16 of 16. An earlier run before the merge failed 15, all fixed: two Oracle timing suites read a compiled statement's rows straight from the driver and now read them as the library does, and the new test's own two mistakes.Review: 3 passes, last CLEAN.
queryand a cursor, of_graph, and of the:jsonpath.