If you get an effect for a normal time and open the inventory, you will see it will tick down every second, but if you use a really long time or more than at least 20000 hours, going back to the inventory, it shows the correct time but it takes longer for it to update.
To reproduce:
Get a potion where the duration is longer than 200000 hours, then drink it, you will notice that in the inventory, it takes longer to update the timer.
Command: /give @p potion{CustomPotionEffects:[{Id:16,Amplifier:255b,Duration:2147483647,ShowParticles:0b}]} 1
Observed results;
The time it takes for the timer to update takes 5> seconds for it to update.
Expected results:
The timer will update every second.
Can confirm in 23w05a