basically it's caused by:
PHP Fatal error: Uncaught Error: Call to a member function getBaseFieldDefinitions() on null in /app/webroot/core/modules/views/src/EntityViewsData.php:287
during the upgrading the core from 8.7.x to 8.8.x, also the same problem is described in other tickets like that: #3035953-28: Add @trigger_error() to deprecated EntityManager->EntityFieldManager methods

however, there are different tickets where we can see that we started removing EntityManager and related functionality from core.
see: #2886622: Deprecate all EntityManager methods with E_USER_DEPRECATED, #3035953: Add @trigger_error() to deprecated EntityManager->EntityFieldManager methods

So, we have to fix GroupContentViewsData.php according to EntityViewsData.php
the status is critical, because there are no chance to do the upgrade from 8.7.x to 8.8.x without the fix

Comments

alphawebgroup created an issue. See original summary.

alphawebgroup’s picture

Issue summary: View changes
alphawebgroup’s picture

StatusFileSize
new3.86 KB
alphawebgroup’s picture

Assigned: alphawebgroup » Unassigned
Status: Active » Needs work

it looks like it works for 8.8.x only

alphawebgroup’s picture

Title: PHP Fatal error: Uncaught Error: Call to a member function getBaseFieldDefinitions() on null - related to GroupContentViewsData.php » 8.8.x: PHP Fatal error: Uncaught Error: Call to a member function getBaseFieldDefinitions() on null - related to GroupContentViewsData.php
lobsterr’s picture

Status: Needs work » Reviewed & tested by the community
Parent issue: » #3042771: Drupal 9 Deprecated Code Report

I have checked it works.

dropa’s picture

Status: Reviewed & tested by the community » Needs work

This indeed does bump core minimum requirement to 8.8, so composer.json and group.info.yml needs to be modified as well

Edit: This is what happens with core 8.7.8

Argument 3 passed to Drupal\views\EntityViewsData::__construct()
must implement interface Drupal\Core\Entity\EntityManagerInterface,
instance of Drupal\Core\Entity\EntityTypeManager given, called in
.../web/modules/contrib/group/src/Entity/Views/GroupContentViewsData.php
lobsterr’s picture

Status: Needs work » Needs review
StatusFileSize
new4.68 KB

I rerolled the patch. It is not applying anymore and also I added requirements

krzysztof domański’s picture

Priority: Major » Critical
StatusFileSize
new2.25 KB
new4.5 KB

1. Drupal 8.8.0 is available so this is critical now.

2. IMO it would be a good idea to creating a new branch 8.x-2.0 for Drupal ^8.8. It can easily prepared to Drupal 9 then.

3. We can use core_version_requirement. New 'core_version_requirement' key in info.yml files for modules, themes and profiles allows Composer semantic version constraints including specifying multiple major versions of core.

4. Out of-scope.

-      $field_name = 'gc__' . $entity_type_id;
+      $field_name = "gc__{$entity_type_id}";
berdir’s picture

Priority: Critical » Normal

No, it is not. The error is already fixed in the dev version, getting rid of the deprecations is neither critical nor major. See #3095390: Drupal Core 8.8-beta1 update fails with Group 8.x-1.0-rc4

vasike’s picture

i confirm @Berdir latest comment #10

kristiaanvandeneynde’s picture

Category: Bug report » Task

Either use the dev version or apply the patch from here for now if you are having issues. #3061353: Replace deprecated EntityManager and add EntityFieldManager in GroupContentViewsData

The patch here will be committed once the minimum version is 8.8.

jedgar1mx’s picture

Patches were not working for me but dev seems to do the job.

superfluousapostrophe’s picture

Using the dev version also worked for me. After installing the dev version of Group, be sure to update the DB to catch the module updates before trying to update to 8.8.

jedgar1mx’s picture

My guess is that there are some other patches that were merged into dev that are required by 8.8

lobsterr’s picture

@jedgar1mix, I have grouped all depreciation issues here #3042771: Drupal 9 Deprecated Code Report, other tickets don't have any problems with 8.8 as far as I remember

psf_’s picture

I updated to D8.8 using group dev version and it works ok.

mmilaprat’s picture

which is your recommendation, we must use use the patch 3068918-9.patch or the dev version of the module?

psf_’s picture

In my project context, and with the actual dev status, I used dev. But, I can't recommend a way or another, each one has her risks.

Deno’s picture

When can we expect new version of the group module?

c.e.a’s picture

After updating from Drupal Core 8.7.x to 8.8.x, the site became inaccessible and I encountered the below error:

Error: Uncaught Error: Call to a member function getDefinitions() on null in /home/#####/public_html/#####.com/web/modules/contrib/group/src/Entity/Views/GroupContentViewsData.php:79

All I have to do is switch from Group 8.x-1.0-rc4 version to Group 8.x-1.x-dev version by running composer require 'drupal/group:1.x-dev' then drush updb and now all is working as expected.

Thank you for your help,

dercheffe’s picture

What would be wrong with creating a new beta release including the patches?

Best regards

dercheffe’s picture

dww’s picture

Status: Needs review » Postponed

@dercheffe re: #22: This patch would prevent group from working with 8.7.x core, which (should be) still supported until 8.9.0 core is released. So we do *not* want to include this patch in a release of group until after June 3 2020.

@Krzysztof Domański: group works fine with 8.8.x core already. We don't need this patch to support 8.8.x, so this isn't critical. We just need #3100998: Create a 8.x-1.0-rc5 release so that folks get an official release that includes #3061353: Replace deprecated EntityManager and add EntityFieldManager in GroupContentViewsData. A whole new branch is a lot of technical debt for limited benefit, so I'd advocate against that strategy.

Since (IMHO) we should *not* commit this patch for another ~6 months, setting to postponed.

Thanks,
-Derek

kristiaanvandeneynde’s picture

Agree with #24. Need a small bugfix to land before tagging new release. Hopefully this week.

safetypin’s picture

I'm attempting to apply patch #9, but it won't apply. I'm using Group RC5; has this patch been committed? It sounds like it wasn't going to be committed, but when I started trying to manually apply the patch I found that some of the changes are there, and some are not. So, does this need to be rerolled? I'm continuing to get the error, so something is still going wrong somewhere. I've already updated to Drupal 8.8.1, which is what (presumably) caused this error to be thrown.

berdir’s picture

You don't need a patch for 8.8 compatibility if you use the latest -rc

berdir’s picture

Status: Postponed » Closed (duplicate)
sidhan’s picture

I updated the drupal version 8.9 to 9.4 using composer after that refresh the page but it seem like this "The website encountered an unexpected error. Please try again later". Is some knows please help me to do the next step