I'm getting a WSOD and this error whenever I try to access the settings page for this module, which makes the module unusable. I'm on Drupal 8.6.10.
The website encountered an unexpected error. Please try again later.
InvalidArgumentException: Source path has to start with a slash. in Drupal\Core\Path\AliasManager->getAliasByPath() (line 186 of core/lib/Drupal/Core/Path/AliasManager.php). Drupal\splash_redirect\Form\SplashRedirectSettingsForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 518)
Drupal\Core\Form\FormBuilder->retrieveForm('splash_redirect_settings_form', Object) (Line: 275)
Drupal\Core\Form\FormBuilder->buildForm('splash_redirect_settings_form', Object) (Line: 93)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
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: 151)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 44)
Drupal\bat_api\StackMiddleware\BatApiMiddleware->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: 44)
Drupal\services\StackMiddleware\FormatSetter->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 693)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
Comments
Comment #2
adambernstein commentedDid you happen to just update from Splash Redirect 8.x-1.4? If so, please run database updates as mentioned in the Release Notes
Comment #3
carnerik commentedThanks for the fast reply!
It's a new install (8.x-1.5). I did run updates on the database (and cleared the cache).
I checked on simplytest.me (Drupal 8.6.13; Splash Redirect 8.x-1.5) and got the same result.
Comment #4
adambernstein commentedOk gotcha. Thanks for the report, I'll take a look.
Comment #6
adambernstein commentedGive this patch a try and let me know if it resolves the issue. You may have to uninstall and reinstall the splash_redirect module after patching.
Comment #7
adambernstein commentedHaven't heard from OP, but I'm reasonably sure the patch will solve the issue. I'll bundle this into 8.x-1.6 and release. Make sure to uninstall splash_redirect before you update.
Comment #8
carnerik commentedIt's working!
FYI, while examining the patch and module files for 1.5, I noticed that I was missing the config folder. I'm not sure when that happened... Anyway, I uninstalled the module, deleted the module folder, and then installed 1.6, just to be safe.
Thanks again for the fast response. I'm looking forward to trying the module out.
Comment #9
adambernstein commentedGreat! Thanks for submitting the bug ticket, I'll close this out now.
The config folder was missing because it hadn't been added to the module yet :). That's exactly what I fixed in the patch, so no fault of yours. Thanks!
Comment #10
adambernstein commentedI just caught one other point of confusion that this may bring up. If you leave the default value of the source page as '/', one might expect that to be the front page (even though the help text says "leave blank"). I could imagine users thinking leaving the default '/' is the same as 'blank'.
The 8.x-1.7 release will handle this and interpret both true 'blank' and a single slash to be
<front>.