Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Better Information on Editor Error Messages

Discussion in 'General Discussion' started by frosted, Mar 23, 2017.

  1. frosted

    frosted

    Joined:
    Jan 17, 2014
    Posts:
    4,044
    Whenever I run into a new editor error message, I google it.

    Again and again, I come up with a forum thread or something with.
    • "I'm getting this error"
    • "hey me too"
    • "anyone know what it is?"
    • "i'm getting this error also"
    • "anyone figure it out"
    • ...
    And that's it.

    Giving information on errors is tricky and difficult, I'm aware. Many times an error message may have many different root causes. But is there any way to gather up information on error messages into some kind of knowledge base, ideally with some kind of direct commentary from actual UT guys.

    Some error messages have to be pretty well known, for example, I have gotten the "The profiler is out of samples..." error pretty consistently for least a year or two in multiple projects on different hardware. The best part of this error is that it only happens if the profiler is closed, if the profiler window is open I've never seen it happen.

    There are a bunch more. Yesterday I started getting a 'textureatlas.length != detailprototype.length' error. These kinds of things don't come up all the time, but they aren't super rare either.

    There will always be errors and bugs, that's fine. But we need a better method for identifying potential causes, finding the problems and dealing with them.
     
    Martin_H, RavenOfCode and Ryiah like this.
  2. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    20,952
    How many threads were simply the OP failing to read the error message? Because a number of the threads I've assisted with have been people ignoring the error message that had the actual answer in it.
     
    Last edited: Mar 23, 2017
  3. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,614
    Yeah... the number of times I've helped people by simply telling them to "read the whole error message" until they actually do is nuts.

    Also, "read the first error message" and "fix the errors one at a time" are both pretty critical.

    To me the biggest one is having useful error messages. "Null reference on line X" is actually pretty useless unless you're the person who wrote the code. With that in mind, as a developer I try to pre-empt likely configuration errors and provide useful, instructional messages about them.

    If I know I need to be provided references to certain things, for instance, at the relevant point of the script I'll check to see if they're there, and Debug.LogError("explain what is missing", this); straight away if needed. That way my designers find out about things much more quickly with less testing, and when an error occurs they know exactly what needs to be addressed to fix it. And it's not just for other people, those messages help me, too.

    Basically, the configurable aspects of my components are a part of their user interface (for myself and designers) and should be treated as such.
     
    Last edited: Mar 23, 2017
    Kiwasi and Ryiah like this.
  4. N1warhead

    N1warhead

    Joined:
    Mar 12, 2014
    Posts:
    3,884
    I think once in my life with Unity I've had an error that had nothing to do with what I've done, it was just a breaking bug in general.. 99 out of 100 times the error message is clear, and if it isn't very clear 99 out of 100 times someones asked the same question online, so generally isn't hard to find what something else.

    #EDIT

    You want to complain about error messages? Tell Unity and Monodevelop to actually give the wrong line errors for Shaders... It's bad enough it doesn't pop anything up for you, so you just have to know what you're doing, but even if you mess up and it says line 20, it can be really line 1 or 45 that has the problem instead.
     
    RavenOfCode likes this.
  5. frosted

    frosted

    Joined:
    Jan 17, 2014
    Posts:
    4,044
    That's cool I get them pretty frequently.

    It doesn't matter at all who's fault it is, what matters is that right now if you get an error message from the editor, most of the time you're out of luck getting more information on what the causes are. Often these errors are minor annoyances requiring restarts or something and not worth full on bug reporting.

    As a user, it'd be extremely helpful to have a single location where you could find info on an error message and it's history.

    Perhaps from Unity's side, it'd be helpful to have a single location where you could 'tag' on extra info about what you were doing when you got an error message. This may help them track down a problem.

    Finally, if there is an open bug report associated with an error message - having this also associated would be great.
    - "Oh they fixed this in 5.5.1! Time to upgrade!"
     
  6. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,614
    No, they are worth a bug report. If things aren't reported then how is anyone going to know to fix them? Or, if they don't know how many people get it why would they prioritise it highly enough to get fixed?
     
  7. frosted

    frosted

    Joined:
    Jan 17, 2014
    Posts:
    4,044
    I would expect their analytics suite to automatically report any assertion failure or other error message automatically.

    A bug report like "hey I don't know why I got '[...]' error" is not helpful or worthwhile for anyone.

    This is actually part of the problem. Because someone on Unity's end needs to manually sort bug reports depending on the hand written description. Spamming them with "hey I got the profiler bug again" every time I close the profiler isn't going to do anything but clog up their report processing.
     
    Martin_H likes this.
  8. N1warhead

    N1warhead

    Joined:
    Mar 12, 2014
    Posts:
    3,884
    While I can't complain that it would certainly be nice to have a place to find all potential bug codes, but I don't think it's feasible unless Unity wants to spend time on writing out potentially hundreds of thousands of potential errors. Then cross referencing combinations of problems that can cause these errors. It's not simple thing to document this many potential problems this late in the game. If they started off doing that then that would be different.

    But new versions = new potential outcomes to what will cause something.

    EDIT:

    The problem is, person A and person B can do the same exact thing, but person C do it and get the error... I mean literally the same exact thing, why did it happen for person C but not A & B? It's just not as simple as documenting it, because sometimes there's bugs that just aren't ever found and eventually get's accidentally fixed in a later version.
     
  9. frosted

    frosted

    Joined:
    Jan 17, 2014
    Posts:
    4,044
    They've started to use more assertions in their editor validation - building an automated process to generate a 'bug' page for each assertion every build is actually realistic! It could even cross reference by release build #!
     
  10. N1warhead

    N1warhead

    Joined:
    Mar 12, 2014
    Posts:
    3,884
    Oh nice, I didn't know that - I rarely if ever run into bugs. Been over a year lol.
     
  11. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,614
    Two things.

    First, along with the automated data included in the report maybe it is helpful? How do we know?

    Secondly, if they tell us that they don't want that kind of report then I'll heed that, but until then they have a bug report system to collect information on bugs, so if I have bugs I am going to use that to tell them. It's up to them to decide how best to filter and manage the info they get on the other side, and they're going to be more informed about how to best do that than I am. If I'm pre-deciding what info to send then I'm distorting their vision of what bugs are in the wild before they even get to see it.

    Sure, but reporting it at some point with "How often does this happen?" set to "Always" or "Often" would be great. That's why that option is there - so that we can give them the relevant information without spamming them with it.