feat(core): export all tables from metaschema_public, services_public, and metaschema_modules_public #579
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
Expands the
export-meta.tsconfig to export ALL tables from three schemas when exporting constructive-services metadata via the introspection package. Previously, only a subset of tables were exported.Added tables:
New field types added:
uuid[],int,interval,timestamptzUpdates since last revision
queryAndParseto gracefully skip tables that don't exist (catches PostgreSQL error code42P01= undefined_table). This allows the export to work with databases that don't have all metaschema tables deployed.Review & Testing Checklist for Human
pgpm-modules/, but there may be mismatches or missing columnscsv-to-pgParser supports the new field types (uuid[],int,interval,timestamptz) - if not, runtime errors will occurextensiontable query should filter by database_id - currently queries all extensions without WHERE clause (line 842)generate:rlsin the introspection package against a real database and verify the generatedmeta.sqlcontains INSERT statements for all new tablesNotes
pnpm buildpassed successfullymetaschema_public.policytable; fixed by adding error handling to skip missing tablespgpm-modules/metaschema-modules/andpgpm-modules/metaschema-schema/Link to Devin run: https://app.devin.ai/sessions/5c1c71a0c3284e0883313ac30f889c9d
Requested by: Dan Lynch (@pyramation)