Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integretify Constraint Violation Error Production #3171

Closed
jshrek opened this issue Jul 7, 2023 · 1 comment
Closed

Integretify Constraint Violation Error Production #3171

jshrek opened this issue Jul 7, 2023 · 1 comment

Comments

@jshrek
Copy link

jshrek commented Jul 7, 2023

I am seeing the following error come up every day in logs.
Not sure what it means, and I am not sure if it is causing any issues or not.

error

Here is expanded:

SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'e0f5e923-2b05-4094-b247-7990136a3341' for key 'PRIMARY' (SQL: insert into notifications (id, type, data, read_at, notifiable_id, notifiable_type, updated_at, created_at) values (e0f5e923-2b05-4094-b247-7990136a3341, App\Notifications\WebsiteNotification, {"thread_id":43352,"conversation_id":26358}, , 55, App\User, 2023-07-05 09:13:21, 2023-07-05 09:13:21)) {"exception":"[object] (Illuminate\Database\QueryException(code: 23000): SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'e0f5e923-2b05-4094-b247-7990136a3341' for key 'PRIMARY' (SQL: insert into notifications (id, type, data, read_at, notifiable_id, notifiable_type, updated_at, created_at) values (e0f5e923-2b05-4094-b247-7990136a3341, App\Notifications\WebsiteNotification, {"thread_id":43352,"conversation_id":26358}, , 55, App\User, 2023-07-05 09:13:21, 2023-07-05 09:13:21)) at /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Connection.php:664, Doctrine\DBAL\Driver\PDO\Exception(code: 23000): SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'e0f5e923-2b05-4094-b247-7990136a3341' for key 'PRIMARY' at /home/mydomain/public_freescout/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDO/Exception.php:18, PDOException(code: 23000): SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'e0f5e923-2b05-4094-b247-7990136a3341' for key 'PRIMARY' at /home/mydomain/public_freescout/overrides/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php:115)
[stacktrace]
#0 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Connection.php(624): Illuminate\Database\Connection->runQueryCallback('insert into no...', Array, Object(Closure)) #1 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Connection.php(459): Illuminate\\Database\\Connection->run('insert into no...', Array, Object(Closure))
#2 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Connection.php(411): Illuminate\Database\Connection->statement('insert into no...', Array) #3 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php(2142): Illuminate\\Database\\Connection->insert('insert into no...', Array)
#4 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(1285): Illuminate\Database\Query\Builder->insert(Array)
#5 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Database/Eloquent/Model.php(698): Illuminate\Database\Eloquent\Builder->__call('insert', Array)
#6 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Database/Eloquent/Model.php(550): Illuminate\Database\Eloquent\Model->performInsert(Object(Illuminate\Database\Eloquent\Builder))
#7 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneOrMany.php(279): Illuminate\Database\Eloquent\Model->save()
#8 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Support/helpers.php(1038): Illuminate\Database\Eloquent\Relations\HasOneOrMany->Illuminate\Database\Eloquent\Relations\{closure}(Object(Illuminate\Notifications\DatabaseNotification))
#9 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/HasOneOrMany.php(280): tap(Object(Illuminate\Notifications\DatabaseNotification), Object(Closure))
#10 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Notifications/Channels/DatabaseChannel.php(20): Illuminate\Database\Eloquent\Relations\HasOneOrMany->create(Array)
#11 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php(113): Illuminate\Notifications\Channels\DatabaseChannel->send(Object(App\User), Object(App\Notifications\WebsiteNotification))
#12 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Notifications/NotificationSender.php(89): Illuminate\Notifications\NotificationSender->sendToNotifiable(Object(App\User), '4840c97f-5933-4...', Object(App\Notifications\WebsiteNotification), 'database')
#13 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Notifications/ChannelManager.php(50): Illuminate\Notifications\NotificationSender->sendNow(Object(Illuminate\Database\Eloquent\Collection), Object(App\Notifications\WebsiteNotification), Array)
#14 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Notifications/SendQueuedNotifications.php(57): Illuminate\Notifications\ChannelManager->sendNow(Object(App\User), Object(App\Notifications\WebsiteNotification), Array)
#15 [internal function]: Illuminate\Notifications\SendQueuedNotifications->handle(Object(Illuminate\Notifications\ChannelManager))
#16 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/BoundMethod.php(29): call_user_func_array(Array, Array)
#17 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/BoundMethod.php(87): Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()
#18 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/BoundMethod.php(31): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))
#19 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/Container.php(549): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)
#20 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php(94): Illuminate\Container\Container->call(Array)
#21 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(114): Illuminate\Bus\Dispatcher->Illuminate\Bus\{closure}(Object(Illuminate\Notifications\SendQueuedNotifications))
#22 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(102): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Illuminate\Notifications\SendQueuedNotifications))
#23 /home/mydomain/pu
blic_freescout/vendor/laravel/framework/src/Illuminate/Bus/Dispatcher.php(98): Illuminate\Pipeline\Pipeline->then(Object(Closure))
#24 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/CallQueuedHandler.php(49): Illuminate\Bus\Dispatcher->dispatchNow(Object(Illuminate\Notifications\SendQueuedNotifications), false)
#25 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/Jobs/Job.php(76): Illuminate\Queue\CallQueuedHandler->call(Object(Illuminate\Queue\Jobs\DatabaseJob), Array)
#26 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/Worker.php(320): Illuminate\Queue\Jobs\Job->fire()
#27 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/Worker.php(270): Illuminate\Queue\Worker->process('database', Object(Illuminate\Queue\Jobs\DatabaseJob), Object(Illuminate\Queue\WorkerOptions))
#28 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/Worker.php(114): Illuminate\Queue\Worker->runJob(Object(Illuminate\Queue\Jobs\DatabaseJob), 'database', Object(Illuminate\Queue\WorkerOptions))
#29 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/Console/WorkCommand.php(101): Illuminate\Queue\Worker->daemon('database', 'emails,default,...', Object(Illuminate\Queue\WorkerOptions))
#30 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Queue/Console/WorkCommand.php(85): Illuminate\Queue\Console\WorkCommand->runWorker('database', 'emails,default,...')
#31 [internal function]: Illuminate\Queue\Console\WorkCommand->handle()
#32 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/BoundMethod.php(29): call_user_func_array(Array, Array)
#33 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/BoundMethod.php(87): Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()
#34 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/BoundMethod.php(31): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))
#35 /home/mydomain/public_freescout/overrides/laravel/framework/src/Illuminate/Container/Container.php(549): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)
#36 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Console/Command.php(183): Illuminate\Container\Container->call(Array)
#37 /home/mydomain/public_freescout/vendor/symfony/console/Command/Command.php(255): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
#38 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Console/Command.php(170): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
#39 /home/mydomain/public_freescout/vendor/symfony/console/Application.php(992): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#40 /home/mydomain/public_freescout/vendor/symfony/console/Application.php(255): Symfony\Component\Console\Application->doRunCommand(Object(Illuminate\Queue\Console\WorkCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#41 /home/mydomain/public_freescout/vendor/symfony/console/Application.php(148): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#42 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Console/Application.php(88): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#43 /home/mydomain/public_freescout/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(121): Illuminate\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#44 /home/mydomain/public_freescout/artisan(62): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#45 {main}
"}

@freescout-helpdesk
Copy link
Contributor

freescout-helpdesk commented Jul 12, 2023

It's hard to tell what may cause this. The error is not critical - it just says that it can't insert the record as it already exists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants