Skip to content

refactor: rename github_schema_file_paths table to schema_file_paths #1459

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

devin-ai-integration[bot]
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot commented Apr 23, 2025

What does this PR do?

Renames the github_schema_file_paths table to schema_file_paths to follow the naming convention where github_ prefix is only used for tables that manage GitHub resource IDs.

The job has been tested and confirmed working.

スクリーンショット 2025-04-23 21 28 16 スクリーンショット 2025-04-23 21 28 22 スクリーンショット 2025-04-23 21 28 30

Changes

  • Created a migration file to rename the table
  • Updated all code references to use the new table name

Why?

The github_ prefix should be used only for tables that manage GitHub resource IDs. The github_schema_file_paths table manages schema file paths which are Git resources, not GitHub resources.

Link to Devin run

https://app.devin.ai/sessions/9a42dbe7c6d64fb493ca2b96d47a6643

Requested by

noritaka.ikeda@route06.co.jp

Co-Authored-By: noritaka.ikeda@route06.co.jp <noritaka.ikeda@route06.co.jp>
Copy link

changeset-bot bot commented Apr 23, 2025

⚠️ No Changeset found

Latest commit: a33339a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

vercel bot commented Apr 23, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
liam-app ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 24, 2025 2:23am
liam-erd-sample ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 24, 2025 2:23am
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
liam-docs ⬜️ Ignored (Inspect) Visit Preview Apr 24, 2025 2:23am

Copy link
Contributor Author

🤖 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

Copy link

supabase bot commented Apr 23, 2025

Updates to Preview Branch (devin/1745409215-rename-github-schema-file-paths) ↗︎

Deployments Status Updated
Database Thu, 24 Apr 2025 02:21:22 UTC
Services Thu, 24 Apr 2025 02:21:22 UTC
APIs Thu, 24 Apr 2025 02:21:22 UTC

Tasks are run on every commit but only new migration files are pushed.
Close and reopen this PR if you want to apply changes from existing seed or migration files.

Tasks Status Updated
Configurations Thu, 24 Apr 2025 02:21:26 UTC
Migrations Thu, 24 Apr 2025 02:21:26 UTC
Seeding Thu, 24 Apr 2025 02:21:26 UTC
Edge Functions Thu, 24 Apr 2025 02:21:26 UTC

View logs for this Workflow Run ↗︎.
Learn more about Supabase for Git ↗︎.

Copy link
Contributor

github-actions bot commented Apr 23, 2025

Copy link
Contributor

qodo-merge-pro-for-open-source bot commented Apr 23, 2025

CI Feedback 🧐

(Feedback updated until commit 18b019f)

A test triggered by this PR failed. Here is an AI-generated analysis of the failure:

Action: frontend-ci

Failed stage: Check for diff in generated types and schema.sql [❌]

Failure summary:

The action failed because the generated schema.sql file differs from the committed file.
Specifically, lines 1680-1694 show a diff where 9 empty lines were removed from the schema.sql file.
The error message at line 1694 states: "Generated types and schema.sql differ from committed files."

Relevant error logs:
1:  ##[group]Operating System
2:  Ubuntu
...

157:  ##[group]Run pnpm install --frozen-lockfile --prefer-offline
158:  �[36;1mpnpm install --frozen-lockfile --prefer-offline�[0m
159:  shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
160:  env:
161:  PNPM_HOME: /home/runner/setup-pnpm/node_modules/.bin
162:  ##[endgroup]
163:  Scope: all 17 workspace projects
164:  Lockfile is up to date, resolution step is skipped
165:  Progress: resolved 1, reused 0, downloaded 0, added 0
166:  Packages: +1555
167:  ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
168:  Progress: resolved 1555, reused 662, downloaded 0, added 0
169:  Progress: resolved 1555, reused 1542, downloaded 0, added 275
170:  Progress: resolved 1555, reused 1542, downloaded 0, added 783
171:  Progress: resolved 1555, reused 1542, downloaded 0, added 1555, done
172:  WARN  Failed to create bin at /home/runner/work/liam/liam/frontend/apps/erd-sample/node_modules/.bin/liam. ENOENT: no such file or directory, open '/home/runner/work/liam/liam/frontend/packages/cli/dist-cli/bin/cli.js'
173:  devDependencies:
...

183:  │                                                                              │
184:  │   Ignored build scripts: @biomejs/biome, @bundled-es-modules/glob,           │
185:  │   @depot/cli, @prisma/client, @prisma/engines, @sentry/cli, core-js-pure,    │
186:  │   esbuild, protobufjs, sharp, style-dictionary.                              │
187:  │   Run "pnpm approve-builds" to pick which dependencies should be allowed     │
188:  │   to run scripts.                                                            │
189:  │                                                                              │
190:  ╰──────────────────────────────────────────────────────────────────────────────╯
191:  frontend/apps/docs postinstall$ fumadocs-mdx
192:  frontend/packages/jobs postinstall$ cp ../db-structure/node_modules/@ruby/prism/src/prism.wasm prism.wasm
193:  frontend/packages/jobs postinstall: Done
194:  frontend/apps/docs postinstall: [MDX] types generated
195:  frontend/apps/docs postinstall: Done
196:  frontend/apps/app postinstall$ cp ../../packages/db-structure/node_modules/@ruby/prism/src/prism.wasm prism.wasm
197:  frontend/apps/app postinstall: Done
198:  WARN  Failed to create bin at /home/runner/work/liam/liam/frontend/apps/erd-sample/node_modules/.bin/liam. ENOENT: no such file or directory, open '/home/runner/work/liam/liam/frontend/apps/erd-sample/node_modules/@liam-hq/cli/dist-cli/bin/cli.js'
199:  Done in 6.6s using pnpm v10.8.0
...

946:  cache miss, executing d15951c00f0cc740
947:  > @liam-hq/erd-core@0.1.7 gen /home/runner/work/liam/liam/frontend/packages/erd-core
948:  > concurrently "pnpm:gen:*"
949:  [css] 
950:  [css] > @liam-hq/erd-core@0.1.7 gen:css /home/runner/work/liam/liam/frontend/packages/erd-core
951:  [css] > tcm src
952:  [css] 
953:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/styles/variables.css.d.ts
954:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/styles/globals.css.d.ts
955:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/ERDRenderer.module.css.d.ts
956:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDContent/ERDContent.module.css.d.ts
957:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/Toolbar/DesktopToolbar.module.css.d.ts
958:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/TableDetailDrawer/TableDetailDrawer.module.css.d.ts
959:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/RelationshipEdgeParticleMarker/RelationshipEdgeParticleMarker.module.css.d.ts
960:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/LeftPane/LeftPane.module.css.d.ts
961:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/ErrorDisplay/ParseErrorDisplay.module.css.d.ts
962:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/ErrorDisplay/NetworkErrorDisplay.module.css.d.ts
963:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/ErrorDisplay/ErrorDisplay.module.css.d.ts
964:  [css] Wrote /home/runner/work/liam/liam/frontend/packages/erd-core/src/features/erd/components/ERDRenderer/CardinalityMarkers/CardinalityMarkers.module.css.d.ts
...

1125:  �[22m�[39mNo schema path found for project 100: {"code":"22P02","details":null,"hint":null,"message":"invalid input syntax for type uuid: \"100\""}
1126:  �[90mstderr�[2m | app/api/webhook/github/utils/__tests__/checkSchemaChanges.test.ts�[2m > �[22m�[2mcheckSchemaChanges�[2m > �[22m�[2mshould return false if no files match the schema paths
1127:  �[22m�[39mNo schema path found for project 100: {"code":"22P02","details":null,"hint":null,"message":"invalid input syntax for type uuid: \"100\""}
1128:  �[32m✓�[39m app/api/webhook/github/utils/__tests__/checkSchemaChanges.test.ts �[2m(�[22m�[2m3 tests�[22m�[2m | �[22m�[33m1 skipped�[39m�[2m)�[22m�[32m 181�[2mms�[22m�[39m
1129:  �[2m�[90m↓�[39m�[22m features/projects/pages/ProjectsPage/getProjects.test.ts �[2m(�[22m�[2m1 test�[22m�[2m | �[22m�[33m1 skipped�[39m�[2m)�[22m
1130:  �[2m Test Files �[22m �[1m�[32m3 passed�[39m�[22m�[2m | �[22m�[33m1 skipped�[39m�[90m (4)�[39m
1131:  �[2m      Tests �[22m �[1m�[32m4 passed�[39m�[22m�[2m | �[22m�[33m4 skipped�[39m�[90m (8)�[39m
1132:  �[2m   Start at �[22m 12:23:39
1133:  �[2m   Duration �[22m 2.73s�[2m (transform 413ms, setup 228ms, collect 2.02s, tests 454ms, environment 7ms, prepare 1.47s)�[22m
1134:  ##[endgroup]
1135:  ##[group]@liam-hq/prompt-test:test
1136:  cache miss, executing f932e58e6123a9ed
1137:  > @liam-hq/prompt-test@0.1.0 test /home/runner/work/liam/liam/frontend/packages/prompt-test
1138:  > tsx src/index.ts
1139:  Langfuse secret key was not passed to constructor or not set as 'LANGFUSE_SECRET_KEY' environment variable. No observability data will be sent to Langfuse.
1140:  [Langfuse SDK] 401: Unauthorized. Please check your public/private host settings. Refer to our installation and setup guide: https://langfuse.com/docs/sdk/typescript/guide for details on SDK configuration. Make sure to keep your SDK updated, refer to https://www.npmjs.com/package/langfuse for details. Error details: LangfuseFetchHttpError: HTTP error while fetching Langfuse: 401 and body: {"message":"Invalid authorization header"}
1141:  [Langfuse SDK] 401: Unauthorized. Please check your public/private host settings. Refer to our installation and setup guide: https://langfuse.com/docs/sdk/typescript/guide for details on SDK configuration. Make sure to keep your SDK updated, refer to https://www.npmjs.com/package/langfuse for details. Error details: LangfuseFetchHttpError: HTTP error while fetching Langfuse: 401 and body: {"message":"Invalid authorization header"}
1142:  TypeError: itemsResponse.data is not iterable (cannot read property undefined)
1143:  at Langfuse.getDataset (/home/runner/work/liam/liam/node_modules/.pnpm/langfuse-core@3.37.2/node_modules/langfuse-core/src/index.ts:1432:13)
...

1151:  �[1m�[7m�[36m RUN �[39m�[27m�[22m �[36mv3.1.1 �[39m�[90m/home/runner/work/liam/liam/frontend/packages/db-structure�[39m
1152:  �[32m✓�[39m src/parser/tbls/index.test.ts �[2m(�[22m�[2m20 tests�[22m�[2m)�[22m�[32m 48�[2mms�[22m�[39m
1153:  (node:7743) ExperimentalWarning: WASI is an experimental feature and might change at any time
1154:  (Use `node --trace-warnings ...` to show where the warning was created)
1155:  �[32m✓�[39m src/parser/prisma/index.test.ts �[2m(�[22m�[2m21 tests�[22m�[2m)�[22m�[33m 499�[2mms�[22m�[39m
1156:  �[32m✓�[39m src/parser/schemarb/index.test.ts �[2m(�[22m�[2m18 tests�[22m�[2m)�[22m�[33m 682�[2mms�[22m�[39m
1157:  �[32m✓�[39m src/schema/overrideSchema.test.ts �[2m(�[22m�[2m6 tests�[22m�[2m)�[22m�[32m 24�[2mms�[22m�[39m
1158:  �[32m✓�[39m src/parser/sql/postgresql/processSQLInChunks.test.ts �[2m(�[22m�[2m6 tests�[22m�[2m)�[22m�[32m 38�[2mms�[22m�[39m
1159:  �[32m✓�[39m src/parser/tbls/schema.generated.test.ts �[2m(�[22m�[2m5 tests�[22m�[2m)�[22m�[32m 54�[2mms�[22m�[39m
1160:  �[32m✓�[39m src/parser/schemarb/singularize.test.ts �[2m(�[22m�[2m18 tests�[22m�[2m)�[22m�[32m 10�[2mms�[22m�[39m
1161:  �[32m✓�[39m src/parser/supportedFormat/detectFormat.test.ts �[2m(�[22m�[2m10 tests�[22m�[2m)�[22m�[32m 13�[2mms�[22m�[39m
1162:  (node:8111) ExperimentalWarning: WASI is an experimental feature and might change at any time
1163:  (Use `node --trace-warnings ...` to show where the warning was created)
1164:  �[32m✓�[39m src/parser/index.test.ts �[2m(�[22m�[2m2 tests�[22m�[2m)�[22m�[32m 252�[2mms�[22m�[39m
1165:  �[32m✓�[39m src/parser/sql/postgresql/index.test.ts �[2m(�[22m�[2m19 tests�[22m�[2m | �[22m�[33m1 skipped�[39m�[2m)�[22m�[33m 42268�[2mms�[22m�[39m
1166:  �[33m�[2m✓�[22m�[39m processor�[2m > �[22mLong "create table" statement (exceeds 500 lines, surpassing CHUNK_SIZE)�[2m > �[22mparses without errors �[33m 19818�[2mms�[22m�[39m
1167:  �[33m�[2m✓�[22m�[39m processor�[2m > �[22mLong "create function" statement (exceeds 500 lines, surpassing CHUNK_SIZE)�[2m > �[22mparses without errors �[33m 21693�[2mms�[22m�[39m
1168:  �[2m Test Files �[22m �[1m�[32m10 passed�[39m�[22m�[90m (10)�[39m
...

1199:  [vite]  * [new branch]        add-project-header-design -> origin/add-project-header-design
1200:  [vite]  * [new branch]        add-schema-meta          -> origin/add-schema-meta
1201:  [vite]  * [new branch]        add_script_to_gen_schema -> origin/add_script_to_gen_schema
1202:  [vite]  * [new branch]        add_script_to_gen_schema_json -> origin/add_script_to_gen_schema_json
1203:  [vite]  * [new branch]        add_test_table           -> origin/add_test_table
1204:  [vite]  * [new branch]        avoid-cp-for-windows-actions -> origin/avoid-cp-for-windows-actions
1205:  [vite]  * [new branch]        avoid-semicolon-logic-2  -> origin/avoid-semicolon-logic-2
1206:  [vite]  * [new branch]        avoid-semicolon-logic-test -> origin/avoid-semicolon-logic-test
1207:  [vite]  * [new branch]        before-promptfoo-experiment -> origin/before-promptfoo-experiment
1208:  [vite]  * [new branch]        changeset-invest1        -> origin/changeset-invest1
1209:  [vite]  * [new branch]        changeset-invest3        -> origin/changeset-invest3
1210:  [vite]  * [new branch]        changeset-release/changeset-invest1 -> origin/changeset-release/changeset-invest1
1211:  [vite]  * [new branch]        check-github-action      -> origin/check-github-action
1212:  [vite]  * [new branch]        chore/install-renovate   -> origin/chore/install-renovate
1213:  [vite]  * [new branch]        cli-schema-json-for-local -> origin/cli-schema-json-for-local
1214:  [vite]  * [new branch]        console-error-1-draft    -> origin/console-error-1-draft
1215:  [vite]  * [new branch]        delete-docs-vercel-deploy-erd-yml -> origin/delete-docs-vercel-deploy-erd-yml
1216:  [vite]  * [new branch]        devin/1738820244-add-init-command-tests -> origin/devin/1738820244-add-init-command-tests
1217:  [vite]  * [new branch]        devin/1738828298-add-multiline-comment-support -> origin/devin/1738828298-add-multiline-comment-support
1218:  [vite]  * [new branch]        devin/1739501885-improve-navigation-test-waits -> origin/devin/1739501885-improve-navigation-test-waits
1219:  [vite]  * [new branch]        devin/1740113652-update-changeset-docs -> origin/devin/1740113652-update-changeset-docs
1220:  [vite]  * [new branch]        devin/1741661851-optimize-github-config-validation -> origin/devin/1741661851-optimize-github-config-validation
1221:  [vite]  * [new branch]        devin/1741663537-github-env-validation-at-boot -> origin/devin/1741663537-github-env-validation-at-boot
1222:  [vite]  * [new branch]        devin/1741825670-postgresql-parser-test -> origin/devin/1741825670-postgresql-parser-test
1223:  [vite]  * [new branch]        devin/1743062004-investigate-issue-1005 -> origin/devin/1743062004-investigate-issue-1005
1224:  [vite]  * [new branch]        devin/1744202861-add-organization-ui -> origin/devin/1744202861-add-organization-ui
1225:  [vite]  * [new branch]        devin/1744864520-appbar-refactoring -> origin/devin/1744864520-appbar-refactoring
1226:  [vite]  * [new branch]        devin/1745381489-fix-supabase-auth-security -> origin/devin/1745381489-fix-supabase-auth-security
1227:  [vite]  * [new branch]        devin/1745404272-fix-appbar-hydration-error -> origin/devin/1745404272-fix-appbar-hydration-error
1228:  [vite]  * [new branch]        devin/1745409215-rename-github-schema-file-paths -> origin/devin/1745409215-rename-github-schema-file-paths
1229:  [vite]  * [new branch]        devin/1745409537-add-organization-id-knowledge-suggestions -> origin/devin/1745409537-add-organization-id-knowledge-suggestions
1230:  [vite]  * [new branch]        emu-pr-1033-base         -> origin/emu-pr-1033-base
1231:  [vite]  * [new branch]        emu-pr-1033-feature      -> origin/emu-pr-1033-feature
1232:  [vite]  * [new branch]        emu-pr-1081-base         -> origin/emu-pr-1081-base
1233:  [vite]  * [new branch]        emu-pr-1081-feature      -> origin/emu-pr-1081-feature
1234:  [vite]  * [new branch]        enhance-the-highlighting-of-related-table-nodes-when-hovering-usememo-1 -> origin/enhance-the-highlighting-of-related-table-nodes-when-hovering-usememo-1
1235:  [vite]  * [new branch]        error-message-erd-network-error -> origin/error-message-erd-network-error
1236:  [vite]  * [new branch]        feat-related-posts       -> origin/feat-related-posts
...

1275:  [vite]  * [new branch]        refactor_edge_cardinality_by_using_custom_mark -> origin/refactor_edge_cardinality_by_using_custom_mark
1276:  [vite]  * [new branch]        refactor_hidden_node_handle -> origin/refactor_hidden_node_handle
1277:  [vite]  * [new branch]        release-debug-branch     -> origin/release-debug-branch
1278:  [vite]  * [new branch]        ren-a-table              -> origin/ren-a-table
1279:  [vite]  * [new branch]        renovate-pnpm-10.x-2     -> origin/renovate-pnpm-10.x-2
1280:  [vite]  * [new branch]        renovate/langchain-openai-0.x -> origin/renovate/langchain-openai-0.x
1281:  [vite]  * [new branch]        renovate/major-react-monorepo -> origin/renovate/major-react-monorepo
1282:  [vite]  * [new branch]        renovate/nextjs-monorepo -> origin/renovate/nextjs-monorepo
1283:  [vite]  * [new branch]        renovate/playwright-monorepo -> origin/renovate/playwright-monorepo
1284:  [vite]  * [new branch]        renovate/pnpm-10.x       -> origin/renovate/pnpm-10.x
1285:  [vite]  * [new branch]        renovate/radix-ui-primitives-monorepo -> origin/renovate/radix-ui-primitives-monorepo
1286:  [vite]  * [new branch]        renovate/supabase-2.x    -> origin/renovate/supabase-2.x
1287:  [vite]  * [new branch]        renovate/vite-6.x        -> origin/renovate/vite-6.x
1288:  [vite]  * [new branch]        renovate/vitejs-plugin-react-4.x -> origin/renovate/vitejs-plugin-react-4.x
1289:  [vite]  * [new branch]        renovate/xyflow-react-12.x -> origin/renovate/xyflow-react-12.x
1290:  [vite]  * [new branch]        revert-435-error-message-erd -> origin/revert-435-error-message-erd
1291:  [vite]  * [new branch]        review-suggestion-patch-suggestion-2 -> origin/review-suggestion-patch-suggestion-2
...

1426:  * [new branch]        add-project-header-design -> origin/add-project-header-design
1427:  * [new branch]        add-schema-meta          -> origin/add-schema-meta
1428:  * [new branch]        add_script_to_gen_schema -> origin/add_script_to_gen_schema
1429:  * [new branch]        add_script_to_gen_schema_json -> origin/add_script_to_gen_schema_json
1430:  * [new branch]        add_test_table           -> origin/add_test_table
1431:  * [new branch]        avoid-cp-for-windows-actions -> origin/avoid-cp-for-windows-actions
1432:  * [new branch]        avoid-semicolon-logic-2  -> origin/avoid-semicolon-logic-2
1433:  * [new branch]        avoid-semicolon-logic-test -> origin/avoid-semicolon-logic-test
1434:  * [new branch]        before-promptfoo-experiment -> origin/before-promptfoo-experiment
1435:  * [new branch]        changeset-invest1        -> origin/changeset-invest1
1436:  * [new branch]        changeset-invest3        -> origin/changeset-invest3
1437:  * [new branch]        changeset-release/changeset-invest1 -> origin/changeset-release/changeset-invest1
1438:  * [new branch]        check-github-action      -> origin/check-github-action
1439:  * [new branch]        chore/install-renovate   -> origin/chore/install-renovate
1440:  * [new branch]        cli-schema-json-for-local -> origin/cli-schema-json-for-local
1441:  * [new branch]        console-error-1-draft    -> origin/console-error-1-draft
1442:  * [new branch]        delete-docs-vercel-deploy-erd-yml -> origin/delete-docs-vercel-deploy-erd-yml
1443:  * [new branch]        devin/1738820244-add-init-command-tests -> origin/devin/1738820244-add-init-command-tests
1444:  * [new branch]        devin/1738828298-add-multiline-comment-support -> origin/devin/1738828298-add-multiline-comment-support
1445:  * [new branch]        devin/1739501885-improve-navigation-test-waits -> origin/devin/1739501885-improve-navigation-test-waits
1446:  * [new branch]        devin/1740113652-update-changeset-docs -> origin/devin/1740113652-update-changeset-docs
1447:  * [new branch]        devin/1741661851-optimize-github-config-validation -> origin/devin/1741661851-optimize-github-config-validation
1448:  * [new branch]        devin/1741663537-github-env-validation-at-boot -> origin/devin/1741663537-github-env-validation-at-boot
1449:  * [new branch]        devin/1741825670-postgresql-parser-test -> origin/devin/1741825670-postgresql-parser-test
1450:  * [new branch]        devin/1743062004-investigate-issue-1005 -> origin/devin/1743062004-investigate-issue-1005
1451:  * [new branch]        devin/1744202861-add-organization-ui -> origin/devin/1744202861-add-organization-ui
1452:  * [new branch]        devin/1744864520-appbar-refactoring -> origin/devin/1744864520-appbar-refactoring
1453:  * [new branch]        devin/1745381489-fix-supabase-auth-security -> origin/devin/1745381489-fix-supabase-auth-security
1454:  * [new branch]        devin/1745404272-fix-appbar-hydration-error -> origin/devin/1745404272-fix-appbar-hydration-error
1455:  * [new branch]        devin/1745409215-rename-github-schema-file-paths -> origin/devin/1745409215-rename-github-schema-file-paths
1456:  * [new branch]        devin/1745409537-add-organization-id-knowledge-suggestions -> origin/devin/1745409537-add-organization-id-knowledge-suggestions
1457:  * [new branch]        emu-pr-1033-base         -> origin/emu-pr-1033-base
1458:  * [new branch]        emu-pr-1033-feature      -> origin/emu-pr-1033-feature
1459:  * [new branch]        emu-pr-1081-base         -> origin/emu-pr-1081-base
1460:  * [new branch]        emu-pr-1081-feature      -> origin/emu-pr-1081-feature
1461:  * [new branch]        enhance-the-highlighting-of-related-table-nodes-when-hovering-usememo-1 -> origin/enhance-the-highlighting-of-related-table-nodes-when-hovering-usememo-1
1462:  * [new branch]        error-message-erd-network-error -> origin/error-message-erd-network-error
1463:  * [new branch]        feat-related-posts       -> origin/feat-related-posts
...

1502:  * [new branch]        refactor_edge_cardinality_by_using_custom_mark -> origin/refactor_edge_cardinality_by_using_custom_mark
1503:  * [new branch]        refactor_hidden_node_handle -> origin/refactor_hidden_node_handle
1504:  * [new branch]        release-debug-branch     -> origin/release-debug-branch
1505:  * [new branch]        ren-a-table              -> origin/ren-a-table
1506:  * [new branch]        renovate-pnpm-10.x-2     -> origin/renovate-pnpm-10.x-2
1507:  * [new branch]        renovate/langchain-openai-0.x -> origin/renovate/langchain-openai-0.x
1508:  * [new branch]        renovate/major-react-monorepo -> origin/renovate/major-react-monorepo
1509:  * [new branch]        renovate/nextjs-monorepo -> origin/renovate/nextjs-monorepo
1510:  * [new branch]        renovate/playwright-monorepo -> origin/renovate/playwright-monorepo
1511:  * [new branch]        renovate/pnpm-10.x       -> origin/renovate/pnpm-10.x
1512:  * [new branch]        renovate/radix-ui-primitives-monorepo -> origin/renovate/radix-ui-primitives-monorepo
1513:  * [new branch]        renovate/supabase-2.x    -> origin/renovate/supabase-2.x
1514:  * [new branch]        renovate/vite-6.x        -> origin/renovate/vite-6.x
1515:  * [new branch]        renovate/vitejs-plugin-react-4.x -> origin/renovate/vitejs-plugin-react-4.x
1516:  * [new branch]        renovate/xyflow-react-12.x -> origin/renovate/xyflow-react-12.x
1517:  * [new branch]        revert-435-error-message-erd -> origin/revert-435-error-message-erd
1518:  * [new branch]        review-suggestion-patch-suggestion-2 -> origin/review-suggestion-patch-suggestion-2
...

1613:  * [new tag]           @liam-hq/ui@0.0.15       -> @liam-hq/ui@0.0.15
1614:  * [new tag]           @liam-hq/ui@0.0.16       -> @liam-hq/ui@0.0.16
1615:  �[1m�[7m�[36m RUN �[39m�[27m�[22m �[36mv3.1.1 �[39m�[90m/home/runner/work/liam/liam/frontend/packages/cli�[39m
1616:  �[32m✓�[39m src/cli/erdCommand/getInputContent.test.ts �[2m(�[22m�[2m8 tests�[22m�[2m)�[22m�[32m 110�[2mms�[22m�[39m
1617:  (node:9048) ExperimentalWarning: WASI is an experimental feature and might change at any time
1618:  (Use `node --trace-warnings ...` to show where the warning was created)
1619:  (node:9201) ExperimentalWarning: WASI is an experimental feature and might change at any time
1620:  (Use `node --trace-warnings ...` to show where the warning was created)
1621:  �[32m✓�[39m src/cli/erdCommand/runPreprocess.test.ts �[2m(�[22m�[2m4 tests�[22m�[2m)�[22m�[33m 670�[2mms�[22m�[39m
1622:  �[33m�[2m✓�[22m�[39m runPreprocess�[2m > �[22mshould create schema.json with the content in 'postgres' format �[33m 333�[2mms�[22m�[39m
1623:  �[32m✓�[39m src/cli/index.test.ts �[2m(�[22m�[2m3 tests�[22m�[2m)�[22m�[32m 12�[2mms�[22m�[39m
1624:  (node:9294) ExperimentalWarning: WASI is an experimental feature and might change at any time
1625:  (Use `node --trace-warnings ...` to show where the warning was created)
1626:  �[32m✓�[39m src/cli/erdCommand/index.test.ts �[2m(�[22m�[2m3 tests�[22m�[2m)�[22m�[32m 27�[2mms�[22m�[39m
1627:  �[32m✓�[39m src/cli/smoke.test.ts �[2m(�[22m�[2m2 tests�[22m�[2m)�[22m�[33m 42979�[2mms�[22m�[39m
1628:  �[33m�[2m✓�[22m�[39m CLI Smoke Test�[2m > �[22mshould run the CLI command without errors: `erd` �[33m 5272�[2mms�[22m�[39m
1629:  �[33m�[2m✓�[22m�[39m CLI Smoke Test�[2m > �[22mshould run the CLI command without errors: `erd build` �[33m 4447�[2mms�[22m�[39m
1630:  �[2m Test Files �[22m �[1m�[32m5 passed�[39m�[22m�[90m (5)�[39m
...

1680:  diff --git a/frontend/packages/db/schema/schema.sql b/frontend/packages/db/schema/schema.sql
1681:  index 0a095eee..2afd7d06 100644
1682:  --- a/frontend/packages/db/schema/schema.sql
1683:  +++ b/frontend/packages/db/schema/schema.sql
1684:  @@ -1012,15 +1012,6 @@ GRANT USAGE ON SCHEMA "public" TO "service_role";
1685:  -
1686:  -
1687:  -
1688:  -
1689:  -
1690:  -
1691:  -
1692:  -
1693:  -
1694:  Generated types and schema.sql differ from committed files.
1695:  ##[error]Process completed with exit code 1.
1696:  Post job cleanup.

Copy link

liam-migration-preview bot commented Apr 23, 2025

This PR renames the 'github_schema_file_paths' table to 'schema_file_paths' and updates code references to improve naming consistency. A key concern is the inconsistent constraint and index naming which may lead to overlooked references and hints at potential performance impacts that need to be benchmarked. Overall, wrapping the migration in a transaction and aligning table names with project conventions is a positive step that, once refined, will further improve system integrity.

Migration URL: https://liam-app-git-staging-route-06-core.vercel.app/app/projects/9d777f64-400a-42f3-a60e-98a59fc97279/ref/devin%2F1745409215-rename-github-schema-file-paths/migrations/7183fe32-5442-463b-b69e-3d22e9a7534e

ER Diagram:

Copy link
Contributor

liam-migration bot commented Apr 23, 2025

This PR renames the github_schema_file_paths table to schema_file_paths and updates all related code references while wrapping the migration in a transaction for atomicity. A key issue is the inconsistent constraint naming that still uses the old prefix and the need to verify post-migration data integrity and performance. Overall, the migration improves naming clarity and safety, though updating constraint names and confirming performance and permission alignment are important next steps.

Migration URL: https://liam-erd-web.vercel.app/app/projects/284f1bca-2633-4a93-9567-7bc98ab298f7/ref/devin%2F1745409215-rename-github-schema-file-paths/migrations/384b14ce-03ad-49b9-b744-96fe31a6db55

ER Diagram:

Copy link
Contributor

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 PR contains tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Constraint Naming

The primary key constraint name "github_schema_file_path_pkey" was retained for the renamed schema_file_paths table. Consider renaming this constraint to match the new table name for consistency.

ALTER TABLE ONLY "public"."schema_file_paths"
    ADD CONSTRAINT "github_schema_file_path_pkey" PRIMARY KEY ("id");

Copy link
Contributor

PR Code Suggestions ✨

Explore these optional code suggestions:

CategorySuggestion                                                                                                                                    Impact
General
Update constraint naming pattern

The constraint name "schema_file_path_project_id_fkey" is still using the old
naming pattern. For consistency with the table rename, consider updating the
constraint name to "schema_file_path_project_id_fkey" to match the new table
name pattern.

frontend/packages/db/supabase/migrations/20250423115340_rename_github_schema_file_paths.sql [12-14]

-alter table "public"."schema_file_paths" add constraint "schema_file_path_project_id_fkey"
+alter table "public"."schema_file_paths" add constraint "schema_file_paths_project_id_fkey"
   foreign key ("project_id") references "public"."projects"("id")
   on update cascade on delete restrict;
  • Apply this suggestion
Suggestion importance[1-10]: 7

__

Why: The suggestion correctly identifies an inconsistency in the constraint naming pattern. The constraint name still uses "schema_file_path" (singular) while the table has been renamed to "schema_file_paths" (plural), which could cause confusion in future maintenance.

Medium
Consistent index naming

The index names are still using the singular form "schema_file_path_" while the
table has been renamed to the plural form "schema_file_paths". For consistency,
update the index names to use the plural form.

frontend/packages/db/supabase/migrations/20250423115340_rename_github_schema_file_paths.sql [16-20]

-create unique index if not exists "schema_file_path_path_project_id_key"
+create unique index if not exists "schema_file_paths_path_project_id_key"
   on "public"."schema_file_paths" using btree ("path", "project_id");
 
-create unique index if not exists "schema_file_path_project_id_key"
+create unique index if not exists "schema_file_paths_project_id_key"
   on "public"."schema_file_paths" using btree ("project_id");
  • Apply this suggestion
Suggestion importance[1-10]: 7

__

Why: The suggestion correctly points out that the index names still use the singular form "schema_file_path_" while the table has been renamed to the plural form "schema_file_paths". Maintaining consistent naming conventions improves code readability and maintainability.

Medium
Update primary key constraint name

The primary key constraint name still uses the old
"github_schema_file_path_pkey" naming pattern. For consistency with the table
rename, update the primary key constraint name to match the new table name
pattern.

frontend/packages/db/schema/schema.sql [448-449]

 ALTER TABLE ONLY "public"."schema_file_paths"
-    ADD CONSTRAINT "github_schema_file_path_pkey" PRIMARY KEY ("id");
+    ADD CONSTRAINT "schema_file_paths_pkey" PRIMARY KEY ("id");
  • Apply this suggestion
Suggestion importance[1-10]: 7

__

Why: The suggestion correctly identifies that the primary key constraint name still uses the old "github_schema_file_path_pkey" pattern, which is inconsistent with the renamed table. Updating this would maintain naming consistency throughout the database schema.

Medium
  • More

Copy link
Member

@MH4GF MH4GF left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but please check a comment!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Co-Authored-By: noritaka.ikeda@route06.co.jp <noritaka.ikeda@route06.co.jp>
Copy link
Member

@hoshinotsuyoshi hoshinotsuyoshi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@hoshinotsuyoshi hoshinotsuyoshi added this pull request to the merge queue Apr 24, 2025
Merged via the queue into main with commit 17255ad Apr 24, 2025
19 checks passed
@hoshinotsuyoshi hoshinotsuyoshi deleted the devin/1745409215-rename-github-schema-file-paths branch April 24, 2025 03:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants