Skip to content

Shouldn't roots be disposed when their scope function throws? #2487

@AFatNiBBa

Description

@AFatNiBBa

Describe the bug

When something throws (Directly) inside of a function passed to createRoot(), the root that was being created doesn't get disposed.
Is this expected?

Your Example Website or App

https://playground.solidjs.com/anonymous/1e6d765f-717a-4fef-a981-573593533dcc

Steps to Reproduce the Bug or Issue

  1. Go to the playground link
  2. Check the console

Expected behavior

The root should be disposed and "Disposing" should be logged

Screenshots or Videos

No response

Platform

(Irrelevant)

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions