11

I'm getting an error when trying to edit this post:

https://stackoverflow.com/a/22944075

Even if I make zero changes, when I click "Save Edits" the page scrolls up to the text box and throws the error "Your post appears to contain code that is not properly formatted as code" without even so much as showing me where the error is! See exhibit A:

enter image description here

Any idea what's going on here?

13
  • Note that when I tried to introduce an edit, I succeeded. So maybe it has something to do with reputation?
    – HamZa
    Commented Nov 12, 2017 at 12:21
  • 2
    You do face all the normal editor restrictions and checks till you earn edit privileges on the site
    – Suraj Rao
    Commented Nov 12, 2017 at 12:37
  • 3
    @SurajRao The error suggests I have a mistake in formatting, not that I do not have adequate reputation to edit the post.
    – jaytea
    Commented Nov 12, 2017 at 13:10
  • 3
    My comment was more in response to HamZa's comment. @jaytea since you don't have edit privileges, you can suggest edits and editor restrictions are in place and these restrictions will not come into play when users with edit privilege are editing
    – Suraj Rao
    Commented Nov 12, 2017 at 13:12
  • Otherwise I do agree that showing this message seems odd here
    – Suraj Rao
    Commented Nov 12, 2017 at 13:13
  • 6
    SO/SE performs checks on the current state of the text in the editor. The checks must pass in order to not get that notification and various others. The checks don't test just the changes you are making, but the entire current text. Such checks change over time and by privilege level (reputation). Thus, you can encounter questions where it's not possible to save the unchanged text, even if you have full editing privileges (>2k rep). An example of such is when a site is blacklisted. You can't save an edit to a post which contains the blacklisted site without removing the site from the post.
    – Makyen Mod
    Commented Nov 13, 2017 at 2:32
  • 2
    @Makyen This is certainly good information, but is it useful? I don't see how it's possible to reconcile the error message I see with the fact that HamZa is able to edit the post with unchanged text and I am not. Do you not agree that this is evidence of a bug?
    – jaytea
    Commented Nov 13, 2017 at 5:50
  • @jaytea, It's unclear if it's a bug, feature, or misfeature. Note that the fact that the question is locked is also a factor, as it's not possible to edit the answer at all for users with very low reputation (e.g. 21). When I attempted to edit the answer with the account I use for low-rep testing, it produced the error: "Question is locked.", and did not even show the edit interface.
    – Makyen Mod
    Commented Nov 13, 2017 at 5:59
  • @Makyen So it is possible that one of StackOverflow's features is to report erroneous error messages to its users?
    – jaytea
    Commented Nov 13, 2017 at 6:23
  • 1
    @jaytea Without knowing what it's detecting/reporting in more detail, it's not possible to say if it's a bug, or a poorly designed exception notice which doesn't tell the user enough information to pinpoint the problem.
    – Makyen Mod
    Commented Nov 13, 2017 at 7:10
  • 3
    @jaytea The two can be reconciled if you assume that the "poorly-formatted-code" filter has a rep limit. HamZa has high rep, so could potentially be exempt from such a filter.
    – mbrig
    Commented Nov 13, 2017 at 15:14
  • @mbrig Indeed that makes sense and seems to me to be the most likely scenario.
    – jaytea
    Commented Nov 13, 2017 at 17:44
  • I just encountered the same problem with this post: stackoverflow.com/a/60676356/5472354 I cannot edit it unless I remove the quote. Why is that? Does it also have to do with reputation?
    – mapf
    Commented Mar 18, 2020 at 14:30

0

You must log in to answer this question.

Browse other questions tagged .