Hello,

Context : Drupal 8.2.4

When I try to display the "Edit" tab for a content type, I have this error :

Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException: You have requested a non-existent service "datetime.time". in Drupal\Component\DependencyInjection\Container->get() (line 157 of core/lib/Drupal/Component/DependencyInjection/Container.php).
Drupal\autosave_form\Form\AutosaveEntityFormHandler::createInstance(Object, Object) (Line: 249)
Drupal\Core\Entity\EntityTypeManager->createHandlerInstance('Drupal\autosave_form\Form\AutosaveEntityFormHandler', Object) (Line: 238)
Drupal\Core\Entity\EntityTypeManager->getHandler('node_type', 'autosave_form') (Line: 39)
autosave_form_form_alter(Array, Object, 'node_type_edit_form') (Line: 501)
Drupal\Core\Extension\ModuleHandler->alter('form', Array, Object, 'node_type_edit_form') (Line: 818)
Drupal\Core\Form\FormBuilder->prepareForm('node_type_edit_form', Array, Object) (Line: 131)
Drupal\autosave_form\Form\AutosaveFormBuilder->prepareForm('node_type_edit_form', Array, Object) (Line: 272)
Drupal\Core\Form\FormBuilder->buildForm('node_type_edit_form', Object) (Line: 74)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 574)
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}()
call_user_func_array(Object, Array) (Line: 144)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 64)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 99)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 78)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 50)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 652)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

Comments

Florent Jousseaume created an issue. See original summary.

znak’s picture

I can't to reproduce your issue. I need more info.

Florent Jousseaume’s picture

Hello Znak,

I've enabled the module on a fresh installation with 8.2.4 version. When i try to edit a node, I have the exception in my previous comment.
After search in the code, I can not find the service datetime.time
Hope it helps you.

Florent,

bkhandruk’s picture

Status: Active » Needs review
StatusFileSize
new3.08 KB
hchonov’s picture

Status: Needs review » Closed (works as designed)

The problem is that the time service has been introduced in 8.3.x and is not present in 8.2.x. The autosave form module has been developed mainly against 8.3.x, which is scheduled to be released on 05.04.2017. Therefore if you want to use the module you have to apply a patch removing the time service.