Skip to content

Commit b74f88e

Browse files
lepiafNyholm
andauthored
Add support for PHP 8 (#424)
* Add support for PHP 8 * Fix phpstan * Exclude Translator/TranslatorInterface.php from phpstan analysis I don't know how to manage this error ``` % make phpstan 2 ↵ ✹ Note: Using configuration file /project/phpstan.neon.dist. 49/49 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓] 100% ------ ---------------------------------------------------------------------- Line Translator/TranslatorInterface.php ------ ---------------------------------------------------------------------- 31 Interface Translation\Bundle\Translator\TranslatorInterface extends unknown interface Symfony\Component\Translation\TranslatorInterface. 💡 Learn more at https://phpstan.org/user-guide/discovering-symbols ------ ---------------------------------------------------------------------- -- ------------------------------------------------------------------------- Error -- ------------------------------------------------------------------------- Error message "Interface Translation\Bundle\Translator\TranslatorInterface extends unknown interface Symfony\Component\Translation\TranslatorInterface." cannot be ignored, use excludes_analyse instead. -- ------------------------------------------------------------------------- ``` * Increase lowest version Co-authored-by: Nyholm <tobias.nyholm@gmail.com>
1 parent b38026e commit b74f88e

File tree

2 files changed

+17
-15
lines changed

2 files changed

+17
-15
lines changed

composer.json

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -10,31 +10,31 @@
1010
}
1111
],
1212
"require": {
13-
"php": "^7.2",
14-
"symfony/framework-bundle": "^3.4 || ^4.3 || ^5.0",
15-
"symfony/validator": "^3.4 || ^4.3 || ^5.0",
16-
"symfony/translation": "^3.4 || ^4.3 || ^5.0",
17-
"symfony/twig-bundle": "^3.4 || ^4.3 || ^5.0",
18-
"symfony/finder": "^3.4 || ^4.3 || ^5.0",
19-
"symfony/intl": "^3.4 || ^4.3 || ^5.0",
13+
"php": "^7.2 || ^8.0",
14+
"symfony/framework-bundle": "^3.4.47 || ^4.4.20 || ^5.2.5",
15+
"symfony/validator": "^3.4.47 || ^4.4.20 || ^5.2.5",
16+
"symfony/translation": "^3.4.47 || ^4.4.20 || ^5.2.5",
17+
"symfony/twig-bundle": "^3.4.47 || ^4.4.20 || ^5.2.5",
18+
"symfony/finder": "^3.4.47 || ^4.4.20 || ^5.2.5",
19+
"symfony/intl": "^3.4.47 || ^4.4.20 || ^5.2.5",
2020

2121
"php-translation/symfony-storage": "^2.1",
2222
"php-translation/extractor": "^2.0",
2323
"nyholm/nsa": "^1.1",
24-
"twig/twig": "^2.11 || ^3.0"
24+
"twig/twig": "^2.14.4 || ^3.3"
2525
},
2626
"require-dev": {
2727
"symfony/phpunit-bridge": "^5.2",
2828
"bamarni/composer-bin-plugin": "^1.3",
2929
"php-translation/translator": "^1.0",
30-
"php-http/curl-client": "^1.7",
31-
"php-http/message": "^1.6",
30+
"php-http/curl-client": "^1.7 || ^2.0",
31+
"php-http/message": "^1.11",
3232
"php-http/message-factory": "^1.0.2",
33-
"symfony/console": "^3.4 || ^4.3 || ^5.0",
34-
"symfony/twig-bridge": "^3.4 || ^4.3 || ^5.0",
35-
"symfony/asset": "^3.4 || ^4.3 || ^5.0",
36-
"symfony/dependency-injection": "^3.4 || ^4.3 || ^5.0",
37-
"symfony/web-profiler-bundle": "^3.4 || ^4.3 || ^5.0",
33+
"symfony/console": "^3.4.47 || ^4.4.20 || ^5.2.5",
34+
"symfony/twig-bridge": "^3.4.47 || ^4.4.20 || ^5.2.5",
35+
"symfony/asset": "^3.4.47 || ^4.4.20 || ^5.2.5",
36+
"symfony/dependency-injection": "^3.4.47 || ^4.4.20 || ^5.2.5",
37+
"symfony/web-profiler-bundle": "^3.4.47 || ^4.4.20 || ^5.2.5",
3838
"matthiasnoback/symfony-dependency-injection-test": "^4.1",
3939
"matthiasnoback/symfony-config-test": "^4.1",
4040
"nyholm/psr7": "^1.1",

phpstan-baseline.neon

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,3 +145,5 @@ parameters:
145145
count: 2
146146
path: Twig/TranslationExtension.php
147147

148+
excludes_analyse:
149+
- Translator/TranslatorInterface.php

0 commit comments

Comments
 (0)