Skip to content

Conversation

@DogeDark
Copy link
Contributor

@DogeDark DogeDark commented Mar 15, 2025

The eval channel was being garbage collected even though the user's code should still have a hard reference to it.

I spent a while trying to solve the root issue of why the channel is getting GC'ed (maybe some weird async JS GC trickery?), and decided it'd be quicker to implement a system where the channel is only dropped when we manually dioxus.close(); it. The close method is already called internally and won't need to be called by the user.

Fixes #2979

@DogeDark DogeDark added bug Something isn't working javascript Pull requests that update Javascript code labels Mar 15, 2025
@DogeDark DogeDark requested a review from a team as a code owner March 15, 2025 04:36
@jkelleyrtp jkelleyrtp merged commit 9ffa423 into DioxusLabs:main Apr 15, 2025
16 of 17 checks passed
@DogeDark DogeDark deleted the fix-eval branch April 17, 2025 00:16
AnteDeliria pushed a commit to AnteDeliria/dioxus that referenced this pull request Jun 2, 2025
AnteDeliria pushed a commit to AnteDeliria/dioxus that referenced this pull request Jul 23, 2025
jongiddy added a commit to jongiddy/cf-dioxus that referenced this pull request Sep 7, 2025
The `web` feature uses code that expects to run in a browser with web objects
including `window`. Workers code provides a JS environment without these
objects.

As an example, see the `eval` implementation in
DioxusLabs/dioxus#3877 (added in Dioxus 0.7).
jongiddy added a commit to jongiddy/cf-dioxus that referenced this pull request Sep 7, 2025
The `web` feature uses code that expects to run in a browser with web objects
including `window`. Workers code provides a JS environment without these
objects.

As an example, see the `eval` implementation in
DioxusLabs/dioxus#3877 (added in Dioxus 0.7).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working javascript Pull requests that update Javascript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Eval suddenly stops

2 participants