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

Force composer to search package with compatibility #143

Merged
merged 10 commits into from
Jan 17, 2024
2 changes: 1 addition & 1 deletion .github/workflows/quality.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
run: |
wget -q https://cs.symfony.com/download/php-cs-fixer-v3.phar -O php-cs-fixer
chmod a+x php-cs-fixer
PHP_CS_FIXER_IGNORE_ENV=true ./php-cs-fixer fix src --dry-run
./php-cs-fixer fix src --dry-run
phpstan:
runs-on: ubuntu-latest
Expand Down
5 changes: 2 additions & 3 deletions rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
declare(strict_types=1);

use Rector\CodeQuality\Rector\Class_\InlineConstructorDefaultToPropertyRector;
use Rector\CodingStyle\Rector\String_\UseClassKeywordForClassNameResolutionRector;
use Rector\Config\RectorConfig;
use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector;
use Rector\Set\ValueObject\LevelSetList;
Expand All @@ -22,7 +23,5 @@
SymfonyLevelSetList::UP_TO_SYMFONY_60,
]);

$rectorConfig->skip([
StringClassNameToClassConstantRector::class
]);
$rectorConfig->skip([StringClassNameToClassConstantRector::class]);
};
2 changes: 1 addition & 1 deletion src/Action/SFTP/Builder/Action.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

final class Action implements ActionBuilderInterface
{
private ?Node\Expr $logger = null;

Check failure on line 11 in src/Action/SFTP/Builder/Action.php

View workflow job for this annotation

GitHub Actions / phpstan6

Property Kiboko\Component\Satellite\Action\SFTP\Builder\Action::$logger is never read, only written.

Check failure on line 11 in src/Action/SFTP/Builder/Action.php

View workflow job for this annotation

GitHub Actions / phpstan5

Property Kiboko\Component\Satellite\Action\SFTP\Builder\Action::$logger is never read, only written.
private ?Node\Expr $state = null;

Check failure on line 12 in src/Action/SFTP/Builder/Action.php

View workflow job for this annotation

GitHub Actions / phpstan6

Property Kiboko\Component\Satellite\Action\SFTP\Builder\Action::$state is never read, only written.

Check failure on line 12 in src/Action/SFTP/Builder/Action.php

View workflow job for this annotation

GitHub Actions / phpstan5

Property Kiboko\Component\Satellite\Action\SFTP\Builder\Action::$state is never read, only written.

public function __construct(
private readonly Node\Expr $host,
Expand Down Expand Up @@ -38,7 +38,7 @@
public function getNode(): Node
{
return new Node\Expr\New_(
class: new Node\Name\FullyQualified('Kiboko\Component\Action\Flow\SFTP\UploadFile'),
class: new Node\Name\FullyQualified('Kiboko\\Component\\Action\\Flow\\SFTP\\UploadFile'),
args: [
new Node\Arg(
value: $this->host,
Expand Down
2 changes: 1 addition & 1 deletion src/Feature/Rejection/Builder/Rejection.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function withRejection(Node\Expr $rejection): void
private static function nullRejection(): Node\Expr
{
return new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullRejection::class)
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullRejection')
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function __construct(private readonly Rejection\Builder\RabbitMQBuilder $
{
$this->files = [];
$this->packages = [
'php-etl/rabbitmq-flow',
'php-etl/rabbitmq-flow:*',
];
}

Expand Down
4 changes: 2 additions & 2 deletions src/Pipeline/Loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$rejection = $compiled->getBuilder()->getNode();
} else {
$rejection = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepRejection::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepRejection'),
);
}

Expand All @@ -62,7 +62,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$state = $compiled->getBuilder()->getNode();
} else {
$state = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepState::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepState'),
);
}

Expand Down
4 changes: 2 additions & 2 deletions src/Pipeline/Transformer.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$rejection = $compiled->getBuilder()->getNode();
} else {
$rejection = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepRejection::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepRejection'),
);
}

Expand All @@ -62,7 +62,7 @@ public function __invoke(array $config, Pipeline $pipeline, StepRepositoryInterf
$state = $compiled->getBuilder()->getNode();
} else {
$state = new Node\Expr\New_(
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\NullStepState::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\NullStepState'),
);
}

Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/Batching/Builder/Fork.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface::class'),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
],
'stmts' => [
new Node\Stmt\ClassMethod(
Expand Down
6 changes: 3 additions & 3 deletions src/Plugin/Batching/Builder/Merge.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\TransformerInterface::class),
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\FlushableInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\FlushableInterface'),
],
'stmts' => [
new Node\Stmt\Property(
Expand Down Expand Up @@ -226,7 +226,7 @@ class: new Node\Name\FullyQualified('Kiboko\\Component\\Bucket\\AcceptanceResult
)
),
],
'returnType' => new Node\Name\FullyQualified(\Kiboko\Contract\Bucket\ResultBucketInterface::class),
'returnType' => new Node\Name\FullyQualified('Kiboko\\Contract\\Bucket\\ResultBucketInterface'),
],
),
],
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/Filtering/Builder/Drop.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function getNode(): Node
return new Node\Expr\New_(
class: new Node\Stmt\Class_(null, [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\TransformerInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
],
'stmts' => [
(new Builder\Method('transform'))
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/Filtering/Builder/Reject.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function getNode(): Node
return new Node\Expr\New_(
class: new Node\Stmt\Class_(null, [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\TransformerInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\TransformerInterface'),
],
'stmts' => [
(new Builder\Method('transform'))
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/SFTP/Builder/Extractor.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\LoaderInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\LoaderInterface'),
],
'stmts' => [
new Node\Stmt\ClassMethod(
Expand Down
2 changes: 1 addition & 1 deletion src/Plugin/SFTP/Builder/Loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ class: new Node\Stmt\Class_(
name: null,
subNodes: [
'implements' => [
new Node\Name\FullyQualified(\Kiboko\Contract\Pipeline\LoaderInterface::class),
new Node\Name\FullyQualified('Kiboko\\Contract\\Pipeline\\LoaderInterface'),
],
'stmts' => [
new Node\Stmt\ClassMethod(
Expand Down
Loading