View previous topic :: View next topic |
Author |
Message |
pingtoo Veteran
Joined: 10 Sep 2021 Posts: 1236 Location: Richmond Hill, Canada
|
Posted: Thu Oct 17, 2024 2:35 pm Post subject: session not able to track read topics [RESOLVED] |
|
|
Not sure if any body else experience this. My session seems not able to track topic been read. It is continue show as un-read topic. This happen to me yesterday afternoon (EST).
I remember I seen this happen in the past. This usually lead to forums software stop function later.
Last edited by pingtoo on Thu Oct 17, 2024 3:50 pm; edited 1 time in total |
|
Back to top |
|
|
Max Steel Advocate
Joined: 12 Feb 2007 Posts: 2267 Location: My own world! I and Gentoo!
|
Posted: Thu Oct 17, 2024 2:38 pm Post subject: |
|
|
I get this error every now and then. When this happens i get it working again by deleting all cookies in my browser and relogin. _________________ mfg
Steel
___________________
Heim-PC: AMD Ryzen 5950X, 64GB RAM, GTX 1080
Laptop: Intel Core i5-4300U, 16GB RAM, Intel Graphic
Arbeit-PC: Intel i5-1145G7, 16GB RAM, Intel Iris Xe Graphic (leider WSL2) |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1909
|
Posted: Thu Oct 17, 2024 3:04 pm Post subject: |
|
|
I gave up on this being automatic as it quickly breaks.
I simply rely on using the "Mark all topics read" link on a forum to keep track.
Also, the "You last visited on" time on the main page seems to be the basis of this feature. |
|
Back to top |
|
|
szatox Advocate
Joined: 27 Aug 2013 Posts: 3420
|
Posted: Thu Oct 17, 2024 3:10 pm Post subject: |
|
|
I had something like that a while ago; there is a cookie that holds recently visited posts. Deleting it should fix things.
I actually had better results deleting only this one cookie than deleting all cookies set by FGO. _________________ Make Computing Fun Again |
|
Back to top |
|
|
pingtoo Veteran
Joined: 10 Sep 2021 Posts: 1236 Location: Richmond Hill, Canada
|
Posted: Thu Oct 17, 2024 3:49 pm Post subject: |
|
|
Thanks to all those reply. I should check my browser cookie jar to clean up. |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1909
|
Posted: Thu Oct 17, 2024 4:52 pm Post subject: |
|
|
What I believe is happening is the serialized PHP array, which is then html encoded, is hitting the cookie max size limit (4096 bytes) and then just being rejected by browsers (and possibly servers) as invalid.
As it stores topics and UNIX timestamps as key/value, the size of the numbers and encoding along with the number of topics people read increase exponentially and quickly run out of space for a cookie.
Yes, you can temporarily clear out the Session cookie but the issue is likely to return particularly if persistent login is enabled.
I doubt there is a real fix with this old software, but maybe one day it can work as intended. |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1909
|
Posted: Fri Oct 18, 2024 1:27 pm Post subject: |
|
|
I can easily replicate this issue and it is the phpbb2mysql_t cookie.
Every time a topic is viewed, this cookie increases in size 31 bytes on average. Once the reader hits over 130 topics read, with modern times and topic numeric size, the cookie sent back is no longer valid and rejected by the browser.
Unless the browser clears the cookie, the forum software is not smart enough to do on its own. I believe that the forum is counting on "closing the browser" to clear a session cookie. However, they don't seem to do that as easily. I can logout, close the tab, close the browser and this cookie persists.
I know it is beating a dead horse to try to fix phpbb2, but I wanted to share my findings. |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 22618
|
Posted: Fri Oct 18, 2024 1:31 pm Post subject: |
|
|
Thank you for the findings. Even if the forum software is not fixed, your results should help other users who want to delete only the bad cookie, without wiping out the rest of their state. |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1909
|
Posted: Fri Oct 18, 2024 2:26 pm Post subject: |
|
|
Ah, phpBB does account for this, but not well enough due to the popularity of the forum and 32-bit time().
https://gitweb.gentoo.org/proj/forums.git/tree/htdocs/viewtopic.php?h=forumscvs#n573 :
Code: | if ( count($tracking_topics) >= 150 && empty($tracking_topics[$topic_id]) ) |
Since we are under 150 before an invalid cookie, it breaks very easily.
Strangely enough, posting a topic or reply looks for a count of 100. |
|
Back to top |
|
|
pingtoo Veteran
Joined: 10 Sep 2021 Posts: 1236 Location: Richmond Hill, Canada
|
Posted: Fri Oct 18, 2024 3:41 pm Post subject: |
|
|
grknight wrote: | I can easily replicate this issue and it is the phpbb2mysql_t cookie.
Every time a topic is viewed, this cookie increases in size 31 bytes on average. Once the reader hits over 130 topics read, with modern times and topic numeric size, the cookie sent back is no longer valid and rejected by the browser.
Unless the browser clears the cookie, the forum software is not smart enough to do on its own. I believe that the forum is counting on "closing the browser" to clear a session cookie. However, they don't seem to do that as easily. I can logout, close the tab, close the browser and this cookie persists.
I know it is beating a dead horse to try to fix phpbb2, but I wanted to share my findings. |
Thanks for the information.
I can confirm this behavior. I usually don't always keep my machine turn on for more that two days. But my current session have been up for more than two weeks and I do persist login. So it is exact match. |
|
Back to top |
|
|
|