Open jdchmiel opened 8 years ago
php -v PHP 7.0.2 (cli) (built: Jan 12 2016 15:00:50) ( ZTS ) Copyright (c) 1997-2015 The PHP Group Zend Engine v3.0.0, Copyright (c) 1998-2015 Zend Technologies with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2015, by Zend Technologies
root@254e6ba419d7:/opt/threading# php -i "phpinfor();" | grep -C3 pthreads /usr/local/etc/php/conf.d/docker-php-ext-mongodb.ini, /usr/local/etc/php/conf.d/docker-php-ext-opcache.ini, /usr/local/etc/php/conf.d/docker-php-ext-pdo_mysql.ini, /usr/local/etc/php/conf.d/docker-php-ext-pthreads.ini, /usr/local/etc/php/conf.d/upload-size.ini
Revision => $Id: 547e93e58ead98dbbb1d44dbaf86513eb08ace3f $
pthreads
Version => 3.1.5
changing line 22 to:
class Task extends \Threaded {
seems to fix it. Found that by the tip where https://github.com/krakjoe/pthreads/issues/548 says the docs are out of date.
I have been banging my head against the wall trying to get composer autoloading working in a Magento project. I was excited to find this example / tutorial to build from. After trying to copy the logic to my code with no success - I get seg faults as soon as I change:
/* override default inheritance behaviour for the new threaded context */ public function start(int $options = NULL) { return parent::start(PTHREADS_INHERIT_ALL ); }
to/* override default inheritance behaviour for the new threaded context */ public function start(int $options = NULL) { return parent::start(PTHREADS_INHERIT_NONE ); }
I decided to try this example verbatim. I get an error as follows:Obviously the warning I had already come across and fixed above by adding the type hints, but I did not even bother looking any farther into the Fatal as I have veered way too far off task now.