amphp / file

An abstraction layer and non-blocking file access solution that keeps your application responsive.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Revolt event loop hangs with file operations inside defer()

evll opened this issue · comments

Not sure, if it's related to #75 , but the script below is just hanging indefinitely (writing succeeds):

\Revolt\EventLoop::defer(function () {
    \Amp\File\write('/code/out', 'contents');
});

\Revolt\EventLoop::run();

The same version without defer() works fine:

\Amp\File\write('/code/out', 'contents');

\Revolt\EventLoop::run();

I believe this was fixed with amphp/parallel@v2.2.5. If not, feel free to repoen.