From 414eec260f343a87877e0422a4d03d708bcc489e Mon Sep 17 00:00:00 2001 From: Michael Albrecht Date: Mon, 16 Mar 2026 12:46:27 +0100 Subject: [PATCH 1/4] [Upodate][PHP/Pimcore] php 8.3 and pimcore ^11.0 --- bin/composer | 2 +- compose.yaml | 2 +- composer.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/composer b/bin/composer index 66df3c9f..396a3cb1 100755 --- a/bin/composer +++ b/bin/composer @@ -1,3 +1,3 @@ #!/usr/bin/env bash -docker-compose run -u "$(id -u)" -v /tmp:/tmp -e COMPOSER_CACHE_DIR=/tmp/composer --no-deps --rm --entrypoint=/usr/bin/composer php "$@" +exec docker compose run --rm --user "$(id -u):$(id -g)" --no-deps php composer "$@" diff --git a/compose.yaml b/compose.yaml index e86c102b..6b792f5d 100644 --- a/compose.yaml +++ b/compose.yaml @@ -1,6 +1,6 @@ services: php: - image: pimcore/pimcore:php8.2.8-v2.0 + image: pimcore/pimcore:php8.3-debug-latest volumes: - ./:/var/www/html/ environment: diff --git a/composer.json b/composer.json index 79922f6f..91c722e3 100644 --- a/composer.json +++ b/composer.json @@ -33,7 +33,7 @@ } }, "require": { - "php": "~8.0.0 || ~8.1.0 || ~8.2.0", + "php": "~8.2.0 || ~8.3.0", "pimcore/pimcore": "^10.0 || ^11.0" }, "require-dev": { From 44cce5cebc1dfcbc6582b37c6965295cdb292245 Mon Sep 17 00:00:00 2001 From: Michael Albrecht Date: Mon, 16 Mar 2026 12:48:09 +0100 Subject: [PATCH 2/4] [Upodate][PHP/Pimcore] php 8.3 and pimcore ^11.0 --- .github/workflows/php.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index 54dc7bdc..81236c74 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -17,7 +17,7 @@ jobs: fail-fast: false matrix: include: - - php-version: "8.0" + - php-version: "8.2" dependencies: "lowest" steps: @@ -47,10 +47,10 @@ jobs: fail-fast: false matrix: include: - - php-version: "8.1" - dependencies: "highest" - php-version: "8.2" dependencies: "highest" + - php-version: "8.3" + dependencies: "highest" steps: - name: Git Checkout From 460d936295ac5f4bb6423fb9510fbed6663614a4 Mon Sep 17 00:00:00 2001 From: Michael Albrecht Date: Mon, 16 Mar 2026 12:57:51 +0100 Subject: [PATCH 3/4] [Upodate][PHP/Pimcore] php 8.3 and pimcore ^11.0 --- composer.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/composer.json b/composer.json index 91c722e3..aba5f69d 100644 --- a/composer.json +++ b/composer.json @@ -15,6 +15,9 @@ "sort-packages": true, "allow-plugins": { "phpstan/extension-installer": true + }, + "audit": { + "block-insecure": false } }, "autoload": { From 4d7c2aee533024f776d3be1da773573c8c3ea59a Mon Sep 17 00:00:00 2001 From: Michael Albrecht Date: Mon, 16 Mar 2026 13:00:46 +0100 Subject: [PATCH 4/4] [Upodate][PHP/Pimcore] cs-fixed --- src/Formatter/AttributeFormatter.php | 6 +++--- src/Formatter/ClassFormatter.php | 6 +++--- src/Formatter/RelationsFormatter.php | 12 ++++++------ src/Model/Attribute.php | 3 --- src/Service/ClassDefinition2UMLService.php | 4 ++-- src/Service/PrinterService.php | 2 +- 6 files changed, 15 insertions(+), 18 deletions(-) diff --git a/src/Formatter/AttributeFormatter.php b/src/Formatter/AttributeFormatter.php index 29ec6d7b..9de2e731 100644 --- a/src/Formatter/AttributeFormatter.php +++ b/src/Formatter/AttributeFormatter.php @@ -18,14 +18,14 @@ public function format(Attribute $attribute): string { $additionalInfo = ''; if ($attribute->getAdditionalInfo()) { - $additionalInfo = sprintf(' (%s)', $attribute->getAdditionalInfo()); + $additionalInfo = \sprintf(' (%s)', $attribute->getAdditionalInfo()); } if ($attribute->getDefaultValue()) { - $additionalInfo .= sprintf(' = %s', $attribute->getDefaultValue()); + $additionalInfo .= \sprintf(' = %s', $attribute->getDefaultValue()); } - return sprintf( + return \sprintf( <<%s %s%s%s TABLEROW, diff --git a/src/Formatter/ClassFormatter.php b/src/Formatter/ClassFormatter.php index 5be6d8b8..2dfc1609 100644 --- a/src/Formatter/ClassFormatter.php +++ b/src/Formatter/ClassFormatter.php @@ -16,7 +16,7 @@ public function __construct( public function format(ObjectClass $objectClass): string { - $labelDeclaration = sprintf( + $labelDeclaration = \sprintf( << <DataObject>
%s (ID: %s)%s @@ -27,7 +27,7 @@ public function format(ObjectClass $objectClass): string $this->formatAttributes($objectClass), ); - return sprintf( + return \sprintf( << %s', $relation->getSourceType(), $relation->getTargetType()); + $name = \sprintf('%s -> %s', $relation->getSourceType(), $relation->getTargetType()); - $dir = sprintf('dir=%s', $relation->isBidirectional() ? 'none' : 'both'); + $dir = \sprintf('dir=%s', $relation->isBidirectional() ? 'none' : 'both'); $arrow = ''; $label = ''; @@ -26,10 +26,10 @@ public function format(array $relations): string $label = 'label="<>"'; } elseif ($relation->isAggregation()) { $arrow = 'arrowtail=odiamond'; - $label = sprintf('label="%s %s"', $relation->getSourceRolename(), $this->determineCardinality($relation)); + $label = \sprintf('label="%s %s"', $relation->getSourceRolename(), $this->determineCardinality($relation)); } - $result[] = sprintf('%s [%s %s %s];', $name, $dir, $arrow, $label); + $result[] = \sprintf('%s [%s %s %s];', $name, $dir, $arrow, $label); } return implode(PHP_EOL, $result); @@ -41,9 +41,9 @@ private function determineCardinality(Relation $relation): string $minimum = $relation->getMinimum() ?: '0'; $maximum = $relation->getMaximum() ?: 'n'; if ($minimum === $maximum) { - return sprintf('(%s)', $minimum); + return \sprintf('(%s)', $minimum); } - return sprintf($result, $minimum, $maximum); + return \sprintf($result, $minimum, $maximum); } } diff --git a/src/Model/Attribute.php b/src/Model/Attribute.php index e3b51339..606b1b75 100644 --- a/src/Model/Attribute.php +++ b/src/Model/Attribute.php @@ -61,9 +61,6 @@ public function setName(string $name): Attribute return $this; } - /** - * @return ?string - */ public function getAdditionalInfo(): ?string { return $this->additionalInfo; diff --git a/src/Service/ClassDefinition2UMLService.php b/src/Service/ClassDefinition2UMLService.php index d05c807e..04a55503 100644 --- a/src/Service/ClassDefinition2UMLService.php +++ b/src/Service/ClassDefinition2UMLService.php @@ -114,7 +114,7 @@ private function addRelation(mixed $fieldDefinition, Relation $relation, ClassDe ->setSourceRolename($fieldDefinition->getTitle()) ->setMinimum($fieldDefinition->getMandatory() ? 1 : 0); - $relationsKey = sprintf('%s.%s - %s', $relation->getSourceType(), $fieldDefinition->getName(), $relation->getTargetType()); + $relationsKey = \sprintf('%s.%s - %s', $relation->getSourceType(), $fieldDefinition->getName(), $relation->getTargetType()); // if relation already exists it must be bidirectional if (\array_key_exists($relationsKey, $this->relations)) { @@ -130,7 +130,7 @@ private function addReverseRelation(ClassDefinition\Data\ReverseObjectRelation $ ->setSourceRolename($fieldDefinition->getOwnerFieldName()) ->setTargetType($classDefinition->getName() ?? self::UNKNOWN); - $relationsKey = sprintf('%s.%s - %s', $relation->getSourceType(), $fieldDefinition->getOwnerFieldName(), $relation->getTargetType()); + $relationsKey = \sprintf('%s.%s - %s', $relation->getSourceType(), $fieldDefinition->getOwnerFieldName(), $relation->getTargetType()); // if relation exists already merge it otherwise if (\array_key_exists($relationsKey, $this->relations)) { diff --git a/src/Service/PrinterService.php b/src/Service/PrinterService.php index e6915a68..b62fe9f4 100644 --- a/src/Service/PrinterService.php +++ b/src/Service/PrinterService.php @@ -31,7 +31,7 @@ public function print(array $classes, array $relations) } OUTPUT; - return sprintf($output, $this->printClasses($classes), $this->printRelations($relations)); + return \sprintf($output, $this->printClasses($classes), $this->printRelations($relations)); } /**