Questions tagged [code]
Questions relating to code that appears in a question or answer, such as answers which are entirely code. Do not use this tag for questions about code formatting; use [code-formatting] instead - and NEVER EVER USE THIS TAG TO ASK A PROGRAMMING QUESTION ON META!.
141
questions
24
votes
4
answers
653
views
Is it link-only when there is a link and description but no code?
As one of your newest moderators, I've been handling a bunch of not-an-answer flags. One NAA flag was for this answer:
The flag comment said that the link was broken. When reviewing the flag, I:
...
2
votes
1
answer
216
views
Is it ever ok to put an image of code in a question? [duplicate]
I have been staunch in my opinion of Posting images of code
I will 100% of the time either downvote the question or flag to be closed.
My question is, am I being too rigid? We've given plenty of ...
-8
votes
1
answer
163
views
Unable to post code and error on Stack Overflow (while asking question) - {} not seen, whitespaces and Ctrl+K doesn't work
I wanted to post a question on Stack Overflow.
I tried posting a code with its error. But, it showed some indentation error in code.
I was not able to find any {} above to resolve the problem. ...
12
votes
0
answers
146
views
Why do we still have strange escape backslashes appearing in question code?
I was wondering why would users have that weird backslashes when pasting code. Now I noticed that this is a persisting issue1, 2, 3. Why hasn't this been solved yet? See here. I've edited several ...
-16
votes
2
answers
175
views
How should I write my question about margins not working?
I have a question about my Stack Overflow post: Why are margins not working in my HTML file and how can I fix that?
I have a problem with my HTML file, but I can't figure out how I should ask about it....
2
votes
1
answer
217
views
Code searching at the end of 2022
Tl;Dr:
As of November 2022, is Google still the best option to search for posts including specific code methods?
I'm trying to find questions with code generated by the Google Sheets Macro Recorder. ...
-17
votes
2
answers
273
views
Should I edit posts with improved style? [duplicate]
I edited this answer on Stack Overflow and improved its format, so it's easier to read and conforms to Python best style/format practices. Is it a good edit or not?
It used to look like this
return ...
3
votes
0
answers
109
views
Why are strange backslashes (escapes?) suddenly appearing in rendered code? [duplicate]
I've noticed that lately strange backslashes are appearing more and more frequently in edited code.
Here is another example. Is this a user failure or a bug in the site's code rendering?
37
votes
0
answers
593
views
Punctuation characters being escaped in code
For the past couple of days, it seems that when users paste code into their questions, but don't put it into a proper code block, many punctuation characters are being automatically escaped with ...
41
votes
6
answers
2k
views
Should we edit a question to transcribe code from an image to text?
Context: "How to call a method from a class referenced as a string?"
More general context: how do we educate occasional users, or new users, to the best practices to follow when posting a ...
20
votes
2
answers
2k
views
Answers with large amounts of code (whole scripts)
I answered a question (since closed: "This question needs debugging details. It is not currently accepting answers," and deleted) a little while ago, and it really is a good answer, because ...
-9
votes
2
answers
244
views
Piece-of-code-highlight/error highlight for Stack Overflow (and possibly others)
Similar questions
I have checked some previous questions/answers like this one: Highlight Line of Code
But I did not like the answer and this can be troublesome.
Proposal
Let's say I post a big (but ...
1
vote
0
answers
154
views
While editing a question, this piece of text causes the error: "contain code that is not properly formatted"
I am editing one of my questions on Stack Overflow.
It raises an error:
Your post appears to contain code that is not properly formatted as
code.
After some digging, I find it is about this text:
(...
11
votes
1
answer
422
views
Should I reject or approve this code edit suggestion? [duplicate]
I've already read main question on this topic, When should I make edits to code? and this one too, still I'm not sure what to do with this edit suggestion:
https://stackoverflow.com/review/suggested-...
77
votes
9
answers
6k
views
Should questions about obfuscated code be off-topic?
Per another Meta it came to our attention that there was a user posting potentially malicious code. There's no real rule about that, but, for unrelated reasons of moderation, the account that posted ...