Skip to content
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

🐛 Fixed forever loading of related tables section for table without relationships #634

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ya2s
Copy link
Contributor

@ya2s ya2s commented Jan 31, 2025

Summary

The table without the relationShip has a node length of 1.
As a result, tablenodesinitialized was always false
CleanShot 2025-01-31 at 23 50 20@2x

CleanShot 2025-01-31 at 23 50 30@2x

Related Issue

resolve: #347

Changes

Testing

Other Information

@ya2s ya2s requested a review from a team as a code owner January 31, 2025 14:54
@ya2s ya2s requested review from hoshinotsuyoshi, FunamaYukina, junkisai, MH4GF and sasamuku and removed request for a team January 31, 2025 14:54
Copy link

changeset-bot bot commented Jan 31, 2025

🦋 Changeset detected

Latest commit: 352bb52

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@liam-hq/erd-core Patch
@liam-hq/cli Patch

Not sure what this means? Click here to learn what changesets are.

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

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.

The CLI version seems to show nothing. Please check.

Screenshot 2025-02-03 at 17 29 05

https://liam-erd-sample-69b1fd3hf-route-06-core.vercel.app/

"@liam-hq/cli": patch
---

🐛 Check node length
Copy link
Member

Choose a reason for hiding this comment

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

This will be a release note, so please describe what can now be done.

Copy link
Contributor

CI Feedback 🧐

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

Action: run-e2e / e2e-test

Failed stage: Run e2e tests [❌]

Failed test name: tests/vrt/vrt.test.ts › top

Failure summary:

The action failed due to a Visual Regression Test (VRT) failure in the Playwright test suite:

  • The test 'top' in file 'tests/vrt/vrt.test.ts' failed because the screenshot comparison did not
    match the expected baseline
  • The test was retried 2 times but continued to fail
  • The failure indicates visual differences between the current and expected UI state
  • Additional warning was observed about failing to create binary at
    frontend/apps/erd-sample/node_modules/.bin/liam due to missing file

  • Relevant error logs:
    1:  ##[group]Operating System
    2:  Ubuntu
    ...
    
    191:  Scope: all 11 workspace projects
    192:  Lockfile is up to date, resolution step is skipped
    193:  Progress: resolved 1, reused 0, downloaded 0, added 0
    194:  Packages: +1440
    195:  ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    196:  Progress: resolved 1440, reused 1285, downloaded 0, added 0
    197:  Progress: resolved 1440, reused 1420, downloaded 0, added 600
    198:  Progress: resolved 1440, reused 1420, downloaded 0, added 1440, done
    199:  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'
    ...
    
    204:  + @turbo/gen 2.1.2
    205:  + syncpack 13.0.0
    206:  + turbo 2.1.2
    207:  frontend/apps/docs postinstall$ fumadocs-mdx
    208:  frontend/apps/docs postinstall: [MDX] types generated
    209:  frontend/apps/docs postinstall: Done
    210:  frontend/apps/erd-web postinstall$ cp ../../packages/db-structure/node_modules/@ruby/prism/src/prism.wasm prism.wasm
    211:  frontend/apps/erd-web postinstall: Done
    212:  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'
    ...
    
    1457:  PNPM_HOME: /home/runner/setup-pnpm/node_modules/.bin
    1458:  URL: https://liam-erd-58uptwnmh-route-06-core.vercel.app
    1459:  ##[endgroup]
    1460:  > @liam-hq/[email protected] test:e2e /home/runner/work/liam/liam/frontend/packages/e2e
    1461:  > playwright test
    1462:  Running 3 tests using 1 worker
    1463:  ··××F
    1464:  1) [chromium] › tests/vrt/vrt.test.ts:26:5 › top ─────────────────────────────────────────────────
    1465:  Error: �[2mexpect(�[22m�[31mpage�[39m�[2m).�[22mtoHaveScreenshot�[2m(�[22m�[32mexpected�[39m�[2m)�[22m
    ...
    
    1502:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1503:  attachment #2: top-1-actual.png (image/png) ────────────────────────────────────────────────────
    1504:  test-results/vrt-vrt-top-chromium/top-1-actual.png
    1505:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1506:  attachment #3: top-1-diff.png (image/png) ──────────────────────────────────────────────────────
    1507:  test-results/vrt-vrt-top-chromium/top-1-diff.png
    1508:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1509:  Retry #1 ───────────────────────────────────────────────────────────────────────────────────────
    1510:  Error: �[2mexpect(�[22m�[31mpage�[39m�[2m).�[22mtoHaveScreenshot�[2m(�[22m�[32mexpected�[39m�[2m)�[22m
    ...
    
    1546:  test-results/vrt-vrt-top-chromium-retry1/top-1-diff.png
    1547:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1548:  attachment #4: trace (application/zip) ─────────────────────────────────────────────────────────
    1549:  test-results/vrt-vrt-top-chromium-retry1/trace.zip
    1550:  Usage:
    1551:  pnpm exec playwright show-trace test-results/vrt-vrt-top-chromium-retry1/trace.zip
    1552:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1553:  Retry #2 ───────────────────────────────────────────────────────────────────────────────────────
    1554:  Error: �[2mexpect(�[22m�[31mpage�[39m�[2m).�[22mtoHaveScreenshot�[2m(�[22m�[32mexpected�[39m�[2m)�[22m
    ...
    
    1590:  tests/vrt/vrt.test.ts-snapshots/top-1-chromium-linux.png
    1591:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1592:  attachment #2: top-1-actual.png (image/png) ────────────────────────────────────────────────────
    1593:  test-results/vrt-vrt-top-chromium-retry2/top-1-actual.png
    1594:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1595:  attachment #3: top-1-diff.png (image/png) ──────────────────────────────────────────────────────
    1596:  test-results/vrt-vrt-top-chromium-retry2/top-1-diff.png
    1597:  ────────────────────────────────────────────────────────────────────────────────────────────────
    1598:  1 failed
    1599:  [chromium] › tests/vrt/vrt.test.ts:26:5 › top ──────────────────────────────────────────────────
    1600:  2 passed (21.4s)
    1601:  ELIFECYCLE  Command failed with exit code 1.
    1602:  ##[error]Process completed with exit code 1.
    

    @ya2s
    Copy link
    Contributor Author

    ya2s commented Feb 9, 2025

    @MH4GF I've corrected it

    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.

    Related tables section for table without relationships are forever loading.
    2 participants