[php-src] Issue #20893: Assertion failure in check_node_running_in_fiber with generator in destructor

From: Date: Sat, 10 Jan 2026 13:00:53 +0000
Subject: [php-src] Issue #20893: Assertion failure in check_node_running_in_fiber with generator in destructor
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-251519@lists.php.net to get a copy of this message
Issue: https://github.com/php/php-src/issues/20893 Author: vi3tL0u1s ### Description The following code: ```php <?php class a { static $b; static $max = 2.; function __destruct() { if (self::$max-- < 0) return; self::$b = $this; static $gen = (function() { $from = (function () { x:$n[] = new a; yield; })(); try { yield from $from; } finally {} })(); $fiber = new Fiber(function () use ($gen) { $gen->current(); $gen->next(); }); $fiber->start(); } } new a; ``` ``` php: /path/to/php-src/Zend/zend_generators.c:217: check_node_running_in_fiber: Assertion `generator->execute_data' failed. Aborted ``` ## Commit c518a6ba8bf7a3eb6551424c7ca90dfa06b01b15 ## Configurations ``` ./configure --enable-debug --enable-address-sanitizer --disable-shared --with-pic --enable-mbstring --with-zlib ``` ### PHP Version ```plain PHP 8.6.0-dev (cli) (built: Jan 9 2026 14:43:36) (NTS DEBUG) Copyright (c) The PHP Group Zend Engine v4.6.0-dev, Copyright (c) Zend Technologies with Zend OPcache v8.6.0-dev, Copyright (c), by Zend Technologies ``` ### Operating System Ubuntu 22.04

« previous php.bugs (#251519) next »