Skip to content

fix(pgpm/cli): use database name instead of UUID for default extension name#491

Merged
pyramation merged 1 commit intomainfrom
devin/1766720308-improve-export-extension-name
Dec 26, 2025
Merged

fix(pgpm/cli): use database name instead of UUID for default extension name#491
pyramation merged 1 commit intomainfrom
devin/1766720308-improve-export-extension-name

Conversation

@pyramation
Copy link
Copy Markdown
Contributor

Summary

Changes the default value for extensionName in the pgpm export command from a UUID to the human-readable database name.

Previously, the default was dbInfo.database_ids[0] which is a UUID like 7c944bc6-511a-44ad-a407-ce2cefd5e466. Now it uses the selected database name from collections_public.database, falling back to the PostgreSQL database name (dbname) if unavailable.

Review & Testing Checklist for Human

  • Run pgpm export end-to-end - Verify the extension name prompt now shows a readable database name as the default instead of a UUID
  • Verify the fallback works - If selectedDatabaseNames[0] is somehow undefined, confirm it falls back to dbname correctly

Test Plan

  1. Run pgpm export against a database with entries in collections_public.database
  2. When prompted for "Extension name", verify the default value shown is the database name (not a UUID)
  3. Accept the default and confirm the export completes successfully

Notes

Link to Devin run: https://app.devin.ai/sessions/7530c5fa0b95477e9758c657dff7e299
Requested by: Dan Lynch (@pyramation)

…n name

Previously, the export command defaulted the extensionName to the database UUID
(dbInfo.database_ids[0]), which resulted in confusing names like
'7c944bc6-511a-44ad-a407-ce2cefd5e466'.

Now it uses the selected database name from collections_public.database, falling
back to the PostgreSQL database name (dbname) if no name is available.
@devin-ai-integration
Copy link
Copy Markdown
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@pyramation pyramation merged commit 171d829 into main Dec 26, 2025
34 checks passed
@pyramation pyramation deleted the devin/1766720308-improve-export-extension-name branch December 26, 2025 03:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant