Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Maintenance #389

Merged
merged 4 commits into from
Oct 23, 2024
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
3 changes: 0 additions & 3 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,4 @@
/phpcs.xml.dist export-ignore
/phpstan.neon export-ignore
/phpstan-baseline.neon export-ignore
/psalm.xml export-ignore
/psalm-baseline.xml export-ignore
/psalm.phpstub export-ignore
/composer.lock export-ignore
2 changes: 1 addition & 1 deletion .github/workflows/static-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ on:
jobs:
static-analysis:
name: "Static Analysis"
uses: "doctrine/.github/.github/workflows/static-analysis[email protected]"
uses: "doctrine/.github/.github/workflows/phpstan[email protected]"
with:
composer-root-version: "3.0"
5 changes: 2 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,13 @@
"psr/cache": "^1.0 || ^2.0 || ^3.0"
},
"require-dev": {
"phpstan/phpstan": "1.11.1",
"phpstan/phpstan": "1.12.7",
"phpstan/phpstan-phpunit": "^1",
"phpstan/phpstan-strict-rules": "^1.1",
"doctrine/coding-standard": "^12",
"doctrine/common": "^3.0",
"phpunit/phpunit": "^8.5 || ^9.5",
"symfony/cache": "^4.4 || ^5.4 || ^6.0",
"vimeo/psalm": "4.30.0 || 5.24.0"
"symfony/cache": "^4.4 || ^5.4 || ^6.0 || ^7.0"
},
"conflict": {
"doctrine/common": "<2.10"
Expand Down
24 changes: 0 additions & 24 deletions psalm-baseline.xml

This file was deleted.

12 changes: 0 additions & 12 deletions psalm.phpstub

This file was deleted.

72 changes: 0 additions & 72 deletions psalm.xml

This file was deleted.

6 changes: 3 additions & 3 deletions src/Persistence/AbstractManagerRegistry.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ abstract class AbstractManagerRegistry implements ManagerRegistry

/**
* @var string
* @psalm-var class-string
* @phpstan-var class-string
*/
private $proxyInterfaceName;

/**
* @param array<string, string> $connections
* @param array<string, string> $managers
* @psalm-param class-string $proxyInterfaceName
* @phpstan-param class-string $proxyInterfaceName
*/
public function __construct(
string $name,
Expand Down Expand Up @@ -255,7 +255,7 @@ public function resetManager(?string $name = null)
return $this->getManager($name);
}

/** @psalm-param class-string $persistentObject */
/** @phpstan-param class-string $persistentObject */
private function selectManager(
string $persistentObject,
?string $persistentManagerName = null
Expand Down
6 changes: 3 additions & 3 deletions src/Persistence/Event/LifecycleEventArgs.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ class LifecycleEventArgs extends EventArgs
{
/**
* @var ObjectManager
* @psalm-var TObjectManager
* @phpstan-var TObjectManager
*/
private $objectManager;

/** @var object */
private $object;

/** @psalm-param TObjectManager $objectManager */
/** @phpstan-param TObjectManager $objectManager */
public function __construct(object $object, ObjectManager $objectManager)
{
$this->object = $object;
Expand All @@ -45,7 +45,7 @@ public function getObject()
* Retrieves the associated ObjectManager.
*
* @return ObjectManager
* @psalm-return TObjectManager
* @phpstan-return TObjectManager
*/
public function getObjectManager()
{
Expand Down
10 changes: 5 additions & 5 deletions src/Persistence/Event/LoadClassMetadataEventArgs.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@ class LoadClassMetadataEventArgs extends EventArgs
{
/**
* @var ClassMetadata
* @psalm-var TClassMetadata
* @phpstan-var TClassMetadata
*/
private $classMetadata;

/**
* @var ObjectManager
* @psalm-var TObjectManager
* @phpstan-var TObjectManager
*/
private $objectManager;

/**
* @psalm-param TClassMetadata $classMetadata
* @psalm-param TObjectManager $objectManager
* @phpstan-param TClassMetadata $classMetadata
* @phpstan-param TObjectManager $objectManager
*/
public function __construct(ClassMetadata $classMetadata, ObjectManager $objectManager)
{
Expand All @@ -42,7 +42,7 @@ public function __construct(ClassMetadata $classMetadata, ObjectManager $objectM
* Retrieves the associated ClassMetadata.
*
* @return ClassMetadata
* @psalm-return TClassMetadata
* @phpstan-return TClassMetadata
*/
public function getClassMetadata()
{
Expand Down
6 changes: 3 additions & 3 deletions src/Persistence/Event/ManagerEventArgs.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ class ManagerEventArgs extends EventArgs
{
/**
* @var ObjectManager
* @psalm-var TObjectManager
* @phpstan-var TObjectManager
*/
private $objectManager;

/** @psalm-param TObjectManager $objectManager */
/** @phpstan-param TObjectManager $objectManager */
public function __construct(ObjectManager $objectManager)
{
$this->objectManager = $objectManager;
Expand All @@ -30,7 +30,7 @@ public function __construct(ObjectManager $objectManager)
* Retrieves the associated ObjectManager.
*
* @return ObjectManager
* @psalm-return TObjectManager
* @phpstan-return TObjectManager
*/
public function getObjectManager()
{
Expand Down
6 changes: 3 additions & 3 deletions src/Persistence/Event/OnClearEventArgs.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ class OnClearEventArgs extends EventArgs
{
/**
* @var ObjectManager
* @psalm-var TObjectManager
* @phpstan-var TObjectManager
*/
private $objectManager;

/**
* @param ObjectManager $objectManager The object manager.
* @psalm-param TObjectManager $objectManager
* @phpstan-param TObjectManager $objectManager
*/
public function __construct(ObjectManager $objectManager)
{
Expand All @@ -33,7 +33,7 @@ public function __construct(ObjectManager $objectManager)
* Retrieves the associated ObjectManager.
*
* @return ObjectManager
* @psalm-return TObjectManager
* @phpstan-return TObjectManager
*/
public function getObjectManager()
{
Expand Down
2 changes: 1 addition & 1 deletion src/Persistence/Event/PreUpdateEventArgs.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class PreUpdateEventArgs extends LifecycleEventArgs

/**
* @param array<string, array<int, mixed>> $changeSet
* @psalm-param TObjectManager $objectManager
* @phpstan-param TObjectManager $objectManager
*/
public function __construct(object $entity, ObjectManager $objectManager, array &$changeSet)
{
Expand Down
4 changes: 2 additions & 2 deletions src/Persistence/ManagerRegistry.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,10 @@ public function getManagerNames();
*
* @param string $persistentObject The name of the persistent object.
* @param string|null $persistentManagerName The object manager name (null for the default one).
* @psalm-param class-string<T> $persistentObject
* @phpstan-param class-string<T> $persistentObject
*
* @return ObjectRepository
* @psalm-return ObjectRepository<T>
* @phpstan-return ObjectRepository<T>
*
* @template T of object
*/
Expand Down
Loading