Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2026-01-13 13:24:22

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 5,155
Website GitHub

Re: can't save any article

Is that this?

[MariaDB 11.8] UNIX_TIMESTAMP() now returns NULL instead of 0 (zero):


TXP Builders – finely-crafted code, design and txp

Offline

#14 2026-01-13 13:30:09

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 12,373
Website GitHub

Re: can't save any article

jakob wrote #342205:

Is this?

You beat me to it. I was gonna post the same link. Might be related. It’s the only timestampish issues I can find up there at the moment.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Hire Txp Builders – finely-crafted code, design and Txp

Offline

#15 2026-01-13 13:32:49

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 12,373
Website GitHub

Re: can't save any article

If it is that, and we get null back instead of an integer, can we detect it and swap the return value for a 0 so everything carries on working? I don’t think PHP allows us to cast null to int any more, but it might.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Hire Txp Builders – finely-crafted code, design and Txp

Offline

#16 2026-01-13 15:25:17

etc
Developer
Registered: 2010-11-11
Posts: 5,648
Website GitHub

Re: can't save any article

jakob wrote #342205:

Is that this?

Oh, thanks, have not seen it. So yes, this looks like a critical mariadb bug. I was actually thinking of that, but they are certainly related.

Bloke wrote #342207:

If it is that, and we get null back instead of an integer, can we detect it and swap the return value for a 0 so everything carries on working? I don’t think PHP allows us to cast null to int any more, but it might.

Nope, we’d need to handle it at the db level, and it looks cumbersome. I would rather avoid this gymnastics.

Offline

#17 2026-01-13 16:36:50

bici
Member
From: vancouver
Registered: 2004-02-24
Posts: 2,246
Website Mastodon

Re: can't save any article

etc wrote #342208:

… this looks like a critical mariadb bug.

just asking/wondering…. why don’t the folks responsible for MariaDb fix the bug?


…. texted postive

Offline

#18 2026-01-13 17:24:22

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,680
GitHub

Re: can't save any article

Gentle, respectful reminder: we don’t officially support MariaDB with Textpattern 4.x. There is no explicit mention of ABI compatibility, as far as I know. There is a compatibility and differences landing page on their docs.

I’m running Textpattern 4.9.0 on MariaDB 10.11, which is a well-established LTS branch with a long-ish shelf life ahead. I haven’t found any issues to date. MariaDB 11.8 is around 7 months old at the present time.

@Adams: Perhaps it’s worth switching to an earlier LTS branch if MariaDB is on the cards?

Offline

#19 2026-01-13 17:46:51

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 12,373
Website GitHub

Re: can't save any article

gaekwad wrote #342211:

we don’t officially support MariaDB with Textpattern 4.x.

Aye, noted but if it happened to be an easy fix, it’d be a nice win for 4.9.1. Sadly looks as if it’s out of reach unless they can resolve it.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Hire Txp Builders – finely-crafted code, design and Txp

Offline

#20 2026-01-13 18:10:18

etc
Developer
Registered: 2010-11-11
Posts: 5,648
Website GitHub

Re: can't save any article

Well, there might be an easy fix, it just looks dirty. We’d have to detect once the value of

SELECT FROM_UNIXTIME(0)

and use FROM_UNIXTIME(0) if it is not null, and FROM_UNIXTIME(1) otherwise. This would introduce 1s dates shift on faulty MariaDB servers, but this is comparable to servers time accuracy. But someone needs to test whether FROM_UNIXTIME(1) works first.

Offline

#21 2026-01-13 18:25:44

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 12,373
Website GitHub

Re: can't save any article

etc wrote #342213:

This would introduce 1s dates shift on faulty MariaDB servers

Unlikely anyone would notice. The only fallout would be people who use content expiry at 23:59:59, which might push the expiry into “next day”.

Edit: and it looks as if the humble second might be on its way out anyway once leap seconds are abolished in 2035.

Adams: are you able to confirm if FROM_UNIXTIME(1)@ works please?

Last edited by Bloke (2026-01-13 18:37:05)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Hire Txp Builders – finely-crafted code, design and Txp

Offline

Board footer

Powered by FluxBB