Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ composer.lock
/tests/Metadata/Extractor/Adapter/*.yaml
/vendor/
/Dockerfile

tests/Fixtures/app/config/reference.php
4 changes: 3 additions & 1 deletion .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,16 @@
'docs/guides',
'docs/var',
'src/Doctrine/Orm/Tests/var',
'src/Doctrine/Odm/Tests/var'
'src/Doctrine/Odm/Tests/var',
])
->notPath('tests/Fixtures/app/config/reference.php')
->notPath('src/Symfony/Bundle/DependencyInjection/Configuration.php')
->append([
'tests/Fixtures/app/console',
]);

return (new PhpCsFixer\Config())
->setUnsupportedPhpVersionAllowed(true)
->setRiskyAllowed(true)
->setRules([
'@DoctrineAnnotation' => true,
Expand Down
80 changes: 40 additions & 40 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"dev-main": "4.3.x-dev"
},
"symfony": {
"require": "^6.4 || ^7.1"
"require": "^6.4 || ^7.1 || ^8.0"
},
"pmu": {
"projects": [
Expand Down Expand Up @@ -111,15 +111,15 @@
"psr/cache": "^1.0 || ^2.0 || ^3.0",
"psr/container": "^1.0 || ^2.0",
"symfony/deprecation-contracts": "^3.1",
"symfony/http-foundation": "^6.4.14 || ^7.0",
"symfony/http-kernel": "^6.4 || ^7.0",
"symfony/property-access": "^6.4 || ^7.0",
"symfony/property-info": "^6.4 || ^7.1",
"symfony/serializer": "^6.4 || ^7.0",
"symfony/http-foundation": "^6.4.14 || ^7.0 || ^8.0",
"symfony/http-kernel": "^6.4 || ^7.0 || ^8.0",
"symfony/property-access": "^6.4 || ^7.0 || ^8.0",
"symfony/property-info": "^6.4 || ^7.1 || ^8.0",
"symfony/serializer": "^6.4 || ^7.0 || ^8.0",
"symfony/translation-contracts": "^3.3",
"symfony/type-info": "^7.3 || 7.4.x-dev",
"symfony/validator": "^6.4.11 || ^7.1",
"symfony/web-link": "^6.4 || ^7.1",
"symfony/type-info": "^7.4 || ^8.0",
"symfony/validator": "^6.4.11 || ^7.1 || ^8.0",
"symfony/web-link": "^6.4 || ^7.1 || ^8.0",
"willdurand/negotiation": "^3.1"
},
"require-dev": {
Expand All @@ -129,7 +129,7 @@
"doctrine/cache": "^1.11 || ^2.1",
"doctrine/common": "^3.2.2",
"doctrine/dbal": "^4.0",
"doctrine/doctrine-bundle": "^2.11",
"doctrine/doctrine-bundle": "^2.11 || ^3.1",
"doctrine/mongodb-odm": "^2.10",
"doctrine/mongodb-odm-bundle": "^5.0",
"doctrine/orm": "^2.17 || ^3.0",
Expand Down Expand Up @@ -163,38 +163,38 @@
"soyuka/contexts": "^3.3.10",
"soyuka/pmu": "^0.2.0",
"soyuka/stubs-mongodb": "^1.0",
"symfony/asset": "^6.4 || ^7.0",
"symfony/browser-kit": "^6.4 || ^7.0",
"symfony/cache": "^6.4 || ^7.0",
"symfony/config": "^6.4 || ^7.0",
"symfony/console": "^6.4 || ^7.0",
"symfony/css-selector": "^6.4 || ^7.0",
"symfony/dependency-injection": "^6.4 || ^7.0",
"symfony/doctrine-bridge": "^6.4.2 || ^7.1",
"symfony/dom-crawler": "^6.4 || ^7.0",
"symfony/error-handler": "^6.4 || ^7.0",
"symfony/event-dispatcher": "^6.4 || ^7.0",
"symfony/expression-language": "^6.4 || ^7.0",
"symfony/finder": "^6.4 || ^7.0",
"symfony/form": "^6.4 || ^7.0",
"symfony/framework-bundle": "^6.4 || ^7.0 || 7.4.x-dev",
"symfony/http-client": "^6.4 || ^7.0",
"symfony/intl": "^6.4 || ^7.0",
"symfony/json-streamer": "7.4.x-dev",
"symfony/asset": "^6.4 || ^7.0 || ^8.0",
"symfony/browser-kit": "^6.4 || ^7.0 || ^8.0",
"symfony/cache": "^6.4 || ^7.0 || ^8.0",
"symfony/config": "^6.4 || ^7.0 || ^8.0",
"symfony/console": "^6.4 || ^7.0 || ^8.0",
"symfony/css-selector": "^6.4 || ^7.0 || ^8.0",
"symfony/dependency-injection": "^6.4 || ^7.0 || ^8.0",
"symfony/doctrine-bridge": "^6.4.2 || ^7.1 || ^8.0",
"symfony/dom-crawler": "^6.4 || ^7.0 || ^8.0",
"symfony/error-handler": "^6.4 || ^7.0 || ^8.0",
"symfony/event-dispatcher": "^6.4 || ^7.0 || ^8.0",
"symfony/expression-language": "^6.4 || ^7.0 || ^8.0",
"symfony/finder": "^6.4 || ^7.0 || ^8.0",
"symfony/form": "^6.4 || ^7.0 || ^8.0",
"symfony/framework-bundle": "^6.4 || ^7.0 || ^8.0",
"symfony/http-client": "^6.4 || ^7.0 || ^8.0",
"symfony/intl": "^6.4 || ^7.0 || ^8.0",
"symfony/json-streamer": "^7.4 || ^8.0",
"symfony/maker-bundle": "^1.24",
"symfony/mercure-bundle": "*",
"symfony/messenger": "^6.4 || ^7.0",
"symfony/object-mapper": "^7.3 || 7.4.x-dev",
"symfony/routing": "^6.4 || ^7.0",
"symfony/security-bundle": "^6.4 || ^7.0",
"symfony/security-core": "^6.4 || ^7.0",
"symfony/stopwatch": "^6.4 || ^7.0",
"symfony/string": "^6.4 || ^7.0",
"symfony/twig-bundle": "^6.4 || ^7.0",
"symfony/uid": "^6.4 || ^7.0",
"symfony/var-exporter": "^7.3 || ^7.4.x-dev",
"symfony/web-profiler-bundle": "^6.4 || ^7.0",
"symfony/yaml": "^6.4 || ^7.0",
"symfony/messenger": "^6.4 || ^7.0 || ^8.0",
"symfony/object-mapper": "^7.4 || ^8.0",
"symfony/routing": "^6.4 || ^7.0 || ^8.0",
"symfony/security-bundle": "^6.4 || ^7.0 || ^8.0",
"symfony/security-core": "^6.4 || ^7.0 || ^8.0",
"symfony/stopwatch": "^6.4 || ^7.0 || ^8.0",
"symfony/string": "^6.4 || ^7.0 || ^8.0",
"symfony/twig-bundle": "^6.4 || ^7.0 || ^8.0",
"symfony/uid": "^6.4 || ^7.0 || ^8.0",
"symfony/var-exporter": "^7.4 || ^8.0",
"symfony/web-profiler-bundle": "^6.4 || ^7.0 || ^8.0",
"symfony/yaml": "^6.4 || ^7.0 || ^8.0",
"twig/twig": "^1.42.3 || ^2.12 || ^3.0",
"webonyx/graphql-php": "^15.0"
},
Expand Down
1 change: 0 additions & 1 deletion docs/config/packages/doctrine.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@ doctrine:
dbal:
url: 'sqlite:///%kernel.project_dir%/var/%guide%.db'
orm:
auto_generate_proxy_classes: true
naming_strategy: doctrine.orm.naming_strategy.underscore_number_aware
auto_mapping: false
19 changes: 4 additions & 15 deletions phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ parameters:
ApiPlatform\Metadata\Resource\ResourceMetadataCollection:
- handleNotFound
ignoreErrors:
# ignore type todo remove in 5.0
-
message: '#Symfony\\Component\\PropertyInfo\\Type#'
identifier: class.notFound
# False positives
- message: '#Call to an undefined method Negotiation\\AcceptHeader::getType\(\).#'
-
Expand Down Expand Up @@ -78,32 +82,17 @@ parameters:
message: '#Service "test" is not registered in the container\.#'
path: src/GraphQl/Tests/Type/TypesContainerTest.php

# Expected, due to optional interfaces
- '#Method Symfony\\Component\\Serializer\\NameConverter\\NameConverterInterface::denormalize\(\) invoked with (2|3|4) parameters, 1 required\.#'
- '#Method Symfony\\Component\\Serializer\\NameConverter\\NameConverterInterface::normalize\(\) invoked with (2|3|4) parameters, 1 required\.#'

# Expected, due to backward compatibility
- '#Method GraphQL\\Type\\Definition\\WrappingType::getWrappedType\(\) invoked with 1 parameter, 0 required\.#'
- '#Access to an undefined property GraphQL\\Type\\Definition\\NamedType&GraphQL\\Type\\Definition\\Type::\$name\.#'
- "#Call to function method_exists\\(\\) with GraphQL\\\\Type\\\\Definition\\\\Type&GraphQL\\\\Type\\\\Definition\\\\WrappingType and 'getInnermostType' will always evaluate to true\\.#"
- "#Call to function method_exists\\(\\) with Symfony\\\\Component\\\\Console\\\\Application and 'addCommand' will always evaluate to false\\.#"
- "#Call to function method_exists\\(\\) with 'Symfony\\\\\\\\Component\\\\\\\\PropertyInfo\\\\\\\\PropertyInfoExtractor' and 'getType' will always evaluate to true\\.#"
- "#Call to function method_exists\\(\\) with 'Symfony\\\\\\\\Component\\\\\\\\HttpFoundation\\\\\\\\Request' and 'getContentTypeFormat' will always evaluate to true\\.#"
- '#Call to an undefined method Symfony\\Component\\HttpFoundation\\Request::getContentType\(\)\.#'
- "#Call to function method_exists\\(\\) with 'Symfony\\\\\\\\Component\\\\\\\\Serializer\\\\\\\\Serializer' and 'getSupportedTypes' will always evaluate to true\\.#"
- "#Call to function method_exists\\(\\) with Symfony\\\\Component\\\\Serializer\\\\Normalizer\\\\NormalizerInterface and 'getSupportedTypes' will always evaluate to true\\.#"
- "#Call to function method_exists\\(\\) with Doctrine\\\\ODM\\\\MongoDB\\\\Configuration and 'setMetadataCache' will always evaluate to true\\.#"
- "#Call to function method_exists\\(\\) with Doctrine\\\\ODM\\\\MongoDB\\\\Mapping\\\\ClassMetadata\\|Doctrine\\\\ORM\\\\Mapping\\\\ClassMetadata and 'isChangeTrackingDef…' will always evaluate to true\\.#"
-
message: '#Instanceof between Symfony\\Component\\Serializer\\NameConverter\\NameConverterInterface and Symfony\\Component\\Serializer\\NameConverter\\MetadataAwareNameConverter will always evaluate to false\.#'
paths:
- src/GraphQl/Serializer/SerializerContextBuilder.php
- src/GraphQl/Type/FieldsBuilder.php
-
message: '#Instanceof between Symfony\\Component\\Serializer\\NameConverter\\NameConverterInterface\|null and Symfony\\Component\\Serializer\\NameConverter\\MetadataAwareNameConverter will always evaluate to false\.#'
paths:
- src/Serializer/AbstractConstraintViolationListNormalizer.php
- src/Symfony/Validator/Serializer/ValidationExceptionNormalizer.php

# See https://github.com/phpstan/phpstan-symfony/issues/27
-
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
use ApiPlatform\Metadata\ApiProperty;
use ApiPlatform\Metadata\ApiResource;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;
use Symfony\Component\Validator\Constraints as Assert;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
namespace ApiPlatform\Doctrine\Common\Tests\Fixtures\TestBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;
use Symfony\Component\Validator\Constraints as Assert;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
use ApiPlatform\Metadata\Link;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;

/**
* Fourth Level.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
namespace ApiPlatform\Doctrine\Common\Tests\Fixtures\TestBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;

/**
* Parent Dummy.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;
use Symfony\Component\Validator\Constraints as Assert;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
use ApiPlatform\Metadata\GetCollection;
use ApiPlatform\Metadata\Link;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;
use Symfony\Component\Validator\Constraints as Assert;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
use ApiPlatform\Metadata\Get;
use ApiPlatform\Metadata\Link;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Serializer\Attribute\Groups;

/**
* Third Level.
Expand Down
4 changes: 2 additions & 2 deletions src/Doctrine/Common/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"doctrine/orm": "^2.17 || ^3.0",
"phpspec/prophecy-phpunit": "^2.2",
"phpunit/phpunit": "11.5.x-dev",
"symfony/type-info": "^7.3"
"symfony/type-info": "^7.3 || ^8.0"
},
"conflict": {
"doctrine/persistence": "<1.3"
Expand Down Expand Up @@ -67,7 +67,7 @@
"dev-4.1": "4.1.x-dev"
},
"symfony": {
"require": "^6.4 || ^7.0"
"require": "^6.4 || ^7.0 || ^8.0"
},
"thanks": {
"name": "api-platform/api-platform",
Expand Down
6 changes: 5 additions & 1 deletion src/Doctrine/Odm/Tests/AppKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\PropertyInfo\Type;

/**
* AppKernel for tests.
Expand Down Expand Up @@ -77,11 +78,14 @@ protected function configureContainer(ContainerBuilder $c, LoaderInterface $load
'php_errors' => ['log' => true],
'router' => ['utf8' => true],
'http_method_override' => false,
'annotations' => false,
'handle_all_throwables' => true,
'uid' => ['default_uuid_version' => 7, 'time_based_uuid_version' => 7],
];

if (!class_exists(Type::class)) {
$c->setParameter('.json_streamer.lazy_ghosts_dir', __DIR__.'/cache/json_streamer_lazy_ghost');
}

$c->prependExtensionConfig('framework', $config);

$loader->load(__DIR__.'/config.yml');
Expand Down
Loading
Loading