Skip to content

Commit

Permalink
Merge pull request #74 from ray-di/dep-ver
Browse files Browse the repository at this point in the history
Update dependency and PHP version for enhanced compatibility
  • Loading branch information
koriym authored Jan 22, 2025
2 parents 2982707 + 9f21e05 commit 13044e7
Show file tree
Hide file tree
Showing 12 changed files with 618 additions and 575 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/coding-standards.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ jobs:
cs:
uses: ray-di/.github/.github/workflows/coding-standards.yml@v1
with:
php_version: 8.1
php_version: 8.3
2 changes: 1 addition & 1 deletion .github/workflows/static-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ jobs:
sa:
uses: ray-di/.github/.github/workflows/static-analysis.yml@v1
with:
php_version: 8.1
php_version: 8.3
has_crc_config: false
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
"aura/sql": "^4.0 || ^5.0",
"aura/sqlquery": "^2.7.1 || 3.x-dev",
"pagerfanta/pagerfanta": "^3.5",
"rize/uri-template": "^0.3.4",
"doctrine/annotations": "^1.11",
"rize/uri-template": "^0.3.4 || ^0.4",
"doctrine/annotations": "^1.11 || ^2.0",
"psr/log": "^1.1 || ^2.0 || ^3.0",
"symfony/polyfill-php81": "^1.24"
},
Expand Down Expand Up @@ -52,7 +52,7 @@
"cs": ["phpcs --standard=./phpcs.xml src tests"],
"cs-fix": ["./vendor/bin/phpcbf src tests"],
"clean": ["./vendor/bin/phpstan clear-result-cache", "./vendor/bin/psalm --clear-cache", "rm -rf tests/tmp/*.php"],
"sa": ["./vendor/bin/phpstan analyse -c phpstan.neon", "psalm --show-info=true"],
"sa": ["./vendor/bin/phpstan analyse -c phpstan.neon", "psalm --show-info=false"],
"metrics": ["./vendor/bin/phpmetrics --report-html=build/metrics --exclude=Exception --log-junit=build/junit.xml --junit=build/junit.xml src"],
"phpmd": ["./vendor/bin/phpmd src text ./phpmd.xml"],
"build": ["@cs", "@sa", "@pcov", "@metrics"]
Expand Down
4 changes: 2 additions & 2 deletions src-deprecated/Annotation/AuraSqlConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@
namespace Ray\AuraSqlModule\Annotation;

use Attribute;
use Doctrine\Common\Annotations\NamedArgumentConstructorAnnotation;
use Ray\Di\Di\Qualifier;

/**
* @Annotation
* @Target("METHOD")
* @Qualifier
* @deprecated -- No one using?
* @NamedArgumentConstructor
*/
#[Attribute(Attribute::TARGET_METHOD), Qualifier]
final class AuraSqlConfig implements NamedArgumentConstructorAnnotation
final class AuraSqlConfig
{
/** @var ?array<string> */
public $value;
Expand Down
4 changes: 2 additions & 2 deletions src-deprecated/Annotation/Write.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@
namespace Ray\AuraSqlModule\Annotation;

use Attribute;
use Doctrine\Common\Annotations\NamedArgumentConstructorAnnotation;
use Ray\Di\Di\Qualifier;

/**
* @Annotation
* @Target("METHOD")
* @Qualifier
* @deprecated -- No one using?
* @NamedArgumentConstructor
*/
#[Attribute(Attribute::TARGET_METHOD), Qualifier]
final class Write implements NamedArgumentConstructorAnnotation
final class Write
{
/** @var string */
public $value;
Expand Down
5 changes: 3 additions & 2 deletions src/Annotation/AuraSqlQueryConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,17 @@
namespace Ray\AuraSqlModule\Annotation;

use Attribute;
use Doctrine\Common\Annotations\NamedArgumentConstructorAnnotation;
use Doctrine\Common\Annotations\Annotation\NamedArgumentConstructor;
use Ray\Di\Di\Qualifier;

/**
* @Annotation
* @Target("METHOD")
* @Qualifier
* @NamedArgumentConstructor
*/
#[Attribute(Attribute::TARGET_METHOD), Qualifier]
final class AuraSqlQueryConfig implements NamedArgumentConstructorAnnotation
final class AuraSqlQueryConfig
{
/** @var ?array<string, string> */
public $value;
Expand Down
5 changes: 3 additions & 2 deletions src/Annotation/PagerViewOption.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,17 @@
namespace Ray\AuraSqlModule\Annotation;

use Attribute;
use Doctrine\Common\Annotations\NamedArgumentConstructorAnnotation;
use Doctrine\Common\Annotations\Annotation\NamedArgumentConstructor;
use Ray\Di\Di\Qualifier;

/**
* @Annotation
* @Target("METHOD")
* @Qualifier
* @NamedArgumentConstructor()
*/
#[Attribute(Attribute::TARGET_METHOD), Qualifier]
final class PagerViewOption implements NamedArgumentConstructorAnnotation
final class PagerViewOption
{
/** @var string */
public $value;
Expand Down
5 changes: 3 additions & 2 deletions src/Annotation/Read.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,17 @@
namespace Ray\AuraSqlModule\Annotation;

use Attribute;
use Doctrine\Common\Annotations\NamedArgumentConstructorAnnotation;
use Doctrine\Common\Annotations\Annotation\NamedArgumentConstructor;
use Ray\Di\Di\Qualifier;

/**
* @Annotation
* @Target("METHOD")
* @Qualifier
* @NamedArgumentConstructor
*/
#[Attribute(Attribute::TARGET_METHOD), Qualifier]
final class Read implements NamedArgumentConstructorAnnotation
final class Read
{
/** @var string */
public $value;
Expand Down
5 changes: 3 additions & 2 deletions src/Annotation/Transactional.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@
namespace Ray\AuraSqlModule\Annotation;

use Attribute;
use Doctrine\Common\Annotations\NamedArgumentConstructorAnnotation;
use Doctrine\Common\Annotations\Annotation\NamedArgumentConstructor;

/**
* @Annotation
* @Target("METHOD")
* @NamedArgumentConstructor()
*/
#[Attribute(Attribute::TARGET_METHOD)]
final class Transactional implements NamedArgumentConstructorAnnotation
final class Transactional
{
/**
* @var ?array<string>
Expand Down
1 change: 1 addition & 0 deletions src/AuraSqlConnectionInterceptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ public function invoke(MethodInvocation $invocation)
return $invocation->proceed();
}

/** @param MethodInvocation<object> $invocation */
private function getConnection(MethodInvocation $invocation): ExtendedPdoInterface
{
$methodName = $invocation->getMethod()->name;
Expand Down
2 changes: 1 addition & 1 deletion src/Pagerfanta/AuraSqlQueryPager.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public function offsetGet($page): Page
throw new NotInitialized();
}

$countQueryBuilderModifier = static function (Select $select) {
$countQueryBuilderModifier = static function (Select $select): Select {
foreach (array_keys($select->getCols()) as $key) {
$select->removeCol($key);
}
Expand Down
Loading

0 comments on commit 13044e7

Please sign in to comment.