Skip to content

Uupdate api-platform/core 3.2.6 error #5998

@Napalm4577

Description

@Napalm4577

API Platform version(s) affected: 3.2.6

Description

I have a project on Symfony 6.3. I updated with composer, the library "api-platform/core" from 3.2.5 to 3.2.6 and I get error "'Warning: Undefined array key '$ref'" when I try to display the page /api

How to reproduce

Update library from 3.2.5 to 3.2.6 with composer

Possible Solution

Additional Context

{
  "@context": "\/api\/contexts\/Error",
  "@type": "hydra:Error",
  "hydra:title": "An error occurred",
  "hydra:description": "Warning: Undefined array key \u0022$ref\u0022",
  "trace": [
    {
      "namespace": "",
      "short_class": "",
      "class": "",
      "type": "",
      "function": "",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/JsonSchema\/SchemaFactory.php",
      "line": 227,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\JsonSchema",
      "short_class": "SchemaFactory",
      "class": "ApiPlatform\\JsonSchema\\SchemaFactory",
      "type": "-\u003E",
      "function": "buildPropertySchema",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/JsonSchema\/SchemaFactory.php",
      "line": 142,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\JsonSchema",
      "short_class": "SchemaFactory",
      "class": "ApiPlatform\\JsonSchema\\SchemaFactory",
      "type": "-\u003E",
      "function": "buildSchema",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Hydra\/JsonSchema\/SchemaFactory.php",
      "line": 70,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Hydra\\JsonSchema",
      "short_class": "SchemaFactory",
      "class": "ApiPlatform\\Hydra\\JsonSchema\\SchemaFactory",
      "type": "-\u003E",
      "function": "buildSchema",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/OpenApi\/Factory\/OpenApiFactory.php",
      "line": 353,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\OpenApi\\Factory",
      "short_class": "OpenApiFactory",
      "class": "ApiPlatform\\OpenApi\\Factory\\OpenApiFactory",
      "type": "-\u003E",
      "function": "collectPaths",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/OpenApi\/Factory\/OpenApiFactory.php",
      "line": 97,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\OpenApi\\Factory",
      "short_class": "OpenApiFactory",
      "class": "ApiPlatform\\OpenApi\\Factory\\OpenApiFactory",
      "type": "-\u003E",
      "function": "__invoke",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Symfony\/Bundle\/SwaggerUi\/SwaggerUiProvider.php",
      "line": 75,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Symfony\\Bundle\\SwaggerUi",
      "short_class": "SwaggerUiProvider",
      "class": "ApiPlatform\\Symfony\\Bundle\\SwaggerUi\\SwaggerUiProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Symfony\/Security\/State\/AccessCheckerProvider.php",
      "line": 53,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Symfony\\Security\\State",
      "short_class": "AccessCheckerProvider",
      "class": "ApiPlatform\\Symfony\\Security\\State\\AccessCheckerProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/State\/Provider\/DeserializeProvider.php",
      "line": 47,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\State\\Provider",
      "short_class": "DeserializeProvider",
      "class": "ApiPlatform\\State\\Provider\\DeserializeProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Symfony\/Security\/State\/AccessCheckerProvider.php",
      "line": 53,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Symfony\\Security\\State",
      "short_class": "AccessCheckerProvider",
      "class": "ApiPlatform\\Symfony\\Security\\State\\AccessCheckerProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Symfony\/Validator\/State\/QueryParameterValidateProvider.php",
      "line": 42,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Symfony\\Validator\\State",
      "short_class": "QueryParameterValidateProvider",
      "class": "ApiPlatform\\Symfony\\Validator\\State\\QueryParameterValidateProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Symfony\/Validator\/State\/ValidateProvider.php",
      "line": 32,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Symfony\\Validator\\State",
      "short_class": "ValidateProvider",
      "class": "ApiPlatform\\Symfony\\Validator\\State\\ValidateProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Symfony\/Security\/State\/AccessCheckerProvider.php",
      "line": 53,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Symfony\\Security\\State",
      "short_class": "AccessCheckerProvider",
      "class": "ApiPlatform\\Symfony\\Security\\State\\AccessCheckerProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/State\/Provider\/ContentNegotiationProvider.php",
      "line": 56,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\State\\Provider",
      "short_class": "ContentNegotiationProvider",
      "class": "ApiPlatform\\State\\Provider\\ContentNegotiationProvider",
      "type": "-\u003E",
      "function": "provide",
      "file": "\/var\/www\/isia-core\/vendor\/api-platform\/core\/src\/Documentation\/Action\/EntrypointAction.php",
      "line": 48,
      "args": []
    },
    {
      "namespace": "ApiPlatform\\Documentation\\Action",
      "short_class": "EntrypointAction",
      "class": "ApiPlatform\\Documentation\\Action\\EntrypointAction",
      "type": "-\u003E",
      "function": "__invoke",
      "file": "\/var\/www\/isia-core\/vendor\/symfony\/http-kernel\/HttpKernel.php",
      "line": 181,
      "args": []
    },
    {
      "namespace": "Symfony\\Component\\HttpKernel",
      "short_class": "HttpKernel",
      "class": "Symfony\\Component\\HttpKernel\\HttpKernel",
      "type": "-\u003E",
      "function": "handleRaw",
      "file": "\/var\/www\/isia-core\/vendor\/symfony\/http-kernel\/HttpKernel.php",
      "line": 76,
      "args": []
    },
    {
      "namespace": "Symfony\\Component\\HttpKernel",
      "short_class": "HttpKernel",
      "class": "Symfony\\Component\\HttpKernel\\HttpKernel",
      "type": "-\u003E",
      "function": "handle",
      "file": "\/var\/www\/isia-core\/vendor\/symfony\/http-kernel\/Kernel.php",
      "line": 197,
      "args": []
    },
    {
      "namespace": "Symfony\\Component\\HttpKernel",
      "short_class": "Kernel",
      "class": "Symfony\\Component\\HttpKernel\\Kernel",
      "type": "-\u003E",
      "function": "handle",
      "file": "\/var\/www\/isia-core\/public\/app_dev.php",
      "line": 28,
      "args": []
    }
  ]
}

Thanks guys

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions