Problem/Motivation

When using /admin/config/private-message/uninstall to prepare uninstallation for the module, the Uninstallation Preparation will fail:

An AJAX HTTP error occurred.
HTTP Result Code: 500
Debugging information follows.
Path: /en/batch?id=21&op=do_nojs&op=do
StatusText: Internal Server Error
ResponseText: The website encountered an unexpected error. Please try again later.Drupal\Component\Plugin\Exception\PluginNotFoundException: The "pm_thread_access_time" entity type does not exist. in Drupal\Core\Entity\EntityTypeManager->getDefinition() (line 139 of core/lib/Drupal/Core/Entity/EntityTypeManager.php). Drupal\Core\Entity\EntityTypeManager->getHandler('pm_thread_access_time', 'storage') (Line: 192)
Drupal\Core\Entity\EntityTypeManager->getStorage('pm_thread_access_time') (Line: 515)
Drupal::entityQuery('pm_thread_access_time') (Line: 116)
Drupal\private_message\Form\AdminUninstallForm::deletePrivateMessageAccessTimes(Array) (Line: 295)
_batch_process() (Line: 137)
_batch_do() (Line: 93)
_batch_page(Object) (Line: 55)
Drupal\system\Controller\BatchController->batchPage(Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 580)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 169)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 81)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 718)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

This is likly because the Uninstall From tries to uninstall the Entity-Types pm_thread_access_time and pm_thread_delete_time, which do not exist in the current version.

Steps to reproduce

Go to /admin/config/private-message/uninstall and press "Delete all private message content".

Proposed resolution

Remove deletePrivateMessageAccessTimes and deletePrivateMessageDeleteTimes from AdminUninstallForm.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

RobinCS created an issue. See original summary.

robincs’s picture

Status: Active » Needs review
keshavv’s picture

Status: Needs review » Reviewed & tested by the community

@RobinCS I agree with your point, There is an issue, and the given MR resolves it.

I have gone through the module code and found that this module is still in beta version and functionality is still not built.
As it is required to uninstall the module. It needs to be fixed.

Thank you.

artem_sylchuk made their first commit to this issue’s fork.

artem_sylchuk’s picture

Status: Reviewed & tested by the community » Fixed

Nice catch @RobinCS, thanks for creating the patch!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.