如何处理不可重现的错误
您是否曾经发现自己处于这样的境地——客户报告了错误,但您无法重现该错误。即使是 QA 团队也无法重现该错误。我们的桌面应用程序(C#,Windows 窗体)面临着这样的情况。您建议我们应该做什么来重现该错误,或者跟踪生成该错误的场景。
Did you ever find yourself in this position - a bug is reported by the client but you are unable to reproduce the bug. Even the QA team is unable to reproduce the bug. We are facing such a situation with our desktop application(C#, windows forms). What do you suggest we should do to reproduce the bug, or track the scenario which generates the bug.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
是的,这是一种常见情况。
我发现处理这种情况的最佳方法是在日志文件中记录尽可能多的内容,并让客户将日志文件发送给您进行分析,以及他们对问题发生时正在执行的操作的描述。客户的描述通常非常不完整,并且遗漏了有关错误发生时他们正在做什么的重要细节。详细的日志可以帮助填补故事中的漏洞。
如果您足够幸运,日志文件包含堆栈跟踪,则通常可以推断出错误的可能原因,即使这是一个很少发生且您无法自己重现的错误。在这种情况下,对受影响代码的代码审查可以揭示代码设计中的缺陷,并建议一种不太可能失败的替代方法。
Yes, this is a common situation.
I find that the best way to handle this situation is to log as much as possible in log files and get the customer to send the log files to you for analysis, as well as their description of what they were doing when the problem occurred. The customer description is often very incomplete and misses out important details about what they were doing when the error happened. A detailed log can help fill out the holes in the story.
If you are lucky enough that the log file includes a stack trace it is often possible to reason about possible causes of the error even if it is a rarely occuring bug that you have not been able to reproduce yourself. In this situation a code review of the affected code can reveal flaws in the design of the code and suggest an alternative approach that is less likely to fail.
这一切都取决于您面临的错误类型(逻辑、用户界面、多线程或实际用户)。
重现所需的所有信息
错误。
向您展示如何重现该错误,或者至少发送一些有关如何完成该错误的屏幕截图。
为了尝试掩盖错误,请尝试证明它的存在。
This all dependes on what kind of bug you are facing (Logic, User Interface, Multi Threaded, Or actual User).
all the required info to reproduce
the bug.
show you how to reproduce the bug, or at the least send some screen shots of how it was done.
to try and cover the bug, try proving that it is there.