Refresh meos-idl.json to MEOS-API canonical; regenerate bindings#2
Refresh meos-idl.json to MEOS-API canonical; regenerate bindings#2estebanzimanyi wants to merge 1 commit into
Conversation
|
Thank you for the refresh. I ran a final reproducibility check after MobilityDB/MEOS-API#15 landed, and the committed IDL doesn't match what regenerates from the current canonical state. Could you regenerate against master once more before we merge? Pulled MEOS-API master (now with #15 merged), ran
3 causes:1. Older
|
| Function (slot) | This PR's IDL | Fresh from master |
|---|---|---|
edwithin_tcbuffer_geo (gs param) |
const int * |
const GSERIALIZED * |
geom_perimeter (gs param) |
const int * |
const GSERIALIZED * |
temporal_start_value (return) |
int |
Datum |
tsequence_max_val (return) |
int |
Datum |
overbefore_set_date (d param) |
int |
DateADT |
512 functions are affected: every GSERIALIZED * / Datum / DateADT / GBOX * / BOX3D * slot in scope is still spelled int/int * here.
2. MobilityDB headers were not master
The IDL contains 160 functions that don't exist in MobilityDB master:
- 60
tbigint_* - 63
th3index_* - 121
tcbuffer_*(vs ~70 on master) - 54
tpose_*
These look like a feature branch with the extended type families. Could you confirm which MobilityDB commit/branch was used? If it's a not-yet-merged feature branch, the binding generator's source of truth would point at code that doesn't exist upstream, I'd prefer the canonical MEOS.js to track a state of MobilityDB that's already public.
3. Two functions present on master but missing here
mindistance_tgeo_tgeo and tgeoarr_tgeoarr_mindist — confirms the headers snapshot used was slightly behind current master.
What I'm asking for
- Rebase on current
main(now with Initial commit #1 merged) and regeneratecodegen/res/meos-idl.jsonviapython run.pyagainst:- MEOS-API at current master (after the #15 merge)
- MobilityDB headers at a stable state: either master, or a specific feature branch you can document in the PR body
- Re-run
npm run generateagainst the new IDL, commit the updatedbindings.c+functions.generated.ts - Force-push the amended
23722ba
The reproducibility check I ran is:
# in a fresh MEOS-API checkout, master at or after the #15 merge
python setup.py # or --branch <feature> if you used a branch
python run.py
diff <(jq -S . output/meos-idl.json) \
<(jq -S . path/to/MEOS.js/codegen/res/meos-idl.json)Once that diff is empty, I'll re-verify and approve.
Regenerate codegen/res/meos-idl.json from MEOS-API master (including #15's typerecover fix) against MobilityDB master (2c4243a). This recovers the PG-vendored C types the libclang parse had collapsed to int — GSERIALIZED, Datum, DateADT, GBOX, BOX3D, AFFINE — fixing ~512 signature drifts, and picks up mindistance_tgeo_tgeo / tgeoarr_tgeoarr_mindist. The IDL now tracks the public MobilityDB surface (2672 functions); the not-yet-merged extended-type families are dropped until they land on master. Skip internal Datum-typed functions in the generator. A Datum is an opaque tagged uintptr_t (a pointer for Float8/text/geometry base types, only 32-bit under WASM32) that cannot be marshalled to a JS scalar. Such functions are internal (meos_internal.h); the user-facing API is the typed *_meos.c wrappers (e.g. temporal_start_value -> tint/tfloat/ttext_start_value). 171 Datum-signature functions are now excluded from the generated surface so Datum never reaches the user API. Track MobilityDB's mult -> mul multiplication rename in the TFloat/TInt/TNumber wrappers, and bump the Dockerfile MOBILITYDB_COMMIT pin to 2c4243a so the WASM build stays consistent with the regenerated bindings. npm run generate -> Generated: 2465 Skipped: 172 Manual: 35 npx tsc --noEmit -> clean reproducibility: diff of a fresh run.py output vs the committed IDL is empty
23722ba to
bbf7831
Compare
|
Done — rebased onto Point by point:
One thing your I also bumped the
|
Refreshes
codegen/res/meos-idl.jsonto the MEOS-API canonical IDL and regenerates both outputs, now tracking the public MobilityDB surface.Source of truth (reproducible)
2c4243aThe committed IDL is exactly what
python setup.py && python run.pyproduces against those two states:What changed vs the previous IDL
typerecover.pyrecoversGSERIALIZED/Datum/DateADT/GBOX/BOX3D/AFFINEslots that the earlier parse had collapsed toint/int *.mindistance_tgeo_tgeoandtgeoarr_tgeoarr_mindistare present.Datum stays out of the user API
The recovered types exposed that 171 functions carry a
Datumin their signature — all internal (meos_internal.h). ADatumis an opaque taggeduintptr_t(a pointer forFloat8/text/ geometry base types, 32-bit under WASM32) and cannot be marshalled to a JS scalar. The generator now skips everyDatum-signature function (isDatumadded toshouldSkip); the user-facing path is the typed*_meos.cwrappers, e.g.temporal_start_value→tint_start_value/tfloat_start_value/ttext_start_value. NoDatumappears in anyfunctions.generated.tssignature.Wrapper + build sync
core/types/basic/{TFloat,TInt,TNumber}.ts: track MobilityDB'smult_*→mul_*multiplication rename (the onlycore/typeschange — the symbols were renamed upstream).Dockerfile: bumpMOBILITYDB_COMMITto2c4243aso the WASM build matches the regeneratedbindings.c.Verify