16

I have recently started actively answering and moderating Android questions. I have run into a lot of questions of the style:

My application is crashing, (sometimes, but not always) here is the code and (sometimes, but not always) here is the stack trace.

It's obvious that when code and stack trace are missing, the proper use is to comment and/or flag as "insufficient information". But supposing the relevant information is present, what is an appropriate response? I have sometimes:

I also have seen all these behaviors from a lot of users (the close vote queue is typically filled with these). Are there any official (or unofficial) guidelines for dealing with these questions? I couldn't find anything about this issue, either in the FAQ or in meta.

6
  • 2
    It looks to me like this is a title/naming problem & if they are in fact coming across a "new" problem to SO they should be answered otherwise flagged as duplicate?
    – GPPK
    Jun 5, 2014 at 8:21
  • Doubt there are any real guidelines about but I'd say you've about nailed them.
    – OGHaza
    Jun 5, 2014 at 8:36
  • Maybe narrowing the possible error scope like we did for meta.stackoverflow.com/questions/254782 makes sense, otherwise I doubt that the 30k char limit of an answer is enough to write a good generic "debugging on android" guideline.
    – PlasmaHH
    Jun 5, 2014 at 8:50
  • @PlasmaHH I beg to differ with you on that. The "Unfortunately MyApp..." answer provides more than enough information in my opinion to solve 90% of the Android posts like that. Android is very easy to debug, if you know there are things like stack traces etc. Jun 5, 2014 at 9:53
  • @RichardLeMesurier: It might be different for android development, but in my experience, people needing the guide to get to something like a stacktrace of that question also won't get far on their own having that stacktrace even after reading "What is a stacktrace". The bugs causing them are just so numerous and different that any shortened guideline would more or less read like "look for something wrong".
    – PlasmaHH
    Jun 5, 2014 at 9:59
  • 1
    At the end of the question/answer you linked to. "If you've found your Exception and the line where it occurred, and still cannot figure out how to fix it, don't hesitate to ask a question on StackOverflow." So I don't think it should be voting is as a dup.
    – Pat
    Jun 5, 2014 at 12:30

2 Answers 2

17

These days I'm ecstatic with a code snippet and stack trace as documentation in a question. They beat the dreary "it doesn't work" or the lazy screen shot by a long, long mile. Such a question often googles very well by querying just one or two lines in the stack trace.

If it is not a duplicate it certainly deserves an answer. Only fall back to a hint in a comment if you can't nail it down. Ask for an SSCCE if it is an "impossible" exception.

4
  • "Unfortunately, MyApp has Stopped". And? What would you like us to do about it? Jun 5, 2014 at 9:37
  • 3
    Good point with googling the stack trace - that's something that even if didn't help me directly, very often it led me to a right track in solving crash problems.
    – BartoszKP
    Jun 5, 2014 at 9:42
  • The fact that there are awful-er questions shouldn't be a factor... but I guess your position is very sensible. I'll try to follow this rule from now on.
    – matiash
    Jun 5, 2014 at 21:38
  • It is a simple rule. Do you help one person or do you help a hundred that can google it? I make time for the one-person question but it better be something that I can learn something from. Which makes two. Jun 5, 2014 at 22:26
4

I was a big fan of Niek's Unfortunately MyApp has stopped. How can I solve this? and would have started using it all over.

But then I was told off by one of the higher reps around here - it turns out that this might not be acceptable.

However I still back the idea, and would love it if the powers that be enabled us to do it like that. Niek's post is very helpful, and really gives all the info that these new developers need in order to fix their own code.

4
  • 1
    Would it be appropriate to add other answers to solve other very common issues? They would technically all be valid answers to the generic "Unfortunately, MyApp has stopped". Referencing Fragment views from a parent Activity springs to mind. Jun 5, 2014 at 10:42
  • 1
    "But then I was told off by one of the higher reps around here - it turns out that this might not be acceptable", could you expand on why? It seems to me that that Question/Answer would help out a lot of people who've just started programming in Android/Java and are (maybe) new to SE.
    – TMH
    Jun 5, 2014 at 11:40
  • @TomHart Exactly what I thought. Unfortunately I can't remember which meta-thread my reference comes from. Just the disappointing disapproval about said post. Jun 5, 2014 at 12:39
  • 2
    @RichardLeMesurier This one? Jun 5, 2014 at 14:22

You must log in to answer this question.

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