Problem/Motivation
I noticed the following error in the log. It showed up a couple of times recently.
The dblog message:
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[22001]: String data, right truncated: 7 ERROR: value too long for type character varying(2): INSERT INTO "visitors" ("visitors_ip", "visitors_uid", "visitors_title", "visitors_user_agent", "config_browser_engine", "config_browser_name", "config_browser_version", "config_client_type", "config_device_brand", "config_device_model", "config_device_type", "config_os", "config_os_version", "bot", "visitor_id", "visitors_url", "visitors_referer", "visitors_path", "route", "server", "config_resolution", "config_pdf", "config_flash", "config_java", "config_quicktime", "config_realplayer", "config_windowsmedia", "config_silverlight", "config_cookie", "pf_network", "pf_server", "pf_transfer", "pf_dom_processing", "pf_dom_complete", "pf_on_load", "pf_total", "visitors_date_time", "language", "location_country", "location_continent") VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8, :db_insert_placeholder_9, :db_insert_placeholder_10, :db_insert_placeholder_11, :db_insert_placeholder_12, :db_insert_placeholder_13, :db_insert_placeholder_14, :db_insert_placeholder_15, :db_insert_placeholder_16, :db_insert_placeholder_17, :db_insert_placeholder_18, :db_insert_placeholder_19, :db_insert_placeholder_20, :db_insert_placeholder_21, :db_insert_placeholder_22, :db_insert_placeholder_23, :db_insert_placeholder_24, :db_insert_placeholder_25, :db_insert_placeholder_26, :db_insert_placeholder_27, :db_insert_placeholder_28, :db_insert_placeholder_29, :db_insert_placeholder_30, :db_insert_placeholder_31, :db_insert_placeholder_32, :db_insert_placeholder_33, :db_insert_placeholder_34, :db_insert_placeholder_35, :db_insert_placeholder_36, :db_insert_placeholder_37, :db_insert_placeholder_38, :db_insert_placeholder_39) RETURNING visitors_id; Array ( ) in Drupal\visitors\Service\TrackerService->writeLog() (line 60 of /opt/drupal/web/modules/contrib/visitors/src/Service/TrackerService.php).
The backtrace:
#0 /opt/drupal/web/core/modules/pgsql/src/Driver/Database/pgsql/Insert.php(96): Drupal\Core\Database\ExceptionHandler->handleExecutionException()
#1 /opt/drupal/web/modules/contrib/visitors/src/Service/TrackerService.php(60): Drupal\pgsql\Driver\Database\pgsql\Insert->execute()
#2 /opt/drupal/web/modules/contrib/visitors/src/Controller/Visitors.php(198): Drupal\visitors\Service\TrackerService->writeLog()
#3 [internal function]: Drupal\visitors\Controller\Visitors->track()
#4 /opt/drupal/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#5 /opt/drupal/web/core/lib/Drupal/Core/Render/Renderer.php(593): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#6 /opt/drupal/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(121): Drupal\Core\Render\Renderer->executeInRenderContext()
#7 /opt/drupal/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
#8 /opt/drupal/vendor/symfony/http-kernel/HttpKernel.php(183): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#9 /opt/drupal/vendor/symfony/http-kernel/HttpKernel.php(76): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#10 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/Session.php(53): Symfony\Component\HttpKernel\HttpKernel->handle()
#11 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(48): Drupal\Core\StackMiddleware\Session->handle()
#12 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/ContentLength.php(28): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#13 /opt/drupal/web/core/modules/big_pipe/src/StackMiddleware/ContentLength.php(32): Drupal\Core\StackMiddleware\ContentLength->handle()
#14 /opt/drupal/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(191): Drupal\big_pipe\StackMiddleware\ContentLength->handle()
#15 /opt/drupal/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(128): Drupal\page_cache\StackMiddleware\PageCache->fetch()
#16 /opt/drupal/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(82): Drupal\page_cache\StackMiddleware\PageCache->lookup()
#17 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(48): Drupal\page_cache\StackMiddleware\PageCache->handle()
#18 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(51): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#19 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/AjaxPageState.php(36): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#20 /opt/drupal/web/core/lib/Drupal/Core/StackMiddleware/StackedHttpKernel.php(51): Drupal\Core\StackMiddleware\AjaxPageState->handle()
#21 /opt/drupal/web/core/lib/Drupal/Core/DrupalKernel.php(709): Drupal\Core\StackMiddleware\StackedHttpKernel->handle()
#22 /opt/drupal/web/index.php(19): Drupal\Core\DrupalKernel->handle()
#23 {main}
Steps to reproduce
I'm not sure how to reproduce the error. I was looking at the log and noticed the errors.
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes