12

I've asked a question and answered it myself a long time ago. Today I got a notification that someone added a comment to my answer, and I wanted to add a comment to that myself (saying that I have not used this particular technology in a long, long time, so no idea how correct all the info in the answer still is). But if I click on any "Add a comment" link under my question or any of the answers, I'm just being redirected to the question, and cannot add a comment - I don't get to see the comment box at all.

This is not the case for any other questions or answers where I try to "Add a comment", it works the normal way in other places. So is this a very particular bug or is it by design that I should not be able to comment anymore? (Maybe I've used up my allotted number of comments for this question + answers? There is no such thing, right??)

I tried both Firefox (version 98.0) and Chrome (version 99.0.4844.74) and the behaviour is the same in both browsers. I'm on Fedora 34.


From @mickmackusa:

I am also experiencing this same bug at stackoverflow.com/q/797251/2943403. I want to reply to a comment under my answer but the Add Comment link doesn't open a comment box for me to type into. I cannot flag, follow, downvote, or upvote any answers. I cannot Add Another Answer. I cannot close, star, upvote, or downvote the question. I can edit and share posts; and protect the question. The grey icons at the top right corner of the page are either non-responsive or they change the url when clicked.

I've reproduced this on my laptop's chrome browser 99.0.4484.82 and my mobile's chrome browser 99.0.4484.88.

I posted an answer to the page nearly 3 years ago and received a message under the answer today. I've never experienced this bug before.

In the browser console, there is a javascript error @ full.en.js?v=fbc131b52052:1:

Uncaught TypeError: Cannot read properties of undefined (reading 'dispatchEvent')
at full.en.js?v=fbc131b52052:1:136703
at Array.forEach ()
at A (full.en.js?v=fbc131b52052:1:136559)
at E (full.en.js?v=fbc131b52052:1:133273)
at full.en.js?v=fbc131b52052:1:153180
at Object.init (full.en.js?v=fbc131b52052:1:153973)
at Object.StackExchange.question.fullInit (full.en.js?v=fbc131b52052:1:120502)
at Object.init (full.en.js?v=fbc131b52052:1:69926)
at Object. (55559565:57:40)
at i (jquery.min.js:2:27449)

enter image description here

18
  • 2
    Seems to be related to your account, all "Add a comment" links on that question work for me and open a textbox.
    – BDL
    Commented Mar 24, 2022 at 9:32
  • 4
    Try reloading. That's usually a JS that didn't fully load/execute. If that doesn't work, check the browser JS console for errors.
    – yivi
    Commented Mar 24, 2022 at 9:34
  • Reloading doesn't help, unfortunately. I do see the links, clicking them just does not give me the textbox but a redirect to the question instead.
    – Josien
    Commented Mar 24, 2022 at 9:36
  • 2
    Have you checked the JS console in the browser for errors?
    – yivi
    Commented Mar 24, 2022 at 9:54
  • Tried that just now. On any other question I tried I see a 204 POST and 200 GET in 'Network' when clicking the "Add a comment" link. On the above question/answers I see... nothing, both in 'Console' and 'Network'. So this all seems to point to some user-specific boundaries, as other users do get a textbox?
    – Josien
    Commented Mar 24, 2022 at 10:18
  • 4
    It's unlikely there are user-specific constraints. I would still bet on a local issue loading JS assets. You should check your JS console when loading the page, see if anything fails to load or if there are JS errors when the page is rendered. By the time you click on the "add a comment" link, it's likely too late.
    – yivi
    Commented Mar 24, 2022 at 10:20
  • 2
    You're right @yivi, I do see an Uncaught TypeError: e.PostElement[0] is undefined error in the 'Console' when loading the above question specifically. Do you have a suggestion how I could fix this locally?
    – Josien
    Commented Mar 24, 2022 at 10:45
  • Not sure. I would check if any of the requests that happen during the page load fail one way or another.
    – yivi
    Commented Mar 24, 2022 at 10:48
  • 2
    Strange that it happens in two browsers, that means it's likely not caching. Are they old versions of these browsers by any chance? I've seen other meta posts about Stack Overflow no longer working because people were using an old OS for which there were no newer browser updates.
    – Gimby
    Commented Mar 24, 2022 at 10:52
  • I use Firefox version 98.0 and Chrome version 99.0.4844.74, on Fedora 34. (I'll add this to the question.) So pretty recent versions. It's an interesting issue :-)
    – Josien
    Commented Mar 24, 2022 at 10:57
  • 1
    Could be regional cache. This has happened before where some regions (e.g., Europe) get different JS than others. And one is broken because the cache for that region is not yet updated or something along those lines.
    – VLAZ
    Commented Mar 24, 2022 at 11:05
  • 1
    That has also recently happened, didn't it? That the site wasn't being properly updated on all the CDN nodes.
    – Gimby
    Commented Mar 24, 2022 at 12:55
  • 3
    I am experiencing this exact same bug at stackoverflow.com/q/797251/2943403. I want to reply to a comment under my answer but I cannot. I cannot flag, close, or follow any posts. I cannot Add Another Answer. I can edit, protect, and share posts. I cannot star, upvote, or downvote the question. I've reproduced this on my laptop's chrome browser and my mobile's chrome browser 99.0.4484.88. So how do our two experiences intersect? Commented Mar 30, 2022 at 8:17
  • 3
    I actually experienced this yesterday myself but refreshing fixed it so I thought it was just a page load error and toddled off.
    – Catija Staff
    Commented Mar 30, 2022 at 12:22
  • 1
    @mickmackusa So we both have it consistently with our own questions and/or answers? And other users have it sometimes but it 'goes away' after a refresh... I can check my error message to see if it looks somewhat like yours.
    – Josien
    Commented Mar 30, 2022 at 14:01

1 Answer 1

9

Thanks for the report and all the debugging in the comments!

Just pushed up a fix for this which is live in prod.

I definitely see where the exception is being thrown and it's just a case of not handling nulls properly.

I wasn't able to repro this locally, but wanted to push up improved null handling first to see if that cleared things up. I'll still keep fishing around, but gently holler at me here if anyone's still experiencing this issue and I'll dive back in.

2
  • 2
    I can verify that the bug has been removed in my case. Commented Mar 30, 2022 at 22:59
  • 2
    Yes, I can confirm commenting works again for me for that particular question and its anwers! Thanks for fixing!
    – Josien
    Commented Apr 1, 2022 at 9:56

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .