Skip to content

Commit 69ed9b6

Browse files
committed
minor #1133 [Store] Remove unused dev dependencies (OskarStark)
This PR was squashed before being merged into the main branch. Discussion ---------- [Store] Remove unused dev dependencies | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | Docs? | no | Issues | -- | License | MIT The store bridges have their own composer.json with their specific dependencies. The main store package doesn't need these vendor packages in require-dev since it only tests core functionality. Commits ------- f9f07ff [Store] Remove unused dev dependencies
2 parents da3c61a + f9f07ff commit 69ed9b6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+475
-17
lines changed

.github/workflows/code-quality.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,3 +73,11 @@ jobs:
7373
source .github/workflows/.utils.sh
7474
7575
echo "$PACKAGES" | xargs -n1 | parallel -j +3 "_run_task {} '(cd src/{} && $COMPOSER_UP && $PHPSTAN)'"
76+
77+
- name: Run PHPStan on store bridges
78+
run: |
79+
source .github/workflows/.utils.sh
80+
81+
BRIDGES=$(find src/store/src/Bridge/ -mindepth 1 -maxdepth 1 -type d -printf '%f\n' | sort | tr '\n' ' ')
82+
echo "Bridges: $BRIDGES"
83+
echo "$BRIDGES" | xargs -n1 | parallel -j +3 "_run_task {} '(cd src/store/src/Bridge/{} && $COMPOSER_UP && $PHPSTAN)'"

src/store/composer.json

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,21 +49,13 @@
4949
"symfony/uid": "^7.3|^8.0"
5050
},
5151
"require-dev": {
52-
"codewithkyrian/chromadb-php": "^1.0",
53-
"doctrine/dbal": "^3.3|^4.0",
54-
"mongodb/mongodb": "^1.21|^2.0",
5552
"phpstan/phpstan": "^2.0",
5653
"phpstan/phpstan-strict-rules": "^2.0",
5754
"phpunit/phpunit": "^11.5.46",
58-
"probots-io/pinecone-php": "^1.0",
59-
"symfony/cache": "^6.4|^7.1",
6055
"symfony/console": "^6.4|^7.1",
6156
"symfony/dependency-injection": "^6.4|^7.1",
6257
"symfony/dom-crawler": "^6.4|^7.1"
6358
},
64-
"conflict": {
65-
"mongodb/mongodb": "<1.21"
66-
},
6759
"minimum-stability": "dev",
6860
"autoload": {
6961
"psr-4": {

src/store/phpstan.dist.neon

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ parameters:
66
paths:
77
- src/
88
- tests/
9+
excludePaths:
10+
- src/Bridge/
911
treatPhpDocTypesAsCertain: false
1012
ignoreErrors:
1113
-
@@ -14,15 +16,7 @@ parameters:
1416
identifier: missingType.iterableValue
1517
path: tests/*
1618
reportUnmatched: false
17-
-
18-
identifier: missingType.iterableValue
19-
path: src/Bridge/**/Tests/*
20-
reportUnmatched: false
2119
-
2220
identifier: 'symfonyAi.forbidNativeException'
2321
path: tests/*
2422
reportUnmatched: false
25-
-
26-
identifier: 'symfonyAi.forbidNativeException'
27-
path: src/Bridge/**/Tests/*
28-
reportUnmatched: false

src/store/src/Bridge/AzureSearch/composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
"symfony/uid": "^7.3|^8.0"
3434
},
3535
"require-dev": {
36+
"phpstan/phpstan": "^2.0",
37+
"phpstan/phpstan-strict-rules": "^2.0",
3638
"phpunit/phpunit": "^11.5.46"
3739
},
3840
"minimum-stability": "dev",
@@ -43,6 +45,7 @@
4345
},
4446
"autoload-dev": {
4547
"psr-4": {
48+
"Symfony\\AI\\PHPStan\\": "../../../../../.phpstan/",
4649
"Symfony\\AI\\Store\\Bridge\\AzureSearch\\Tests\\": "Tests/"
4750
}
4851
},
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
includes:
2+
- ../../../../../.phpstan/extension.neon
3+
4+
parameters:
5+
level: 6
6+
paths:
7+
- SearchStore.php
8+
treatPhpDocTypesAsCertain: false
9+
ignoreErrors:
10+
-
11+
message: "#^Method .*::test.*\\(\\) has no return type specified\\.$#"
12+
-
13+
identifier: missingType.iterableValue
14+
path: Tests/*
15+
reportUnmatched: false
16+
-
17+
identifier: 'symfonyAi.forbidNativeException'
18+
path: Tests/*
19+
reportUnmatched: false

src/store/src/Bridge/Cache/composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@
3232
"symfony/uid": "^7.3|^8.0"
3333
},
3434
"require-dev": {
35+
"phpstan/phpstan": "^2.0",
36+
"phpstan/phpstan-strict-rules": "^2.0",
3537
"phpunit/phpunit": "^11.5.46"
3638
},
3739
"minimum-stability": "dev",
@@ -42,6 +44,7 @@
4244
},
4345
"autoload-dev": {
4446
"psr-4": {
47+
"Symfony\\AI\\PHPStan\\": "../../../../../.phpstan/",
4548
"Symfony\\AI\\Store\\Bridge\\Cache\\Tests\\": "Tests/"
4649
}
4750
},
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
includes:
2+
- ../../../../../.phpstan/extension.neon
3+
4+
parameters:
5+
level: 6
6+
paths:
7+
- Store.php
8+
treatPhpDocTypesAsCertain: false
9+
ignoreErrors:
10+
-
11+
message: "#^Method .*::test.*\\(\\) has no return type specified\\.$#"
12+
-
13+
identifier: missingType.iterableValue
14+
path: Tests/*
15+
reportUnmatched: false
16+
-
17+
identifier: 'symfonyAi.forbidNativeException'
18+
path: Tests/*
19+
reportUnmatched: false

src/store/src/Bridge/ChromaDb/composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@
3232
"symfony/uid": "^7.3|^8.0"
3333
},
3434
"require-dev": {
35+
"phpstan/phpstan": "^2.0",
36+
"phpstan/phpstan-strict-rules": "^2.0",
3537
"phpunit/phpunit": "^11.5.46"
3638
},
3739
"minimum-stability": "dev",
@@ -42,6 +44,7 @@
4244
},
4345
"autoload-dev": {
4446
"psr-4": {
47+
"Symfony\\AI\\PHPStan\\": "../../../../../.phpstan/",
4548
"Symfony\\AI\\Store\\Bridge\\ChromaDb\\Tests\\": "Tests/"
4649
}
4750
},
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
includes:
2+
- ../../../../../.phpstan/extension.neon
3+
4+
parameters:
5+
level: 6
6+
paths:
7+
- Store.php
8+
treatPhpDocTypesAsCertain: false
9+
ignoreErrors:
10+
-
11+
message: "#^Method .*::test.*\\(\\) has no return type specified\\.$#"
12+
-
13+
identifier: missingType.iterableValue
14+
path: Tests/*
15+
reportUnmatched: false
16+
-
17+
identifier: 'symfonyAi.forbidNativeException'
18+
path: Tests/*
19+
reportUnmatched: false

src/store/src/Bridge/ClickHouse/composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@
3232
"symfony/uid": "^7.3|^8.0"
3333
},
3434
"require-dev": {
35+
"phpstan/phpstan": "^2.0",
36+
"phpstan/phpstan-strict-rules": "^2.0",
3537
"phpunit/phpunit": "^11.5.46"
3638
},
3739
"minimum-stability": "dev",
@@ -42,6 +44,7 @@
4244
},
4345
"autoload-dev": {
4446
"psr-4": {
47+
"Symfony\\AI\\PHPStan\\": "../../../../../.phpstan/",
4548
"Symfony\\AI\\Store\\Bridge\\ClickHouse\\Tests\\": "Tests/"
4649
}
4750
},

0 commit comments

Comments
 (0)