Help! Error Occurred while fetching Meta Data Error SuiteCRM 8

Ok, so I’m on my first use of SuiteCRM 8. I created a custom module. Some minor bugs but seemed to work ok. Then I changed to grouped menu and added my new module to the menu filter. BOOM. can’t get in to SuiteCRM anymore. I get “Error Occurred while fetching Meta Data” and can’t access. I ran console in the browser and the network tab I get this error, so I’m pretty sure the group menu is the problem. Any way to re-set the menu system back to default without being logged in?

{
  "errors": [
    {
      "debugMessage": "Notice: Undefined index: PLNE_Planes",
      "message": "Internal server error",
      "extensions": {
        "category": "internal"
      },
      "locations": [
        {
          "line": 2,
          "column": 3
        }
      ],
      "path": [
        "appMetadata"
      ],
      "trace": [
        {
          "file": "/home/crm/public_html/core/backend/Navbar/LegacyHandler/NavbarHandler.php",
          "line": 234,
          "call": "GroupedTabStructure::get_tab_structure()"
        },
        {
          "file": "/home/crm/public_html/core/backend/Navbar/LegacyHandler/NavbarHandler.php",
          "line": 204,
          "call": "App\\Navbar\\LegacyHandler\\NavbarHandler::getTabStructure()"
        },
        {
          "file": "/home/crm/public_html/core/backend/Navbar/LegacyHandler/NavbarHandler.php",
          "line": 138,
          "call": "App\\Navbar\\LegacyHandler\\NavbarHandler::fetchGroupedNavTabs()"
        },
        {
          "file": "/home/crm/public_html/core/backend/Metadata/Service/AppMetadataProvider.php",
          "line": 183,
          "call": "App\\Navbar\\LegacyHandler\\NavbarHandler::getNavbar()"
        },
        {
          "file": "/home/crm/public_html/core/backend/Metadata/Service/AppMetadataProvider.php",
          "line": 144,
          "call": "App\\Metadata\\Service\\AppMetadataProvider::getUserMetadata()"
        },
        {
          "file": "/home/crm/public_html/core/backend/Metadata/DataProvider/AppMetadataItemDataProvider.php",
          "line": 87,
          "call": "App\\Metadata\\Service\\AppMetadataProvider::getMetadata()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/Bridge/Symfony/Bundle/DataProvider/TraceableChainItemDataProvider.php",
          "line": 75,
          "call": "App\\Metadata\\DataProvider\\AppMetadataItemDataProvider::getItem()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/DataProvider/OperationDataProviderTrait.php",
          "line": 64,
          "call": "ApiPlatform\\Core\\Bridge\\Symfony\\Bundle\\DataProvider\\TraceableChainItemDataProvider::getItem()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/Bridge/Symfony/Routing/IriConverter.php",
          "line": 108,
          "call": "ApiPlatform\\Core\\Bridge\\Symfony\\Routing\\IriConverter::getItemData()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/GraphQl/Resolver/Stage/ReadStage.php",
          "line": 122,
          "call": "ApiPlatform\\Core\\Bridge\\Symfony\\Routing\\IriConverter::getItemFromIri()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/GraphQl/Resolver/Stage/ReadStage.php",
          "line": 74,
          "call": "ApiPlatform\\Core\\GraphQl\\Resolver\\Stage\\ReadStage::getItem()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/GraphQl/Resolver/Factory/ItemResolverFactory.php",
          "line": 69,
          "call": "ApiPlatform\\Core\\GraphQl\\Resolver\\Stage\\ReadStage::__invoke()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
          "line": 632,
          "call": "ApiPlatform\\Core\\GraphQl\\Resolver\\Factory\\ItemResolverFactory::ApiPlatform\\Core\\GraphQl\\Resolver\\Factory\\{closure}()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
          "line": 555,
          "call": "GraphQL\\Executor\\ReferenceExecutor::resolveOrError()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
          "line": 1247,
          "call": "GraphQL\\Executor\\ReferenceExecutor::resolveField()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
          "line": 257,
          "call": "GraphQL\\Executor\\ReferenceExecutor::executeFields()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
          "line": 208,
          "call": "GraphQL\\Executor\\ReferenceExecutor::executeOperation()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/Executor/Executor.php",
          "line": 155,
          "call": "GraphQL\\Executor\\ReferenceExecutor::doExecute()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/GraphQL.php",
          "line": 158,
          "call": "GraphQL\\Executor\\Executor::promiseToExecute()"
        },
        {
          "file": "/home/crm/public_html/vendor/webonyx/graphql-php/src/GraphQL.php",
          "line": 90,
          "call": "GraphQL\\GraphQL::promiseToExecute()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/GraphQl/Executor.php",
          "line": 34,
          "call": "GraphQL\\GraphQL::executeQuery()"
        },
        {
          "file": "/home/crm/public_html/vendor/api-platform/core/src/GraphQl/Action/EntrypointAction.php",
          "line": 86,
          "call": "ApiPlatform\\Core\\GraphQl\\Executor::executeQuery()"
        },
        {
          "file": "/home/crm/public_html/vendor/symfony/http-kernel/HttpKernel.php",
          "line": 157,
          "call": "ApiPlatform\\Core\\GraphQl\\Action\\EntrypointAction::__invoke()"
        },
        {
          "file": "/home/crm/public_html/vendor/symfony/http-kernel/HttpKernel.php",
          "line": 79,
          "call": "Symfony\\Component\\HttpKernel\\HttpKernel::handleRaw()"
        },
        {
          "file": "/home/crm/public_html/vendor/symfony/http-kernel/Kernel.php",
          "line": 195,
          "call": "Symfony\\Component\\HttpKernel\\HttpKernel::handle()"
        },
        {
          "file": "/home/crm/public_html/public/index.php",
          "line": 62,
          "call": "Symfony\\Component\\HttpKernel\\Kernel::handle()"
        }
      ]
    }
  ],
  "data": {
    "appMetadata": null
  }
}

Did you change language?

Thanks @pgr I did see that one, but no language file was changed or installed. I also tried adding this to the config file (hope that still works in version 8):

‘default_navigation_paradigm’ => ‘m’,

didn’t work either. PS - thanks for fixing my post’s code!

Hi @pstevens , have you checked the option you set has been correctly saved:

even if i flag it, that option stays empty. (version 8.1.0 here)

I’ve seen it’s managed in public/legacy/modules/Users/User.php

if (isset($_POST['use_group_tabs'])) {
                $this->setPreference('navigation_paradigm', $_POST['use_group_tabs'], 0, 'global');

that after an interface calls the setPreference function defined in modules/UserPreferences/UserPreference.php

The problem is I can’t even login to make any changes or check.

Have you tried to delete (to move away) the public/legacy/.htaccess file?

Anyway i secceded in enabling the “group tabs” feature doing the opposite as described here:

image

So, please try:
set group_tabs as false,
Do Quick Repair
Set again group_tabs as true,
Do Quick Repair

Hi @pstevens,

Have a look a the following section

How does your error_reporting ini setting look like?

PS: I may not have time to reply back, sorry. Though hope this helps

I’ve checked both the legacy log and the suitecrm 8 log. There’ nothing relevant.

But did you set the error_reporting like the guide says?

Thanks everyone. I eventually did a fresh install and just moved the database over and the relevant stuff from the Uploads folder and the Custom folder to the fresh install. Everything seems to work. I’m leaving the menu as is!

Hi @pstevens,

Thank you for the feedback. Would you mind creating an issue on the SuiteCRM-Core github project please? This is something we need to look at.

Will do I’ve got another dev environment I tried to replicate the issue in but it’s more recent version than the one I was having the issue with and the option to change the menu doesn’t even work at all in the admin menu. (Gives some kind of not found error) So I can’t change the settings to confirm that that was for sure the issue.

1 Like

Thank you @pstevens. If you can reference that issue as well it would be great.

Thanks again for your feedback