Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-30419

GraphQL schema generation fails if content type is in multiple groups

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 2.5.0
    • Fix Version/s: 2.5.1
    • Component/s: Platform > GraphQL
    • Labels:

      Description

      In eZ Publish you could place a single content type (content class) in multiple groups. Currently this is not possible via eZ Platform UI, but the schema still works and admin works as well.

      However with a single type in multiple groups the GraphQL Schema generation fails:

      19:48:35 ERROR     [console] Error thrown while running command "ezplatform:graphql:generate-schema". Message: "Type DomainContentMutation already has a field named createProduct" ["exception" => Exception { …},"command" => "ezplatform:graphql:generate-schema","message" => "Type DomainContentMutation already has a field named createProduct"]
      
      In SchemaBuilder.php line 46:
                                                                            
        Type DomainContentMutation already has a field named createProduct  
                                                                            
      

      Steps to repeat:

      1. Import old eZ Publish database with a content class in multiple content class groups
      2. Upgrade schema to eZ Platform v2.5.0
      3. Run "./bin/console ezplatform:graphql:generate-schema"

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            jani.tarvainen@ez.no Jani Tarvainen
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: