CortexPE / TeaSpoon

☕ A PLUGIN to Extend PMMP's Functionality without completely changing it.
GNU Affero General Public License v3.0
144 stars 102 forks source link

Anvil (crash server) #395

Closed teracube closed 5 years ago

teracube commented 5 years ago

https://poggit.pmmp.io/r/56640/TeaSpoon_dev-272.phar https://jenkins.pmmp.io/job/PocketMine-MP/1757/artifact/PocketMine-MP.phar

2019-04-23 [06:12:53] [Server thread/EMERGENCY]: An unrecoverable error has occurred and the server has crashed. Creating a crash dump
2019-04-23 [06:12:53] [Server thread/EMERGENCY]: Please upload the "/home/teracube/crashdumps/Tue_Apr_23-06.12.53-CEST_2019.log" file to the Crash Archive and submit the link to the Bug Reporting page. Give as much info as you can.
PocketMine-MP Crash Dump Tue Apr 23 06:12:53 CEST 2019

Error: Declaration of CortexPE\inventory\AnvilInventory::onClose(pocketmin\Player $who): void must be compatible with pocketmine\inventory\AnvilInventory::onClose(pocketmine\Player $who): void
File: plugins/TeaSpoon_dev-272.phar/src/CortexPE/inventory/AnvilInventory
Line: 41
Type: E_COMPILE_ERROR

THIS CRASH WAS CAUSED BY A PLUGIN
BAD PLUGIN: TeaSpoon v1.1.2

Code:
[32]  */
[33] 
[34] declare(strict_types = 1);
[35] 
[36] namespace CortexPE\inventory;
[37] 
[38] use pocketmine\inventory\AnvilInventory as PMAnvilInventory;
[39] use pocketmin\Player;
[40] 
[41] class AnvilInventory extends PMAnvilInventory {
[42]    public function getDefaultSize(): int{
[43]        return 3;
[44]    }
[45]    
[46]    public function onClose(Player $who): void{
[47]        foreach($this->getContents() as $item){
[48]            foreach($who->getInventory()->addItem($item) as $doesntFit){
[49]                $who->getLevel()->dropItem($this->holder, $doesntFit);
[50]            }
[51]        }

Backtrace:

PocketMine-MP version: 3.7.2 [Protocol 340]
Git commit: b4a8f8391b0fba26ed99bc5de0b3aaedcad4472f
uname -a: Linux g1 4.5.0-0.bpo.2-amd64 #1 SMP Debian 4.5.4-1~bpo8+1 (2016-05-13) x86_64
PHP Version: 7.2.15
Zend version: 3.2.0
OS : Linux, linux
teracube commented 5 years ago

same error if i downgrade teaspoon on dev 271 anvil : true on config.yml before and after issue

https://poggit.pmmp.io/r/56640/TeaSpoon_dev-271.phar https://jenkins.pmmp.io/job/PocketMine-MP/1757/artifact/PocketMine-MP.phar

PocketMine-MP Crash Dump Tue Apr 23 08:40:06 CEST 2019

Error: Declaration of CortexPE\inventory\AnvilInventory::onClose(CortexPE\inventory\Player $who): void must be compatible with pocketmine\inventory\AnvilInventory::onClose(pocketmine\Player $who): void
File: plugins/TeaSpoon_dev-271.phar/src/CortexPE/inventory/AnvilInventory
Line: 40
Type: E_COMPILE_ERROR

THIS CRASH WAS CAUSED BY A PLUGIN
BAD PLUGIN: TeaSpoon v1.1.2

Code:
[31]  *
[32]  */
[33] 
[34] declare(strict_types = 1);
[35] 
[36] namespace CortexPE\inventory;
[37] 
[38] use pocketmine\inventory\AnvilInventory as PMAnvilInventory;
[39] 
[40] class AnvilInventory extends PMAnvilInventory {
[41]    public function getDefaultSize(): int{
[42]        return 3;
[43]    }
[44]    
[45]    public function onClose(Player $who): void{
[46]        foreach($this->getContents() as $item){
[47]            foreach($who->getInventory()->addItem($item) as $doesntFit){
[48]                $who->getLevel()->dropItem($this->holder, $doesntFit);
[49]            }
[50]        }

Backtrace:

PocketMine-MP version: 3.7.2 [Protocol 340]
Git commit: b4a8f8391b0fba26ed99bc5de0b3aaedcad4472f
uname -a: Linux g1 4.5.0-0.bpo.2-amd64 #1 SMP Debian 4.5.4-1~bpo8+1 (2016-05-13) x86_64
PHP Version: 7.2.15
Zend version: 3.2.0
OS : Linux, linux