Compare commits

..

11 Commits

Author SHA1 Message Date
327a9b020e Bump ramsey/uuid in the production-patch-updates group
Bumps the production-patch-updates group with 1 update: [ramsey/uuid](https://github.com/ramsey/uuid).


Updates `ramsey/uuid` from 4.9.0 to 4.9.1
- [Release notes](https://github.com/ramsey/uuid/releases)
- [Changelog](https://github.com/ramsey/uuid/blob/4.x/CHANGELOG.md)
- [Commits](https://github.com/ramsey/uuid/compare/4.9.0...4.9.1)

---
updated-dependencies:
- dependency-name: ramsey/uuid
  dependency-version: 4.9.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: production-patch-updates
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-08 11:07:45 +00:00
ce90835c7b Bump build/php from b839e52 to 1d9cda6 (#6796) 2025-09-08 10:21:54 +00:00
dc04992ba9 Merge branch 'stable' of github.com:pmmp/PocketMine-MP into stable 2025-09-05 19:25:31 +01:00
bddab47ee8 Bump build/php from ce1b095 to b839e52 (#6795) 2025-09-05 10:32:17 +00:00
3411103e11 Remove dead PHPStan ignores 2025-09-04 23:29:55 +01:00
1868536916 Add PHP 8.4 to test matrix 2025-09-04 21:58:12 +01:00
9a0a8a55b1 Bump shivammathur/setup-php in the github-actions group (#6787) 2025-09-02 13:17:41 +00:00
09cc76ae2b 5.33.2 is next
Commit created by: https://github.com/pmmp/RestrictedActions/actions/runs/17351431906
2025-08-31 02:28:17 +00:00
a540de1e3c Prepare 5.33.1 patch release (#6784) 2025-08-31 03:27:21 +01:00
9eee1a9a6e Banner: don't bail on missing type tags
we didn't set these prior to 5.33.0, so these won't be present on older worlds.
2025-08-31 03:22:58 +01:00
f673159471 5.33.1 is next
Commit created by: https://github.com/pmmp/RestrictedActions/actions/runs/17346780638
2025-08-30 17:46:07 +00:00
15 changed files with 124 additions and 42 deletions

View File

@ -18,7 +18,7 @@ jobs:
- uses: actions/checkout@v5
- name: Setup PHP and tools
uses: shivammathur/setup-php@2.35.3
uses: shivammathur/setup-php@2.35.4
with:
php-version: 8.2

View File

@ -49,7 +49,7 @@ jobs:
- uses: actions/checkout@v5
- name: Setup PHP
uses: shivammathur/setup-php@2.35.3
uses: shivammathur/setup-php@2.35.4
with:
php-version: 8.2

View File

@ -87,7 +87,7 @@ jobs:
submodules: true
- name: Setup PHP
uses: shivammathur/setup-php@2.35.3
uses: shivammathur/setup-php@2.35.4
with:
php-version: ${{ env.PHP_VERSION }}

View File

@ -11,7 +11,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php: ["8.1", "8.2", "8.3"]
php: ["8.1", "8.2", "8.3", "8.4"]
uses: ./.github/workflows/main-php-matrix.yml
with:
@ -28,7 +28,7 @@ jobs:
- uses: actions/checkout@v5
- name: Setup PHP and tools
uses: shivammathur/setup-php@2.35.3
uses: shivammathur/setup-php@2.35.4
with:
php-version: 8.3
tools: php-cs-fixer:3.75

View File

@ -127,3 +127,9 @@ Consider using the `mcpe-protocol` directive in `plugin.yml` as a constraint if
## Internals
- `BlockStateUpgrader` is now almost entirely independent from `BlockStateData`. It's anticipated that the upgrader library will be separable from the core in the future.
- `Block->readStateFromWorld()` is now triggered on chunk load for any position containing a tile. This should allow more effective updating of blocks with properties in their tiles.
# 5.33.1
Released 31st August 2025.
## Fixes
- Fixed banners placed in prior versions getting their tiles deleted (due to missing `Type` tags).

14
composer.lock generated
View File

@ -818,20 +818,20 @@
},
{
"name": "ramsey/uuid",
"version": "4.9.0",
"version": "4.9.1",
"source": {
"type": "git",
"url": "https://github.com/ramsey/uuid.git",
"reference": "4e0e23cc785f0724a0e838279a9eb03f28b092a0"
"reference": "81f941f6f729b1e3ceea61d9d014f8b6c6800440"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/ramsey/uuid/zipball/4e0e23cc785f0724a0e838279a9eb03f28b092a0",
"reference": "4e0e23cc785f0724a0e838279a9eb03f28b092a0",
"url": "https://api.github.com/repos/ramsey/uuid/zipball/81f941f6f729b1e3ceea61d9d014f8b6c6800440",
"reference": "81f941f6f729b1e3ceea61d9d014f8b6c6800440",
"shasum": ""
},
"require": {
"brick/math": "^0.8.8 || ^0.9 || ^0.10 || ^0.11 || ^0.12 || ^0.13",
"brick/math": "^0.8.8 || ^0.9 || ^0.10 || ^0.11 || ^0.12 || ^0.13 || ^0.14",
"php": "^8.0",
"ramsey/collection": "^1.2 || ^2.0"
},
@ -890,9 +890,9 @@
],
"support": {
"issues": "https://github.com/ramsey/uuid/issues",
"source": "https://github.com/ramsey/uuid/tree/4.9.0"
"source": "https://github.com/ramsey/uuid/tree/4.9.1"
},
"time": "2025-06-25T14:20:11+00:00"
"time": "2025-09-04T20:59:21+00:00"
},
{
"name": "symfony/filesystem",

View File

@ -4,6 +4,8 @@ includes:
- tests/phpstan/configs/impossible-generics.neon
- tests/phpstan/configs/php-bugs.neon
- tests/phpstan/configs/phpstan-bugs.neon
- tests/phpstan/configs/property-hook-sadness.neon
- tests/phpstan/configs/reflection-class-sadness.neon
- tests/phpstan/configs/spl-fixed-array-sucks.neon
- vendor/phpstan/phpstan-phpunit/extension.neon
- vendor/phpstan/phpstan-phpunit/rules.neon

View File

@ -31,8 +31,8 @@ use function str_repeat;
final class VersionInfo{
public const NAME = "PocketMine-MP";
public const BASE_VERSION = "5.33.0";
public const IS_DEVELOPMENT_BUILD = false;
public const BASE_VERSION = "5.33.2";
public const IS_DEVELOPMENT_BUILD = true;
public const BUILD_CHANNEL = "stable";
/**

View File

@ -82,7 +82,7 @@ class Banner extends Spawnable{
}
}
$this->type = $nbt->getInt(self::TAG_TYPE);
$this->type = $nbt->getInt(self::TAG_TYPE, self::TYPE_NORMAL);
}
protected function writeSaveData(CompoundTag $nbt) : void{

View File

@ -48,7 +48,7 @@ final class AsyncGeneratorExecutor implements GeneratorExecutor{
\Logger $logger,
private readonly AsyncPool $workerPool,
private readonly GeneratorExecutorSetupParameters $setupParameters,
int $asyncContextId = null
?int $asyncContextId = null
){
$this->logger = new \PrefixedLogger($logger, "AsyncGeneratorExecutor");

View File

@ -1158,12 +1158,6 @@ parameters:
count: 2
path: ../../../src/world/World.php
-
message: '#^Parameter \#2 \$x of method pocketmine\\block\\Block\:\:position\(\) expects int, float\|int given\.$#'
identifier: argument.type
count: 2
path: ../../../src/world/World.php
-
message: '#^Parameter \#2 \$y of method pocketmine\\world\\World\:\:getBlockAt\(\) expects int, float\|int given\.$#'
identifier: argument.type
@ -1188,12 +1182,6 @@ parameters:
count: 2
path: ../../../src/world/World.php
-
message: '#^Parameter \#3 \$y of method pocketmine\\block\\Block\:\:position\(\) expects int, float\|int given\.$#'
identifier: argument.type
count: 2
path: ../../../src/world/World.php
-
message: '#^Parameter \#3 \$z of method pocketmine\\world\\World\:\:getBlockAt\(\) expects int, float\|int given\.$#'
identifier: argument.type
@ -1218,12 +1206,6 @@ parameters:
count: 2
path: ../../../src/world/World.php
-
message: '#^Parameter \#4 \$z of method pocketmine\\block\\Block\:\:position\(\) expects int, float\|int given\.$#'
identifier: argument.type
count: 2
path: ../../../src/world/World.php
-
message: '#^Method pocketmine\\world\\biome\\BiomeRegistry\:\:getBiome\(\) should return pocketmine\\world\\biome\\Biome but returns pocketmine\\world\\biome\\Biome\|null\.$#'
identifier: return.type

View File

@ -0,0 +1,61 @@
parameters:
ignoreErrors:
-
message: '#^Cannot unset property pocketmine\\entity\\Human\:\:\$enderInventory because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Human.php
-
message: '#^Cannot unset property pocketmine\\entity\\Human\:\:\$hungerManager because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Human.php
-
message: '#^Cannot unset property pocketmine\\entity\\Human\:\:\$inventory because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Human.php
-
message: '#^Cannot unset property pocketmine\\entity\\Human\:\:\$offHandInventory because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Human.php
-
message: '#^Cannot unset property pocketmine\\entity\\Human\:\:\$xpManager because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Human.php
-
message: '#^Cannot unset property pocketmine\\entity\\Living\:\:\$armorInventory because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Living.php
-
message: '#^Cannot unset property pocketmine\\entity\\Living\:\:\$effectManager because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/entity/Living.php
-
message: '#^Cannot unset property pocketmine\\player\\Player\:\:\$craftingGrid because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/player/Player.php
-
message: '#^Cannot unset property pocketmine\\player\\Player\:\:\$cursorInventory because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/player/Player.php
-
message: '#^Cannot unset property pocketmine\\world\\format\\io\\leveldb\\LevelDB\:\:\$db because it might have hooks in a subclass\.$#'
identifier: unset.possiblyHookedProperty
count: 1
path: ../../../src/world/format/io/leveldb/LevelDB.php

View File

@ -0,0 +1,31 @@
parameters:
ignoreErrors:
-
message: '#^Call\-site variance of covariant pocketmine\\event\\Event in generic type ReflectionClass\<covariant pocketmine\\event\\Event\> in PHPDoc tag @param for parameter \$class is redundant, template type T of object of class ReflectionClass has the same variance\.$#'
identifier: generics.callSiteVarianceRedundant
count: 2
path: ../../phpunit/event/HandlerListManagerTest.php
-
message: '#^Call\-site variance of covariant pocketmine\\event\\Event in generic type ReflectionClass\<covariant pocketmine\\event\\Event\> in PHPDoc tag @param for parameter \$expect is redundant, template type T of object of class ReflectionClass has the same variance\.$#'
identifier: generics.callSiteVarianceRedundant
count: 1
path: ../../phpunit/event/HandlerListManagerTest.php
-
message: '#^Call\-site variance of covariant pocketmine\\event\\Event in generic type ReflectionClass\<covariant pocketmine\\event\\Event\> in PHPDoc tag @return is redundant, template type T of object of class ReflectionClass has the same variance\.$#'
identifier: generics.callSiteVarianceRedundant
count: 3
path: ../../phpunit/event/HandlerListManagerTest.php
-
message: '#^Call\-site variance of covariant pocketmine\\event\\Event in generic type ReflectionClass\<covariant pocketmine\\event\\Event\> in PHPDoc tag @var for property pocketmine\\event\\HandlerListManagerTest\:\:\$isValidFunc is redundant, template type T of object of class ReflectionClass has the same variance\.$#'
identifier: generics.callSiteVarianceRedundant
count: 1
path: ../../phpunit/event/HandlerListManagerTest.php
-
message: '#^Call\-site variance of covariant pocketmine\\event\\Event in generic type ReflectionClass\<covariant pocketmine\\event\\Event\> in PHPDoc tag @var for property pocketmine\\event\\HandlerListManagerTest\:\:\$resolveParentFunc is redundant, template type T of object of class ReflectionClass has the same variance\.$#'
identifier: generics.callSiteVarianceRedundant
count: 2
path: ../../phpunit/event/HandlerListManagerTest.php

View File

@ -35,12 +35,12 @@ class HandlerListManagerTest extends TestCase{
/**
* @var \Closure
* @phpstan-var \Closure(\ReflectionClass<Event>) : bool
* @phpstan-var \Closure(\ReflectionClass<covariant Event>) : bool
*/
private $isValidFunc;
/**
* @var \Closure
* @phpstan-var \Closure(\ReflectionClass<Event>) : ?\ReflectionClass<Event>
* @phpstan-var \Closure(\ReflectionClass<covariant Event>) : ?\ReflectionClass<covariant Event>
*/
private $resolveParentFunc;
@ -53,7 +53,7 @@ class HandlerListManagerTest extends TestCase{
/**
* @return \Generator|mixed[][]
* @phpstan-return \Generator<int, array{\ReflectionClass<Event>, bool, string}, void, void>
* @phpstan-return \Generator<int, array{\ReflectionClass<covariant Event>, bool, string}, void, void>
*/
public static function isValidClassProvider() : \Generator{
yield [new \ReflectionClass(Event::class), false, "event base should not be handleable"];
@ -65,7 +65,7 @@ class HandlerListManagerTest extends TestCase{
/**
* @dataProvider isValidClassProvider
*
* @phpstan-param \ReflectionClass<Event> $class
* @phpstan-param \ReflectionClass<covariant Event> $class
*/
public function testIsValidClass(\ReflectionClass $class, bool $isValid, string $reason) : void{
self::assertSame($isValid, ($this->isValidFunc)($class), $reason);
@ -73,7 +73,7 @@ class HandlerListManagerTest extends TestCase{
/**
* @return \Generator|\ReflectionClass[][]
* @phpstan-return \Generator<int, array{\ReflectionClass<Event>, \ReflectionClass<Event>|null}, void, void>
* @phpstan-return \Generator<int, array{\ReflectionClass<covariant Event>, \ReflectionClass<covariant Event>|null}, void, void>
*/
public static function resolveParentClassProvider() : \Generator{
yield [new \ReflectionClass(TestConcreteExtendsAllowHandleEvent::class), new \ReflectionClass(TestAbstractAllowHandleEvent::class)];
@ -85,8 +85,8 @@ class HandlerListManagerTest extends TestCase{
/**
* @dataProvider resolveParentClassProvider
*
* @phpstan-param \ReflectionClass<Event> $class
* @phpstan-param \ReflectionClass<Event>|null $expect
* @phpstan-param \ReflectionClass<covariant Event> $class
* @phpstan-param \ReflectionClass<covariant Event>|null $expect
*/
public function testResolveParentClass(\ReflectionClass $class, ?\ReflectionClass $expect) : void{
if($expect === null){