Nextcloud 13 update failed due to news app

Today I attempted nextcloud update version 13. However it fails when it tries to update news app.
It timesout on query below, causing mariadb to restart:

ALTER TABLE oc_news_items ADD unread TINYINT(1) DEFAULT ‘0’ NOT
NULL, ADD starred TINYINT(1) DEFAULT ‘0’ NOT NULL

My oc_news_items is 2936586 rows big.

I suspect its due to the size of the table it causes timeout of the query.
Does anyone have an idea howto execute that query? Is there a way I could split it in chunks?

BTW. my timeouts are set to:

MariaDB [(none)]> show variables like '%timeout%';
+-----------------------------+----------+
| Variable_name               | Value    |
+-----------------------------+----------+
| connect_timeout             | 10       |
| deadlock_timeout_long       | 50000000 |
| deadlock_timeout_short      | 10000    |
| delayed_insert_timeout      | 300      |
| innodb_flush_log_at_timeout | 1        |
| innodb_lock_wait_timeout    | 6000     |
| innodb_rollback_on_timeout  | OFF      |
| interactive_timeout         | 28800    |
| lock_wait_timeout           | 31536000 |
| net_read_timeout            | 30       |
| net_write_timeout           | 60       |
| slave_net_timeout           | 3600     |
| thread_pool_idle_timeout    | 60       |
| wait_timeout                | 28800    |
+-----------------------------+----------+