Uncaught database exception in _tracker_remove

Created on 11 March 2020, over 4 years ago
Updated 22 April 2024, 2 months ago

In the _tracker_remove() we can find the next lines:

      $connection->update('tracker_node')
        ->fields([
          'changed' => $changed,
          'published' => $node->isPublished(),
        ])
        ->condition('nid', $nid)
        ->execute();

If $node->isPublished() returns FALSE we can see the next error:

Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[22007]:
Invalid datetime format: 1366 Incorrect integer value: '' for column `tracker_node`.`published` at row 1:
UPDATE {tracker_node} SET changed=:db_update_placeholder_0, published=:db_update_placeholder_1 WHERE nid = :db_condition_placeholder_0; Array ( [:db_update_placeholder_0] => _TIMESTAMP_ [:db_update_placeholder_1] => [:db_condition_placeholder_0] => _NID_ ) in _tracker_remove()
(line 377 of /core/modules/tracker/tracker.module).

Simmilar issue was fixed by addign (int) and commited here 2887490 β†’
but not all the 'published' => $node->isPublished(), entries were fixed.

πŸ› Bug report
Status

Needs work

Version

1.0

Component
TrackerΒ  β†’

Last updated 26 days ago

No maintainer
Created by

πŸ‡ΊπŸ‡¦Ukraine gilmord πŸ‡ΊπŸ‡¦Ukraine

Live updates comments and jobs are added and updated live.
  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024