20 Commits

Author SHA1 Message Date
Dylan K. Taylor
f75ca312cc
Worker: Unstack tasks in a synchronized block
this prevents any tasks still left in the queue on shutdown getting pulled out by the worker when we're attempting to shut it down.
This led to various race conditions, most notably weird cases where PopulationTask would inexplicably find its expected generator state had not been correctly set up.
2022-08-21 21:57:11 +01:00
Dylan K. Taylor
38d6284671
Use PHP-CS-Fixer to enforce file header presence 2022-06-04 17:34:49 +01:00
Dylan K. Taylor
c0b15de504
Modernize private static property declarations 2022-05-17 21:55:16 +01:00
Dylan K. Taylor
194cb1fb84
phpstan 1.5.1 2022-03-28 17:12:00 +01:00
Dylan K. Taylor
4e956d5d1d
Replace remaining disallowed operators 2022-01-20 19:23:19 +00:00
Jack Honour
58e1e7bd6f
Worker: fixed missing AsyncTask import for documentation (#4719)
OCD from f5c9c02e09f54b53ed4c495c8a0000b54930ccef
2022-01-10 15:12:37 +00:00
Dylan K. Taylor
f5c9c02e09
Improve documentation of Thread and Worker 2021-09-10 15:57:45 +01:00
Dylan K. Taylor
5fbc7681b0
Allow registering multiple ClassLoaders for a thread 2021-07-15 19:00:40 +01:00
Dylan K. Taylor
f6f0938b3b
Merge branch 'stable' 2021-05-21 01:27:35 +01:00
Dylan K. Taylor
6d6f8c3c38 custom threads: use PTHREADS_INHERIT_NONE by default
this has the most reliable behaviour, because some stuff like respect/validation likes to include files unconditionally which declare functions that are already declared, which breaks due to the lack of function autoloading.
2020-12-01 22:32:59 +00:00
Dylan K. Taylor
abe4f1bf25 Merge commit '763c8ebfe3bb8a597768d86040fee130c8fc7ab8'
# Conflicts:
#	resources/vanilla
#	src/pocketmine/Worker.php
#	src/thread/CommonThreadPartsTrait.php
2020-06-26 18:46:01 +01:00
Dylan K. Taylor
3299bc4023 start using pocketmine/errorhandler 2020-05-10 13:04:40 +01:00
Dylan K. Taylor
f9a587d40e imports cleanup 2020-04-28 17:27:38 +01:00
Dylan K. Taylor
ca909ebc1d Merge branch 'next-minor' 2020-03-10 13:05:37 +00:00
Dylan K. Taylor
fb1126797a Merge branch 'stable' 2020-02-07 18:13:55 +00:00
Dylan K. Taylor
67bcc1c0fb phpdoc armageddon for master, pass 1 2020-01-22 11:55:03 +00:00
Dylan K. Taylor
3ee6887792 populate remaining missing return types, using native returns where possible
this is done separately to stable so that stable changes can be integrated easily using an empty merge.
2020-01-19 10:26:35 +00:00
Dylan K. Taylor
cda1143a79 Merge branch 'stable' 2020-01-09 17:17:42 +00:00
Dylan K. Taylor
cbef2bbc51 move ThreadException to pocketmine\thread namespace 2019-10-29 12:42:38 +00:00
Dylan K. Taylor
5499ac620c Removed pocketmine subdirectory, map PSR-4 style 2019-07-30 19:14:57 +01:00