33

What does if __name__ == "__main__": do? has half a million views and some excellent answers.

Unfortunately, while the question title asks one (clear, good) question, the question body asks two completely different questions: what if __name__ == "__main__": does (the question in the title), and what *args means in a function definition. The OP has exhibited a program that happens to use both of these constructs, but there is no actual connection between them.

As a result, while most answers (including the accepted one) address only the primary question and don't acknowledge the secondary question's existence, some people have posted answers that respond to the secondary question. This has caused confusion, and it seems very unlikely that anybody seeking an answer to the second question would even find the page in the first place given that the title indicates it is about a completely different question.

The references to the secondary question are just noise, and I'd like a mod to clean them up. If a mod were to do all of the following things...

... then all trace of there ever having been a secondary question would be purged! Given that nobody looking for an answer to the secondary question on Google is ever going to find that page, I reckon this would be a straightforwardly good thing; it's just removing irrelevant noise.

But I realise this might be a controversial thing to ask for, because:

  • I'm asking for the question's meaning to be changed (or at least for it to be reduced in scope) by an editor
  • I'm asking for the deletion of highly upvoted posts

Would it be right for a mod to take the actions I'm suggesting here?

12
  • 3
    +1 for it being a good discussion if these are things mods should be doing. However, I don't see what it's really hurting. The answers addressing the initial/primary question all seem to be heavily upvoted and at the top. Also, if you want your comment deleted why don't you...delete it? See, folks. voting on meta isn't always about agreement/disagreement :P
    – codeMagic
    Commented Jul 9, 2015 at 18:16
  • 1
  • 2
    Is this something that mods have to do? Couldn't we the community of stackoverflow in order to form a more perfect Q&A exercise our comment/downvote/edit rights and take care of it? Commented Jul 9, 2015 at 18:18
  • 7
    @NathanOliver no, only somebody who has the power to unilaterally delete answers can fix this. It would be entirely wrong for you or I to make an edit to the question that invalidates existing answers while leaving those answers in place.
    – Mark Amery
    Commented Jul 9, 2015 at 18:19
  • 3
    @codeMagic "if you want your comment deleted why don't you...delete it?" - I want it deleted if and only if it's made obsolete by moderator action; as long as the problem with the question remains, so too should my comment pointing out the problem.
    – Mark Amery
    Commented Jul 9, 2015 at 18:21
  • 1
    @MarkAmery the third way: don't pose a meta question asking moderator to do something, pose a meta question that asks for community feedback and direction. We often act based out of consensus achieved on meta in situations like this.
    – George Stocker Mod
    Commented Jul 9, 2015 at 18:22
  • 11
    @GeorgeStocker to be clear: this is a post asking for community feedback and direction - my intent with this question isn't just to instruct you to go and do what I think should be done, but to get feedback on whether what I think should be done is reasonable (and then perhaps have a mod do it). I've edited the title to say "should" instead of "can" so it sounds less like an order.
    – Mark Amery
    Commented Jul 9, 2015 at 18:24
  • 8
    @GeorgeStocker I think he is kind of doing that with "Would it be right for a mod to take the actions I'm suggesting here?" though I agree the post could have been more directly geared towards a discussion with a better title and other changes. But he was listing what he thinks should be done and wants to know if it's appropriate.
    – codeMagic
    Commented Jul 9, 2015 at 18:25
  • 3
    Overall it might be better to have a "split" function where a new question can be peeled off an existing, composite question. But I don't know how likely that is to happen.
    – Rob Grant
    Commented Jul 10, 2015 at 14:33
  • 1
    I think George's point is that you're turning this into an X/Y problem potentially by saying "Should a moderator do...". Better is to present the problem in itself - "Here's a popular question that's really two questions, what do you thinik?" - and let the answer come on its own. (Personally, I'd be all for changing the question ourselves, then flagging the two irrelevant answers with a custom flag pointing back to this question.)
    – Joe
    Commented Jul 10, 2015 at 15:21
  • @Joe if there were available courses of action, sure, but as far as I can tell the only sane ones are 1) do nothing or 2) do what I suggested. I wanted community feedback on the choice between those options rather than upon the situation generally; if I'd asked for the latter, the response would probably be "yeah, it sucks, but what can you do?", which wouldn't be helpful. It's possible I'm being dim and missing some third way, of course - but there's nothing stopping you from posting an out of the box idea if you have one.
    – Mark Amery
    Commented Jul 10, 2015 at 15:23
  • I just did suggest a (slightly) different solution... Anyway, I think this is mostly a semantic discussion, but the point is that you posted "Should a mod do ...". If you think a mod should do something, flag the question. Maybe you really meant "Should we ask a mod to do...", but I still think "Here's a question that seems problematic" is the right way to ask this question, or, "What is the right course of action when you find a question that has a lot of views and really two questions in it?".
    – Joe
    Commented Jul 10, 2015 at 15:38

2 Answers 2

5

The answers have been deleted.

The OP of https://stackoverflow.com/a/419192/1709587 hasn't been around for nearly 3 years.

The OP of https://stackoverflow.com/a/420010/1709587 is still active, but has a 231 net score for an answer addressing the main question.

Neither of them will lose any points from their time spent answering. As Martijn has pointed out in a comment on davidism's post - if those posts are suitable to be added to the canonical question - then do so (better yet - invite them to do so).

In the mean time - go forth edit!

13

The question should be reworded to ask one question, and the answers should be cleaned up appropriately.

There is already a canonical Q&A (probably more than one) about the second question: What does ** (double star) and * (star) do for parameters?. Answers can't be migrated individually, and while they are good answers, the existing answers on this question do more than enough to cover the topic already.

While it's unfortunate that a few answers will be deleted, remember that the goal of this site is a high quality Q&A. We delete things all the time, and users lose some points because of it. In this case, the users will keep the points since the answers are >3 score older than 60 days.

8
  • Note that the authors of the existing answers won't lose rep - you keep your rep when a post with 3 or more upvotes is deleted.
    – Mark Amery
    Commented Jul 10, 2015 at 14:59
  • Because of the age of the answers (net 50 & 38 last time I looked) - the OPs would keep reputation points.
    – Jon Clements Mod
    Commented Jul 10, 2015 at 14:59
  • I'm fine with this.
    – Aaron Hall Mod
    Commented Jul 10, 2015 at 14:59
  • @MarkAmery that's not the criteria for keeping rep... there's a certain time window... If you posted even something that got you 200 rep a day for the next fortnight and it's deleted, you'd lose the rep...
    – Jon Clements Mod
    Commented Jul 10, 2015 at 15:01
  • It's not all about rep, though. Could those answers be migrated to the canonical question? (assuming a good fit) Or an alternative could be to split into two questions and keep all answers as mentioned above.
    – aw04
    Commented Jul 10, 2015 at 15:02
  • @JonClements apparently, there's a score and an age criterion that need to be satisfied in order to keep your rep: meta.stackexchange.com/a/141682/200582. We were either both wrong or both right, depending upon how charitable you want to be. :)
    – Mark Amery
    Commented Jul 10, 2015 at 15:03
  • @MarkAmery I'll split it with you? :p
    – Jon Clements Mod
    Commented Jul 10, 2015 at 15:06
  • 1
    @aw04: they cannot be migrated. Are they that much better than what is already there that to delete them would be a net loss? Then copy them across as community wiki answers crediting the original author.
    – Martijn Pieters Mod
    Commented Jul 10, 2015 at 15:39

You must log in to answer this question.

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