Jump to content

Forum telling me I have a notification when I do not

thekeemo

It's doing it now with the #2 about 5 seconds after I move to a new page. They disappear after I open the notification list, and only reappear about 5 seconds after I move to a new page. 

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

If you open the dev tools using F12, and switch to the console tab, then run

ips.utils.db.get( 'notifications', ips.getSetting('baseURL') )

what is the output?

Also, what is the output when you visit https://linustechtips.com/main/?app=core&module=system&controller=ajax&do=instantNotifications&notifications=0 and https://linustechtips.com/main/api.php?notifications=5&notificationContent=0?

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

16 minutes ago, colonel_mortis said:

If you open the dev tools using F12, and switch to the console tab, then run


ips.utils.db.get( 'notifications', ips.getSetting('baseURL') )

what is the output?

Also, what is the output when you visit https://linustechtips.com/main/?app=core&module=system&controller=ajax&do=instantNotifications&notifications=0 and https://linustechtips.com/main/api.php?notifications=5&notificationContent=0?

Just had the submit reply button area disappear (including the button)

F12 doesnt work in opera anyway

Spoiler

 

Object {timestamp: 1467761198427, messages: "0", notifications: "0"}

 

 

 

 

Spoiler

 

{"notifications":{"count":"0","data":[]},"messages":{"count":"0","data":[]}}

 

 

 

 

Spoiler

{"display_name":"thekeemo","profile_image":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-95785.png","new_pms":0,"new_notifications":0,"notifications":[{"id":13301988,"title":"colonel_mortis commented on Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8017262","date":1467760322,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13297804,"title":"Energycore replied to a status update.","url":"https:\/\/linustechtips.com\/main\/profile\/95785-thekeemo\/?status=139518&type=status","date":1467756338,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_05\/572807a065e09_Bewickswren.jpg.e11095255c3abbbaa1031ff8f2fa4520.thumb.jpg.6418c8e62a2ca7583933c6818a64acaa.jpg","unread":false},{"id":13293872,"title":"Maist quoted you in a topic: is it worth it to pay extra for a premium Z170 board?","url":"https:\/\/linustechtips.com\/main\/topic\/621500-is-it-worth-it-to-pay-extra-for-a-premium-z170-board\/?do=findComment&comment=8016644","date":1467753680,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/set_resources_4\/84c1e40ea0e759e3f1505eb1788ddf3c_default_photo.png","unread":false},{"id":13292785,"title":"Mitrailleuse quoted you in a topic: Israel attacks Facebook, claims FB allows terrorists to incite terrorism","url":"https:\/\/linustechtips.com\/main\/topic\/620792-israel-attacks-facebook-claims-fb-allows-terrorists-to-incite-terrorism\/?do=findComment&comment=8016609","date":1467753190,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-28583.gif","unread":false},{"id":13291167,"title":"Mitrailleuse quoted you in a topic: Israel attacks Facebook, claims FB allows terrorists to incite terrorism","url":"https:\/\/linustechtips.com\/main\/topic\/620792-israel-attacks-facebook-claims-fb-allows-terrorists-to-incite-terrorism\/?do=findComment&comment=8016571","date":1467752505,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-28583.gif","unread":false}]}

It isnt doing it now though

Thats that. If you need to get in touch chances are you can find someone that knows me that can get in touch.

Link to comment
Share on other sites

Link to post
Share on other sites

That's interesting. It seems to be doing it and not doing it at the same times for @thekeemo and I. Here's my info while the problem isn't occurring:

Spoiler

Object {timestamp: 1467696877417, messages: "0", notifications: "0"}

First Link:

Spoiler

{"notifications":{"count":"0","data":[]},"messages":{"count":"0","data":[]}}

Second Link:

Spoiler

{"display_name":"straight_stewie","profile_image":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_02\/Kramer.jpg.2a687a0e7c4fb0aec4fe91338fbc9ee1.thumb.jpg.1bac7a523463ad17a9c78576e904267c.jpg","new_pms":0,"new_notifications":0,"notifications":[{"id":13301989,"title":"colonel_mortis and thekeemo commented on Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8017262","date":1467761342,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13301859,"title":"Ryoutarou97 commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017251","date":1467760206,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_02\/l_sit_look.png.eaa035d4f838c366666755de55e27406.thumb.png.6b336041aee5f97f0f6d01017550151b.png","unread":false},{"id":13280065,"title":"colonel_mortis said your post was informative in: Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8015304","date":1467744671,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13278335,"title":"Hackentosher quoted you in a topic: Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8015696","date":1467742968,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_05\/5733e3b246b96_ProfilePhoto2.png.4376183fdf042169e7fca8c1735f689b.thumb.png.dfa27e43184b9695e09ef1e55fe71458.png","unread":false},{"id":13275744,"title":"LieutenantLime, iamdarkyoshi and AlexTheRose commented on Independence Day Stories","url":"https:\/\/linustechtips.com\/main\/topic\/621131-independence-day-stories\/?do=findComment&comment=8015445","date":1467740762,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/set_resources_5\/84c1e40ea0e759e3f1505eb1788ddf3c_default_photo.png","unread":false}]}


Should I post this again when the problem is occurring? No telling when that will be though.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

6 minutes ago, straight_stewie said:

Should I post this again when the problem is occurring? No telling when that will be though.

Yeah, unfortunately the data while it's not happening doesn't have any clues, but hopefully when it is happening it will be more useful.

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

It's doing it again. This time with 2 notifications (when infact, I have none).

F12 console command:

Spoiler

Object {timestamp: 1467697218730, messages: "0", notifications: "2"}

Link one:

Spoiler

{"notifications":{"count":"0","data":[]},"messages":{"count":"0","data":[]}}

Link two:

Spoiler

{"display_name":"straight_stewie","profile_image":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_02\/Kramer.jpg.2a687a0e7c4fb0aec4fe91338fbc9ee1.thumb.jpg.1bac7a523463ad17a9c78576e904267c.jpg","new_pms":0,"new_notifications":0,"notifications":[{"id":13310620,"title":"UberGamerKing commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017886","date":1467770302,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_06\/57526c063a53d_Linus_going_crazy_For_1_full_hour(1).gif.0f05ff1f0a88001fd63a4a52a9837990.thumb.gif.81d6af609b01aaf6a46448e5ad9cb270.gif","unread":false},{"id":13308986,"title":"aisle9 commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017783","date":1467768062,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_07\/kill-la-kill-wallpaper-4.jpg.31fa5d3bc95195467fcbf312fbc138b1.thumb.jpg.88f21c4a289013dde432c512f464b1e2.jpg","unread":false},{"id":13303832,"title":"colonel_mortis quoted you in a topic: Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8017427","date":1467762364,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13301989,"title":"colonel_mortis and thekeemo commented on Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8017262","date":1467761342,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13301859,"title":"Ryoutarou97 commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017251","date":1467760206,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_02\/l_sit_look.png.eaa035d4f838c366666755de55e27406.thumb.png.6b336041aee5f97f0f6d01017550151b.png","unread":false}]}

 

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

6 hours ago, straight_stewie said:

It's doing it again. This time with 2 notifications (when infact, I have none).

F12 console command:

  Hide contents

Object {timestamp: 1467697218730, messages: "0", notifications: "2"}

Link one:

  Hide contents

{"notifications":{"count":"0","data":[]},"messages":{"count":"0","data":[]}}

Link two:

  Reveal hidden contents

{"display_name":"straight_stewie","profile_image":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_02\/Kramer.jpg.2a687a0e7c4fb0aec4fe91338fbc9ee1.thumb.jpg.1bac7a523463ad17a9c78576e904267c.jpg","new_pms":0,"new_notifications":0,"notifications":[{"id":13310620,"title":"UberGamerKing commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017886","date":1467770302,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_06\/57526c063a53d_Linus_going_crazy_For_1_full_hour(1).gif.0f05ff1f0a88001fd63a4a52a9837990.thumb.gif.81d6af609b01aaf6a46448e5ad9cb270.gif","unread":false},{"id":13308986,"title":"aisle9 commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017783","date":1467768062,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_07\/kill-la-kill-wallpaper-4.jpg.31fa5d3bc95195467fcbf312fbc138b1.thumb.jpg.88f21c4a289013dde432c512f464b1e2.jpg","unread":false},{"id":13303832,"title":"colonel_mortis quoted you in a topic: Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8017427","date":1467762364,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13301989,"title":"colonel_mortis and thekeemo commented on Forum telling me I have a notification when I do not","url":"https:\/\/linustechtips.com\/main\/topic\/620068-forum-telling-me-i-have-a-notification-when-i-do-not\/?do=findComment&comment=8017262","date":1467761342,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/profile\/photo-thumb-10813.png","unread":false},{"id":13301859,"title":"Ryoutarou97 commented on Neighbor Trys to Shoot Down My Phantom 4!","url":"https:\/\/linustechtips.com\/main\/topic\/620521-neighbor-trys-to-shoot-down-my-phantom-4\/?do=findComment&comment=8017251","date":1467760206,"author_photo":"https:\/\/linustechtips.com\/main\/uploads\/monthly_2016_02\/l_sit_look.png.eaa035d4f838c366666755de55e27406.thumb.png.6b336041aee5f97f0f6d01017550151b.png","unread":false}]}

 

Interesting

There is a discrepancy wooo!

Thats that. If you need to get in touch chances are you can find someone that knows me that can get in touch.

Link to comment
Share on other sites

Link to post
Share on other sites

That's really weird - the two numbers are supposed to synchronise with each other regularly. When it's not working, can you open the dev tools again (F12) and switch to the network tab. On the filter bar (near the top), click XHR, so that only XHR is selected, then load the new page. Fairly soon after the page loads (and I think immediately before the sound plays and the notification count is incremented), you should get an entry that looks like

V8c.png

click it, then screencap both the left pane, where the URL appeared, and the preview (if in chrome or a derivative) or response (if in firefox) tabs, expanding all the nodes so that all the data can be seen. In the URL, you might want to blur out the csrfKey parameter, as I have done above, because the CSRF key would allow someone to give you a link to click that would perform all sorts of actions, such as making a post or logging you out. Alternatively, just PM it to me.

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

Ok. So it's been happening again repeatedly. So I've been doing what you said to do over and over and over, and nothing ever appears in the XHR window when the notification count pops up (this time as 1). I have timed it the last five times I've tried, and I am seeing that the notificiation count is falsely incremented about 20 seconds after I reload the page. Again, the XHR window doesn't register anything at all other than the  the "front_front_widgets.js..." that appears when the page is first loaded.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

29 minutes ago, straight_stewie said:

Ok. So it's been happening again repeatedly. So I've been doing what you said to do over and over and over, and nothing ever appears in the XHR window when the notification count pops up (this time as 1). I have timed it the last five times I've tried, and I am seeing that the notificiation count is falsely incremented about 20 seconds after I reload the page. Again, the XHR window doesn't register anything at all other than the  the "front_front_widgets.js..." that appears when the page is first loaded.

Do you have any other tabs (or windows for the same browser) open for the forum?

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, colonel_mortis said:

Do you have any other tabs (or windows for the same browser) open for the forum?

No.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

When you're experiencing the issues, can you open the dev tools and switch to the console tab, then run the following code:

ips.utils.cookie.set("lmgdebug", "1")

Then, leaving the console open, refresh the page and wait for it to play the notification sound. Once it's done that, can you copy and paste everything that has shown up in the console to here. You will then want to turn off debug mode, because it may make load times slightly longer and bypass the cache sometimes, so run

ips.utils.cookie.set("lmgdebug", "0", -1)

to disable debug mode.

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

Spoiler

Enabled logging
root_library.js.0c04b5c….js?v=f89201e012:13 Starting polling with interval 60s
root_library.js.0c04b5c….js?v=f89201e012:13 Loading: https://linustechtips.com/main/uploads/javascript_core/front_front_widgets.js.5e4800e4612b422f07f659e9a2bc37b0.js
root_library.js.0c04b5c….js?v=f89201e012:13 Loaded: https://linustechtips.com/main/uploads/javascript_core/front_front_widgets.js.5e4800e4612b422f07f659e9a2bc37b0.js
root_library.js.0c04b5c….js?v=f89201e012:13 Notifications: fetching from localStorage

I can't get the copypasta to look like it does in the console window, so here's a screenshot. 

diagForMortis.PNG

 

WARNING: There are two lines of stuff missing from this. Please refer to my post right below this one for the correct and full information.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

Link to comment
Share on other sites

Link to post
Share on other sites

6 minutes ago, straight_stewie said:

That's really weird. Just to check, does the problem still occur if you disable adblock? If so, do you have the LTT Notifier for Chome installed? If so, does disabling that make any difference?

If that doesn't help, just to rule out any chance of it being extension-related, can you close chrome fully (Ctrl+Shift+Q, it's not enough to just click close), then run chrome with the command line argument --disable-extensions (Assuming you're running windows, press Win+R, then enter

chrome.exe --disable-extensions

). The forum is supposed to log when it's playing a sound, and there are no traces of any sound being played in the logs that you have included.

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, colonel_mortis said:

The forum is supposed to log when it's playing a sound, and there are no traces of any sound being played in the logs that you have included.

That's probably because it doesn't always play a sound. This time it did not. This is a really funky problem here, the solution to which should be interesting.

 

Just now, colonel_mortis said:

That's really weird. Just to check, does the problem still occur if you disable adblock? If so, do you have the LTT Notifier for Chome installed? If so, does disabling that make any difference?

I do not have the LTT notifier installed. I will disable adblock for this site and see if that helps at all. If that does not help, I will run chrome with extensions disabled as you said. I'll report back later with the results.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

Neither fixed it. I disabled adblock and nothing changed, except for ads not being blocked. I ran chrome with extensions disabled. It runs much faster now, but the problem still occurs. Right on cue, 20 seconds after moving to any new page, the notification icon displays 2 notifications, does not play any sound (sometimes it does though), and there are no new notifications in the list.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, straight_stewie said:

Neither fixed it. I disabled adblock and nothing changed, except for ads not being blocked. I ran chrome with extensions disabled. It runs much faster now, but the problem still occurs. Right on cue, 20 seconds after moving to any new page, the notification icon displays 2 notifications, does not play any sound (sometimes it does though), and there are no new notifications in the list.

Has the clock on your computer ever been significantly in the future?

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

My time walks around randomly (both forwards and backwards), but my date is always the correct date. I do not explicitly know that the time has been significantly ahead of what it should be (right now it reads 12:52 am, ~10 minutes ago it read 1:10 pm, while the current time is 4:06 pm), but it's entirely possible that it has been significantly in the future at some point today.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, straight_stewie said:

My time walks around randomly (both forwards and backwards), but my date is always the correct date. I do not explicitly know that the time has been significantly ahead of what it should be (right now it reads 12:52 am, ~10 minutes ago it read 1:10 pm, while the current time is 4:06 pm), but it's entirely possible that it has been significantly in the future at some point today.

Ah. So it is possible for the time on your computer to go backwards?

I think that is the cause here. The number of notifications that you have is stored along with a timestamp, and if the difference between the current time and the time when they were stored is less than 20s, it just uses the stored version. That allows you to have multiple tabs open without DoSing the site. However, if your clock runs backwards, that will mess things up, and it will always use the cached version.

To work around it, either make sure your clock is set properly (set it up to use NTP with a reliable server like pool.ntp.org), or, when it's messed up, open the dev tools and run

ips.utils.db.remove( 'notifications', ips.getSetting('baseURL') )

That should force a refresh against the server, and it should work normally.

 

Let me know if it works.

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

7 minutes ago, colonel_mortis said:

To work around it, either make sure your clock is set properly (set it up to use NTP with a reliable server like pool.ntp.org)

And that's the solution right there. Now all I have to do is schedule a task to synchronize the time more often.

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×