Skip to content

Commit b767494

Browse files
committed
Revert "Make all checks pass"
This reverts commit 45fae3a.
1 parent 6ed6be0 commit b767494

5 files changed

Lines changed: 10 additions & 24 deletions

File tree

code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ protected function getFieldTypeIdentifier(): string
1515
return 'my_field_type';
1616
}
1717

18-
#[\Override]
1918
public function mapToFieldValueInputType(ContentType $contentType, FieldDefinition $fieldDefinition): ?string
2019
{
2120
if (!$this->canMap($fieldDefinition)) {

code_samples/catalog/custom_catalog_filter/src/CatalogFilter/DataTransformer/ProductNameCriterionTransformer.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,6 @@
88
use Symfony\Component\Form\DataTransformerInterface;
99
use Symfony\Component\Form\Exception\TransformationFailedException;
1010

11-
/**
12-
* @implements \Symfony\Component\Form\DataTransformerInterface<
13-
* \Ibexa\Contracts\ProductCatalog\Values\Product\Query\Criterion\ProductName,
14-
* \Ibexa\Bundle\ProductCatalog\Form\Data\Catalog\CatalogFilterPriceData
15-
* >
16-
*/
1711
final class ProductNameCriterionTransformer implements DataTransformerInterface
1812
{
1913
public function transform($value): ?string

deptrac.baseline.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ deptrac:
174174
- Ibexa\Bundle\Checkout\Form\Type\AddressType
175175
- Ibexa\Bundle\Payment\Form\Type\PaymentMethodChoiceType
176176
- Ibexa\Bundle\Shipping\Form\Type\ShippingMethodChoiceType
177-
App\GraphQL\Schema\MyFieldDefinitionMapper:
177+
App\GraphQL\Schema\MyCustomFieldDefinitionMapper:
178178
- Ibexa\GraphQL\Schema\Domain\Content\Mapper\FieldDefinition\DecoratingFieldDefinitionMapper
179179
App\Migrations\Action\AssignSection:
180180
- Ibexa\Migration\ValueObject\Step\Action

docs/api/graphql/graphql_custom_ft.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ If not specified, it uses `FieldDefinition`.
4040

4141
Compiler pass example that should be placed in `src/DependencyInjection/Compiler`:
4242

43-
``` php skip-validation
43+
``` php
4444
[[= include_file('code_samples/api/graphql/src/DependencyInjection/Compiler/MyCustomTypeGraphQLCompilerPass.php') =]]
4545
```
4646

@@ -60,8 +60,7 @@ It requires that you implement the `getFieldTypeIdentifier` method to tell which
6060
Add `MyFieldDefinitionMapper.php` mapper to `src/GraphQL/Schema`:
6161

6262
``` php
63-
[[= include_code('code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php', 1, 17) =]]
64-
[[= include_code('code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php', 38, 39) =]]
63+
[[= include_file('code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php', 0, 16) =]][[= include_file('code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php', 36, 37) =]]
6564
```
6665

6766
The `FieldDefinitionMapper` interface defines following methods:
@@ -76,7 +75,7 @@ When a mapper method is decorated, you need to call the decorated service method
7675
To do that, you need to replace `mapXXX` by the method it's in:
7776

7877
```php
79-
[[= include_code('code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php', 21, 24, remove_indent=True) =]]
78+
[[= include_file('code_samples/api/graphql/src/GraphQL/Schema/MyFieldDefinitionMapper.php', 19, 22, remove_indent=True) =]]
8079
```
8180

8281
It's required for every implemented method, so that other mappers are called for the other field types.

phpstan-baseline.neon

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,6 @@ parameters:
3030
count: 1
3131
path: code_samples/api/migration/src/Command/MigrationCommand.php
3232

33-
-
34-
message: '#^Instantiated class App\\Notifications\\MyNotification not found\.$#'
35-
identifier: class.notFound
36-
count: 1
37-
path: code_samples/api/notifications/notification_send.php
38-
39-
-
40-
message: '#^Parameter \#1 \$notification of class Ibexa\\Contracts\\Notifications\\Value\\Notification\\SymfonyNotificationAdapter constructor expects Symfony\\Component\\Notifier\\Notification\\Notification, App\\Notifications\\MyNotification given\.$#'
41-
identifier: argument.type
42-
count: 1
43-
path: code_samples/api/notifications/notification_send.php
44-
4533
-
4634
message: '#^Call to an undefined method Ibexa\\Contracts\\ProductCatalog\\Values\\ProductInterface\:\:getPrice\(\)\.$#'
4735
identifier: method.notFound
@@ -324,6 +312,12 @@ parameters:
324312
count: 1
325313
path: code_samples/catalog/custom_attribute_type/src/Attribute/Percent/Storage/PercentStorageConverter.php
326314

315+
-
316+
message: '#^Class App\\CatalogFilter\\DataTransformer\\ProductNameCriterionTransformer implements generic interface Symfony\\Component\\Form\\DataTransformerInterface but does not specify its types\: T, R$#'
317+
identifier: missingType.generics
318+
count: 1
319+
path: code_samples/catalog/custom_catalog_filter/src/CatalogFilter/DataTransformer/ProductNameCriterionTransformer.php
320+
327321
-
328322
message: '#^Method App\\CatalogFilter\\ProductNameFilter\:\:getTranslationMessages\(\) return type has no value type specified in iterable type array\.$#'
329323
identifier: missingType.iterableValue

0 commit comments

Comments
 (0)