Skip to content
New issue

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

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

Already on GitHub? # to your account

Error when referencing the same node as target #234

Open
jsjohann opened this issue Apr 25, 2024 · 0 comments
Open

Error when referencing the same node as target #234

jsjohann opened this issue Apr 25, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@jsjohann
Copy link

jsjohann commented Apr 25, 2024

Describe the bug

When referencing the same node as well as source and target in an edge, the edge isn't rendered and I get following error message in console:

THREE.BufferGeometry.computeBoundingSphere(): Computed radius is NaN. The "position" attribute is likely to have NaN values.

Steps to Reproduce the Bug or Issue

    const nodes = [
        {
            id: '1',
            label: 'Node 1',
        },
    ];

    const edges = [
        {
            id: '1',
            source: '1',
            target: '1',
            label: 'Edge 1',
        },
    ];

    return (
        <GraphCanvas edges={edges} nodes={nodes} />
    )

Expected behavior

Ideally, there would be a support for self-referencing nodes/edges where the arrow basically targets the same node (see quick mockup).

Screenshots or Videos

image

Platform

  • Reagraph Version: 4.17
  • OS: macOS
  • Browser: Chrome
@amcdnl amcdnl added the bug Something isn't working label Apr 25, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants