Skip to content

docs(#314): the float text of to_json() and the last digits of vector distances differ between the packages - #469

Merged
tae898 merged 1 commit into
mainfrom
docs/314-float-text-and-distances
Nov 24, 2026
Merged

tae898 merged 1 commit into
mainfrom
docs/314-float-text-and-distances

Conversation

@tae898

@tae898 tae898 commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator

What does this PR do?

It writes down the two differences of #314 that the status comment of 2026-11-22 left as documentation points. On the Results page: Result.to_json() writes a FLOAT or a float32 array as the shortest float32 text on arcadedb-jvm (0.1) and as the exact float64 it widens to on arcadedb (0.10000000149011612), both read back as the same float32, and to_json_list() has no such difference. On the Vectors page: a distance is a float32 value, so where it does not round exactly the two packages can differ in the sixth significant digit, and two calls of one search on arcadedb-jvm can differ in the last bits.

The values come from the probe of #446 and the docstring of tests/test_cross_wheel_golden.py, which gives each build's value; I did not measure them again for this PR. I only wrote the two paragraphs.

Related issues

Closes #314. The other items of its status comment have their own issues: the integral DECIMAL is done (#452, in #456), the DATE and DATETIME of a projection row is #453, and the non-ASCII text of to_json() is #454.

Docs

docs/modules/ROOT/pages/how-to/databases-and-queries.adoc and docs/modules/ROOT/pages/how-to/vectors.adoc. npx -p @antora/[email protected] -p @antora/[email protected] antora docs/antora-playbook.yml builds with no warning, and the rendered Vectors page has the sentence.

Checklist

  • A regression test fails on the old code and passes on the new: not applicable, a docs-only change
  • The test suite that the change can affect passes: not applicable, no code changed
  • uvx pre-commit run --files <changed files> passes

… distances differ between the packages

Items 2 and 4 of the status comment on #314 stay open as documentation points: the values are equal (a FLOAT or float32 array reads back as the same float32 from either text), the text is not, and a vector distance that does not round exactly in float32 differs in the sixth digit between the packages. The figures are the ones the golden test (tests/test_cross_wheel_golden.py) records for each build. The Antora build of docs/ passes with no warning.
@tae898 tae898 added this to the 26.12.1 milestone Nov 24, 2026
@tae898 tae898 added documentation Improvements or additions to documentation jvm The arcadedb-jvm package (JPype build) native The arcadedb package (native library build) python Pull requests that update python code labels Nov 24, 2026
@tae898 tae898 self-assigned this Nov 24, 2026
@tae898
tae898 merged commit 577feb0 into main Nov 24, 2026
6 checks passed
@tae898
tae898 deleted the docs/314-float-text-and-distances branch November 24, 2026 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation jvm The arcadedb-jvm package (JPype build) native The arcadedb package (native library build) python Pull requests that update python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Parity: the two wheels return different Python floats from to_json_list, and no cross-wheel golden test exists

1 participant