Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [debugging]

Debugging is the process of examining the state of a program - generally with a debugging tool - while it is running and attempting to find bugs that cause it to behave abnormally.

14
votes
3answers
4k views

How to affect priorities to bugs to developers and treat them accordingly?

We have a bug process that is currently being worked. We have 3 levels of bug: P1 bug: Bugs that prevents users from working. They must be solved on the spot. P2 bug: Bugs that are impacting but ...
0
votes
0answers
23 views

Logfile correlation finder (for j4Log)

I'm currently analyzing a problem in a old "distributed" system, that only occurs sporadically - as the system does not support other means of debugging help I have to rely on the logs (I did not ...
-1
votes
1answer
122 views

Debugging code in production?

I've come across a problem that doesn't occur in our development environment or test environment, but does occur in our production environment. Obviously, this environment is pretty locked down, and ...
0
votes
0answers
44 views

Are there any implementations of a AOP framework that can weave aspects into a running program

Using Aspect Oriented Programming (AoP) for logging and debugging seems to be a rather established technique. That got me thinking, are there any software packages that enables us to weave aspects ...
1
vote
2answers
186 views

Developing and debugging microservices locally

The use case: I am working on a microservice based architecture and I am wondering how I am supposed to debug a microservice (with my IDE attached to it) on my local machine where I develop it. The ...
-1
votes
1answer
68 views

What kind of of tools/architecture would work well for a student team competing in a robot soccer competition?

The scenario is as follows. There is a PC running a complex piece of AI software wirelessly controlling a number of soccer robots. This software is written and maintained by a team of students that ...
1
vote
2answers
771 views

How to deal with exceptions in DLLs?

I recently started working on an existing project written in C++ Builder. The application consists of a MainModule that loads LOTS of modules (DLLs). The MainModule itself is a DLL (there is a small ...
5
votes
3answers
473 views

Better conditional debugging pattern?

Given the need to log only in debug mode the easiest way would be to use if conditions: def test(x, debug=False): if debug: print(x) # ...Some more code if debug: print("...
1
vote
2answers
98 views

Testing and Debugging Techniques vs. Rice's Theorem

As far as I got it correctly, as a result of Rice's theorem, the equivalence of two programs is generally not decidable. Nevertheless, there exists a wide variety of testing and debugging techniques, ...
1
vote
3answers
470 views

Difficulties in reading code

I don't have more than 6 months of experience and I am a little lazy . I work on Android platform . I have very good skills in understanding what is happening in general . The problem is that I don't ...
-3
votes
1answer
73 views

Handling different versions of a program and benchmarking with OO

Note: I'm not sure if the way I phrase the question initially will fit 100% on this board, so please help me to focus on the main point. Scenario: You develop an algorithm or a neural network that ...
2
votes
1answer
118 views

Easy way to debug platform-specific issues of non-GUI software on Windows?

I'm maintaining a couple of software repositories (C, C++ essentially) which I want to also run - or let's start with at least build - seamlessly on Windows. Now, my desktop machine does not have ...
4
votes
2answers
114 views

Logging/Debugging of computer vision apps

When I'm writing an computer-vision program (using OpenCV and Python) I need to print/show a lot of intermediate results in form of images (using cv2.imshow(..)) for debugging purposes to find out ...
2
votes
2answers
160 views

How to debug in visual studio 2015 when your web app. need to login via another web app?

My web app (under development) need to login via http://devWebServer/ExtApp/login.aspx After login via address above, it will pass cookie to http://devWebServer/myApp/Login/Default.aspx and continue ...
26
votes
7answers
4k views

Split the calculation of return value and the return statement in one-line methods?

I have had a discussion with a coworker about breaking a return statement and the statement that calculates the return value in two lines. For example private string GetFormattedValue() { var ...
0
votes
1answer
78 views

How to divert IP traffic of 1 site to test new code before deploying

We have a number of IoT devices that communicate over TCP/IP to a server. Once connected, the server can then talk to the device, get data or send down commands. The server accepts incoming ...
5
votes
4answers
856 views

If you follow the rule of Zero, how will you debug the construction of an object?

Everyone is quick to point out the "Rule of Zero" in code reviews, peer conversations, and Stack Overflow comments/answers. I am not a believer. I'd like to be. Usually if enough people agree on ...
-1
votes
4answers
139 views

Identifying code from bug reports

Imagine this scenario: You are relatively new to a very large codebase for a GUI application. A bug report comes in. Since it is a GUI, the report is not expressed in terms relating to functions or ...
0
votes
0answers
69 views

Redirecting the debugger back to user code when stepping through engine code in C++

I have a project (C++, Visual Studio 2015) where I'm thinking of making the API for a library take lambdas or function objects so that the user has a place to put debug breakpoints to know what higher ...
3
votes
4answers
247 views

Advice for bugfixing object oriented code: why is data not set?

When debugging object oriented (Java) code, sometimes some field of some object is null while it should not be. I often spend what I feel is way too much time trying to figure out where it should have ...
-1
votes
1answer
75 views

What techniques to find exact spot of code in a fullstack environment?

I am working on a large J2EE application. I am not very familiar with front end development, and I am trying to trace through the entire application(not in one shot). I am looking at a test case right ...
0
votes
1answer
44 views

Debug class responsibility, accessability

So I'm writing a Flocking System (http://www.red3d.com/cwr/boids/). Each boid calculates it's vectors, I would like to draw these vectors with a helper class for debugging purposes. Who should ...
-1
votes
1answer
38 views

Working On Remote Errors in a Variety of Environments Without FTP or SSH Access

BACKGROUND: I've been developing in PHP for two years - self taught, and beyond the most basic editing, really just a year and a half - but my experience is limited to a small number of environments. ...
0
votes
4answers
220 views

Undoing “fixes”

As someone who hasn't really gotten into large-scale corporate software development--I'm 17, I wanted to ask a question about programming practice. If you encounter a bug in an application, and you ...
3
votes
1answer
133 views

Are there any standards for labelling stdout/stderr messages?

I'm making a console application, and over time I have been developing my own tools and practices for outputting text; a process that keeps evolving. For example, these days I have 4 main types of ...
1
vote
3answers
81 views

Multiple error debuging

Sometimes I ran into errors which are really hard to debug. So my meta question is the following: You have multiple chunks of code, let's say A -> B -> C -> D Your code don't crash but ...
3
votes
3answers
1k views

Should we compile and ship libraries with debug information whenever possible?

There is considerable cost (and pain) for developers to debug external libraries due to the fact that many libraries are distributed in two editions: one with debug information, other without. The ...
1
vote
1answer
720 views

Console application for developer interviews [closed]

I have been tasked with helping our HR department create some new interview questions for candidates applying for development positions. As part of the process, I would like to assess their ability to ...
8
votes
4answers
355 views

Bug clustering in source code

There are many claims about existence of clusters of bugs or defects. A simple search reveals multiple results, for example: 1, 2, 3, 4, 5. However, all the evidence cited is anecdotal and I could ...
166
votes
9answers
27k views

I changed one method signature and now have over 25,000 errors. What now?

I started a new job recently where I am working on a very large application (15M loc). In my previous job we had a similarly large application but (for better or for worse) we used OSGi, which meant ...
1
vote
2answers
151 views

Is it my job to enforce my preconditions?

Say I have a function that takes some arguments that fall under a bunch of constraints, e.g. one of them has to be an integer, another has to be a string of length at least 10, et cetera. In general, ...
3
votes
3answers
2k views

What is the difference between debugging and antibugging?

The terms debugging and antibugging seem to be widely used for referring to tools, measures and design patterns to get rid of bugs. After reading Peter Norvig's Paradigms of Artificial Intelligence ...
8
votes
1answer
424 views

Create in-browser IDE for own grammar [closed]

We are going to use our new own programming language. We have designed grammar, json parser and everything seems to work. Code in my language is transpiled into javascript and interpreted by node.js ...
4
votes
1answer
133 views

What is a good way to debug when does a specific value is pushed onto stack in assembly code?

I am currently debugging a very old game (so there is no customer support) that keeps crashing under certain condition and I have found out it is because unsigned short to unsigned int conversion was ...
2
votes
2answers
61 views

How can I track down a dependency that is causing an X509TrustManager error without having the source?

I am maintaining and Android app that now suffers from an unsafe X509 TrustManager implementation. Since the app doesn't make any HTTPS calls except through dependencies, one of the dependencies is ...
0
votes
2answers
1k views

What is a debug port

I want to explore code paths in Cassandra database, so after getting the code from git and explore it a bit I noticed that it starts a daemon process when I run it from Eclipse. I supposed that when ...
-1
votes
2answers
2k views

Run C program in debug mode (without debugger)

If I want my program to be able to run in debug mode, is it a good idea to make it accept a flag such as -D=DEBUG when I run the program? I currently have a DEBUG variable in a .h file but that I can'...
1
vote
2answers
88 views

Replacing buggy component with library: important to identify bug in old component before replacing?

Summary: component used to work and now doesn't, the regression happened 1+ years ago and we're not sure when, now I'm considering replacing the broken and poorly architected component with a mature ...
0
votes
2answers
212 views

Recognize bug or inability to solve a problem by yourself

How to recognize when there is a bug in program or you have an inability to solve concrete problem? I noticed when I concentrate too much time on a problem and can't find a solution, I am starting to ...
1
vote
1answer
174 views

For Web front end, if there are 20 JavaScript files loading, how to track down the mouseover handler?

For Web front end programming, since any JavaScript can set up an event listener for "mouseover" or "mouseenter" for an element, if we are to track down what is the code that is responsible for making ...
1
vote
3answers
131 views

Are debug-build-only UI controls a bad practice?

Often, to simplify testing, I add UI controls that are only visible and enabled in debug build only. Or prepopulate mandatory input fields in debug build. Is this a bad practice? Assuming the release ...
-2
votes
1answer
231 views

Debugging mutually recursive functions

We have a class in which mainly data processing(XML nodes) is done by mainly 3 methods. Now code in itself strictly follows DRY principle. For e.g. Process Children (reads data from child nodes) ...
1
vote
2answers
154 views

How to determine if there's something wrong with my code or a bug in the library

I'm working with Meteor, which is a relatively young Javascript framework. As such, it seems like I often run into problems which haven't been asked on Stackoverflow already. In one such case, I was ...
1
vote
3answers
152 views

How to debug javascript in browsers that don't have a console interface? [closed]

It's unbelievable but my company is still building web app on IE 6. Although the online dashboard for IE 6 is limited in functionality, I've found extremely difficult to debug anything on it. It's ...
1
vote
3answers
277 views

Is a logical error always caused by the line of code for the earliest program state which is wrong? [closed]

A logical error, contrary to a fatal runtime error, is a run time error which doesn't fatally terminate a program, but does something not intended. Is a logical error necessarily caused by the line ...
22
votes
3answers
5k views

How can I diagnose async/await deadlocks?

I am working with a new codebase that makes heavy use of async/await. Most of the people on my team are also fairly new to async/await. We generally tend to hold to Best Practices as Specified by ...
1
vote
1answer
211 views

Should Write-Debug statements be left in production PowerShell code?

This is one of my functions I have in a module: Function Get-DatabaseUser { [CmdletBinding()] Param() Write-Verbose 'Getting database...' $Database = Get-Database Write-Debug('...
0
votes
2answers
5k views

What is an Integration Point?

How is an Integration Point defined within the context of an application? I've heard about it in a programming course but couldn't grasp the concept in a way that I could distinguish an integration ...
3
votes
2answers
441 views

Methods of “Code Softening” (Opposite of “Hardening”) for C & C++ [closed]

Some developers work on code hardening. (protecting against errors, you can build with a stack protector for example). However, if you're trying to redo a strange someone else reports, or find ...
4
votes
1answer
140 views

Reducing conditional code makes assessing coverage or debugging difficult

Working in Python, I've written a few utilities to assert pre-conditions and to re-interpret exceptions, and have found my code doesn't have so many branches. I've also tried to move other code path ...