sync all 28 modules to constructive-db's source, lockstep 0.39.0 - #115
Merged
Conversation
….39.0
constructive-db carries the newer source for all 28 shared modules; this mirrors
it back into the published copies, then reconciles versions so the two trees
agree.
Direction per package is constructive-db -> here for every deploy/revert/verify
source and plan, with three exceptions where this tree was ahead and is kept:
pgpm-defaults' jest suite (moved here deliberately in constructive-db@a80a95bc093
because its workflows never run pgpm-modules/** suites), the app-scope and
function-resolution READMEs (no vendored counterpart), and the
metaschema-modules snapshot, which is refreshed here for the two new module
tables rather than taken from the stale vendored copy.
Headline source changes carried over:
- pgpm-verify: the verify_* wrappers are replaced by catalog assertions with
typed identities (assert_table/_view/_index/_trigger/_policy/_schema/_type/
_domain/_function plus the grant and security assertions), and every module's
verify/ scripts are rewritten onto them. verify_domain('public.upload')
becomes assert_domain('public.upload'::regtype, 'jsonb'::regtype,
_constraints => 1). Cross-module plan requires that pointed at
pgpm-verify:@0.1.0 now name pgpm-verify:procedures/assert_function.
- revert/ across every module drops each created object by its exact identity.
- app-scope: projected_parent, and frames resolves the tenant's own database
frame before the platform fall-through.
- function-resolution: resolution answers from the published catalog plane in
one static read (catalog_location is gone), plus the capability-resolution
surface (frame_candidates, resolve_bucket/_api/_capabilities/_payload_refs,
bucket/api catalog rows, bound_bucket_id, validate_capabilities).
- metaschema-modules: scope_types_module and user_settings_security_module.
- object-store: node_hash_uuid + set-based insert_nodes_at_paths.
- object-tree: set_many_and_commit.
- partman: after_delete_partition unparents metaschema partition rows.
Version rule: lerna fixed-mode lockstep, one minor bump above the highest
version present in either tree (the vendored pgpm-verify was at 0.38.0, ahead of
this tree's 0.36.0 line), so every module - including errors, which the vendored
copy still had at 0.0.1 - becomes 0.39.0. sync-versions propagated it to each
.control default_version and Makefile DATA, and every sql/ artifact was
regenerated from deploy/ with pgpm package; the bundles are byte-identical to
the ones regenerated in constructive-db from the same sources.
Test infrastructure, needed for the synced suites to run at all:
- pgsql-test ^5.4.1 -> ^5.10.6: 5.4.1 resolves @pgpmjs/core 7.9.0, which ignores
extensions.json's schema/createSchema, so pg_partman landed without its
partman schema and the new partman suite could not deploy.
- inflection-db's jest config pointed ts-jest at a tsconfig.json no package has,
and its @ts-expect-error for jest-in-case is unused now that the types are
installed; that suite has never run in either tree and now passes (29 tests).
- pnpm-workspace.yaml regenerated by pnpm-policy for the new first-party
transitive (git-changed).
All 28 packages' suites pass locally (errors, ltree-helpers and uuid have none).
Contributor
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
…e deployed functions The message argument is defaulted, so regprocedure lookup and DROP FUNCTION must spell the full argument list.
This was referenced Aug 8, 2026
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.
Summary
constructive-db/pgpm-modules/*andpackages/*here are the same 28 modules and had drifted: constructive-db carried the newer source, this tree carried the higher version numbers. This mirrors constructive-db's source back into the published packages and puts both trees on one version.The drift is not incidental — the vendored copy replaced the whole verification vocabulary. Every
verify/script here still calls the string-addressed wrappers; constructive-db asserts against catalog identities:That is only expressible with the
pgpm-verifyin constructive-db (0.38.0, ahead of this tree's 0.36.0 line), sopgpm-verify's 19verify_*/list_*/get_*_from_strprocedures are replaced by 16assert_*procedures, and all 27 other modules'verify/trees are rewritten onto them. Cross-modulepgpm.planrequires that pinnedpgpm-verify:@0.1.0now name a change,pgpm-verify:procedures/assert_function.Deploy-source changes carried over, beyond the verify rewrite:
function-resolution— resolution now answers from the published catalog plane in one static read (catalog_locationis dropped), plus a whole capability-resolution surface:frame_candidates,resolve_bucket,resolve_api,resolve_payload_refs,resolve_capabilities,bucket_catalog_row,api_catalog_row,bound_bucket_id,validate_capabilities.app-scope— newprojected_parent;framesyields the tenant's owndatabaseframe before falling through to the platform database.metaschema-modules—scope_types_moduleanduser_settings_security_moduletables.object-store—node_hash_uuidand a set-basedinsert_nodes_at_paths.object-tree—set_many_and_commit.partman—after_delete_partitiontrigger that unparents metaschema partition rows.totp— NUL-safe base32 decode path.revert/across every module drops objects by exact identity instead of by name.Version rule
Lerna fixed-mode lockstep, one minor bump above the highest version present in either tree. The vendored
pgpm-verifywas at 0.38.0 — ahead of this tree — so 0.37.0/0.38.0 were unavailable and everything goes to 0.39.0, includingerrors, which the vendored copy still had at 0.0.1.pgpm sync-versionspropagated it into each.controldefault_versionandMakefileDATA, and regeneratedsql/<name>--0.39.0.sql+.bundle.tar.gzfromdeploy/. Nothing generated was hand-edited; the bundles are byte-identical to the ones regenerated in constructive-db from the same sources (constructive-io/constructive-db#2858), which is the check that the two trees really are in sync.Where this tree was ahead, and kept
defaults/__tests__constructive-db@a80a95bc093— constructive-db's workflows never runpgpm-modules/**suites. Its snapshot is also the correct one (default_func_acl_count: 1after the PUBLIC-execute revoke); the vendored snapshot still said 2 and is fixed downstream.metaschema-modulessnapshotpages_module; refreshed here for the two new module tables instead.app-scope,function-resolutionREADMEsTest infrastructure
Two changes were needed for the synced suites to run at all:
pgsql-test^5.4.1→^5.10.6. 5.4.1 resolves@pgpmjs/core@7.9.0, which ignoresextensions.json'sschema/createSchema(as AGENTS.md notes for the pgpm 4 CLI), sopg_partmaninstalled without itspartmanschema and the new partman suite died inbeforeAllwithschema "partman" does not exist.inflection-db's jest config pointed ts-jest at atsconfig.jsonthat no package in the workspace has, and its@ts-expect-errorforjest-in-caseis unused now that the types resolve. That suite has never run in either tree; it now passes with 29 tests.pnpm-workspace.yamlregenerated bypnpm-policyfor the new first-party transitive (git-changed).Per-package inventory
Counts are source files only (
sql/excluded). "tests: N changed" is theconstructive-test→pgsql-testimport swap unless the package is listed above; that import is the one legitimately tree-specific difference left between the trees.achievementsapp-scopebase32database-jobsdefaultsencrypted-secretsencrypted-secrets-tableerrorsfakerfunction-resolutiongeotypesinflectioninflection-dbjobsjwt-claimsltree-helpersmeasurementsmetaschema-modulesmetaschema-schemaobject-storeobject-treepartmanstampstotptypesutilsuuidverifyNo genuine semantic conflicts were found: every difference was one side being stale, and each is attributed above.
Verification
All 28 packages' suites pass locally against
postgres-plus:18(errors,ltree-helpersanduuidhave none): 449 tests.npx eslint .andpnpm policy:checkclean.Follow-up:
bucket_idon theupload/imagedomains (constructive-planning#1476/#1477) is a separate PR on top of this one.Link to Devin session: https://app.devin.ai/sessions/43b0b10711174fa49d51907bf2b0c25f
Requested by: @pyramation