Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. What is a bug?

What is a bug?

Scheduled Pinned Locked Moved The Lounge
helpquestionlearningpythonvisual-studio
37 Posts 24 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Marc Clifton
    wrote on last edited by
    #1

    I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

    Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

    M N L M D 18 Replies Last reply
    0
    • M Marc Clifton

      I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

      Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

      M Offline
      M Offline
      Mandeep8
      wrote on last edited by
      #2

      A bug is the failure of code to fulfill business requirements.

      N S 2 Replies Last reply
      0
      • M Marc Clifton

        I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

        Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

        N Offline
        N Offline
        Nish Nishant
        wrote on last edited by
        #3

        In the old days, they were considered bugs. So there were 3 levels ; - compiler errors - runtime errors (program crashes) - logical/functional errors (program does not crash but gives incorrect output) Today most people don't consider compiler errors as bugs.

        Regards, Nish


        Website: www.voidnish.com Blog: voidnish.wordpress.com

        R K L 3 Replies Last reply
        0
        • M Mandeep8

          A bug is the failure of code to fulfill business requirements.

          N Offline
          N Offline
          Nish Nishant
          wrote on last edited by
          #4

          Well, a basic business requirement would be that your code can compile into a binary/runnable format. :)

          Regards, Nish


          Website: www.voidnish.com Blog: voidnish.wordpress.com

          M D 2 Replies Last reply
          0
          • M Marc Clifton

            I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

            Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

            L Offline
            L Offline
            Lost User
            wrote on last edited by
            #5

            Marc Clifton wrote:

            What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code.

            I would say no, that is not a bug. If it is then this is awesome code that simply has a bug that needs to be fixed.

            var godObject = new God();
            while(true)
            {
            godObject.DoWhatIsNeeded()
            }

            Thats right, god objects don't even care about semi colons they are rocking it so much. THey just go go go and do what is needed. I got your whole system right here. Can I get paid now? But seriously, no syntax errors are not bugs. A bug is a manifestation (i.e. observation) of a failure in a running system. Yes, this means that if it is not observed it is not a bug. Welcome to quantum physics and the world of programming where one persons bug is another persons feature.

            Computers have been intelligent for a long time now. It just so happens that the program writers are about as effective as a room full of monkeys trying to crank out a copy of Hamlet. The interesting thing about software is it can not reproduce, until it can.

            K 1 Reply Last reply
            0
            • N Nish Nishant

              Well, a basic business requirement would be that your code can compile into a binary/runnable format. :)

              Regards, Nish


              Website: www.voidnish.com Blog: voidnish.wordpress.com

              M Offline
              M Offline
              Mandeep8
              wrote on last edited by
              #6

              Code that compiles, most basicly Fulfills the contract and stated purpose. client gets what he paid for or sues/bad reviews Does not cause RISK (data loss, intrusion, etc), again lawsuit risk

              1 Reply Last reply
              0
              • M Marc Clifton

                I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

                Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

                M Offline
                M Offline
                Mark_Wallace
                wrote on last edited by
                #7

                You can look for technical definitions, but they would just become overly complex sets of rules and codicils, but what a bug really is is something that makes a program behave in a way that your customers don't expect it to behave. Crashing, for example, is not what I would call "expected behaviour", when using a program -- so if it crashes, there's a bug. More subtly, if you tell a customer that a program will do A and it does B, that's a bug -- but the bug might not be in the code, it might be in the way you explained it. I wanna be a eunuchs developer! Pass me a bread knife!

                M 1 Reply Last reply
                0
                • M Mark_Wallace

                  You can look for technical definitions, but they would just become overly complex sets of rules and codicils, but what a bug really is is something that makes a program behave in a way that your customers don't expect it to behave. Crashing, for example, is not what I would call "expected behaviour", when using a program -- so if it crashes, there's a bug. More subtly, if you tell a customer that a program will do A and it does B, that's a bug -- but the bug might not be in the code, it might be in the way you explained it. I wanna be a eunuchs developer! Pass me a bread knife!

                  M Offline
                  M Offline
                  Mandeep8
                  wrote on last edited by
                  #8

                  Is Windows 7's constant attempting to install a differnet version of an OS without consent a bug? It's not expected the behaviour

                  M 1 Reply Last reply
                  0
                  • M Marc Clifton

                    I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

                    Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

                    D Offline
                    D Offline
                    den2k88
                    wrote on last edited by
                    #9

                    What is a bug? Baby don't hurt me, don't hurt me, no more!

                    GCS d--- s-/++ a- C++++ U+++ P- L- E-- W++ N++ o+ K- w+++ O? M-- V? PS+ PE- Y+ PGP t++ 5? X R++ tv-- b+ DI+++ D++ G e++>+++ h--- ++>+++ y+++*      Weapons extension: ma- k++ F+2 X If you think 'goto' is evil, try writing an Assembly program without JMP. -- TNCaver

                    S 1 Reply Last reply
                    0
                    • N Nish Nishant

                      In the old days, they were considered bugs. So there were 3 levels ; - compiler errors - runtime errors (program crashes) - logical/functional errors (program does not crash but gives incorrect output) Today most people don't consider compiler errors as bugs.

                      Regards, Nish


                      Website: www.voidnish.com Blog: voidnish.wordpress.com

                      R Offline
                      R Offline
                      raddevus
                      wrote on last edited by
                      #10

                      Very interesting question you pose. Would you track compiler errors in a bug tracking database? I would hope that no one ever has. As soon as I say that then someone is going to say, "what about the people who are writing code compilers?" :laugh: So, since you wouldn't really consider tracking compiler errors as you do other errors they probably should be ignored since you can't build the software to get it running without resolving them. Analogy Time Also, let's see if there is an analogy.... ...suppose the robots that are building the cars in an assembly line malfunction and start painting the cars multiple colors because the car has a design element which sticks out that inadvertently flips a switch as it travels down the assembly line. Would that be a bug in the car? Probably not.

                      My book, Launch Your Android App, is available at Amazon.com.

                      N M 2 Replies Last reply
                      0
                      • M Marc Clifton

                        I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

                        Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

                        D Offline
                        D Offline
                        David Crow
                        wrote on last edited by
                        #11

                        Marc Clifton wrote:

                        ? Or do you think that something can only be called a bug if it manifests when the program is run?

                        I agree.

                        "One man's wage rise is another man's price increase." - Harold Wilson

                        "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

                        "You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles

                        1 Reply Last reply
                        0
                        • M Mandeep8

                          Is Windows 7's constant attempting to install a differnet version of an OS without consent a bug? It's not expected the behaviour

                          M Offline
                          M Offline
                          Mark_Wallace
                          wrote on last edited by
                          #12

                          Indeed. It is unwanted behavior that is actually built in. Many would call that malware, and I'd tend toward agreeing with them. I wanna be a eunuchs developer! Pass me a bread knife!

                          1 Reply Last reply
                          0
                          • M Marc Clifton

                            I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

                            Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

                            D Offline
                            D Offline
                            Dominic Burford
                            wrote on last edited by
                            #13

                            In a strongly typed language such as C#, a syntax bug will result in a compile time error so will be trapped before it reaches any potential customers. In a loosely typed language such as Javascript a syntax error will result in a run-time exception and so could arguably be defined as a bug as it could reach a potential customer if it has not been tested sufficiently. A bug is generally defined as any deviation from expected behaviour.

                            "There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare Home | LinkedIn | Google+ | Twitter

                            1 Reply Last reply
                            0
                            • N Nish Nishant

                              Well, a basic business requirement would be that your code can compile into a binary/runnable format. :)

                              Regards, Nish


                              Website: www.voidnish.com Blog: voidnish.wordpress.com

                              D Offline
                              D Offline
                              Dominic Burford
                              wrote on last edited by
                              #14

                              Nish Nishant wrote:

                              Well, a basic business requirement would be that your code can compile into a binary/runnable format

                              That would not be a requirement of the business. That would be a technical requirement.

                              "There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare Home | LinkedIn | Google+ | Twitter

                              N 1 Reply Last reply
                              0
                              • D Dominic Burford

                                Nish Nishant wrote:

                                Well, a basic business requirement would be that your code can compile into a binary/runnable format

                                That would not be a requirement of the business. That would be a technical requirement.

                                "There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare Home | LinkedIn | Google+ | Twitter

                                N Offline
                                N Offline
                                Nish Nishant
                                wrote on last edited by
                                #15

                                Technical requirements and business requirements have some overlap.

                                Regards, Nish


                                Website: www.voidnish.com Blog: voidnish.wordpress.com

                                D 1 Reply Last reply
                                0
                                • R raddevus

                                  Very interesting question you pose. Would you track compiler errors in a bug tracking database? I would hope that no one ever has. As soon as I say that then someone is going to say, "what about the people who are writing code compilers?" :laugh: So, since you wouldn't really consider tracking compiler errors as you do other errors they probably should be ignored since you can't build the software to get it running without resolving them. Analogy Time Also, let's see if there is an analogy.... ...suppose the robots that are building the cars in an assembly line malfunction and start painting the cars multiple colors because the car has a design element which sticks out that inadvertently flips a switch as it travels down the assembly line. Would that be a bug in the car? Probably not.

                                  My book, Launch Your Android App, is available at Amazon.com.

                                  N Offline
                                  N Offline
                                  Nish Nishant
                                  wrote on last edited by
                                  #16

                                  If you are working on a C++ template library, you may need to track some bugs that may take a few days to fix :-)

                                  Regards, Nish


                                  Website: www.voidnish.com Blog: voidnish.wordpress.com

                                  1 Reply Last reply
                                  0
                                  • N Nish Nishant

                                    In the old days, they were considered bugs. So there were 3 levels ; - compiler errors - runtime errors (program crashes) - logical/functional errors (program does not crash but gives incorrect output) Today most people don't consider compiler errors as bugs.

                                    Regards, Nish


                                    Website: www.voidnish.com Blog: voidnish.wordpress.com

                                    K Offline
                                    K Offline
                                    Kenneth Haugland
                                    wrote on last edited by
                                    #17

                                    You forgot the Visual Studio doesn't (currently) work properly so we need a workaround bug :)

                                    1 Reply Last reply
                                    0
                                    • M Marc Clifton

                                      I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

                                      Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

                                      Richard DeemingR Offline
                                      Richard DeemingR Offline
                                      Richard Deeming
                                      wrote on last edited by
                                      #18

                                      For some customers, a "bug" is when your software doesn't magically alter its behaviour to adapt to changes in the business requirements which they didn't bother to tell you about. :doh:


                                      "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

                                      "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

                                      1 Reply Last reply
                                      0
                                      • M Marc Clifton

                                        I imagine we can all agree that a runtime error (something that blows up the program at runtime) or a logical error (doesn't blow up, but produces the wrong result) are bugs. Of course, there are other categories, like a "performance bug" -- produces the right result but takes too long. In any case... What about syntax errors -- those things that the compiler (or the IDE) detects before you even run the code, and in fact prevents you from running the code. Would you go so far as to say that syntax errors are a subset of what we call bugs? Or do you think that something can only be called a bug if it manifests when the program is run? Marc

                                        Imperative to Functional Programming Succinctly Contributors Wanted for Higher Order Programming Project! Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny

                                        Kornfeld Eliyahu PeterK Offline
                                        Kornfeld Eliyahu PeterK Offline
                                        Kornfeld Eliyahu Peter
                                        wrote on last edited by
                                        #19

                                        I asked one of our customers... "A bug is when one choose to print a summary report and a summary report is printed"...

                                        Skipper: We'll fix it. Alex: Fix it? How you gonna fix this? Skipper: Grit, spit and a whole lotta duct tape.

                                        "It never ceases to amaze me that a spacecraft launched in 1977 can be fixed remotely from Earth." ― Brian Cox

                                        1 Reply Last reply
                                        0
                                        • D den2k88

                                          What is a bug? Baby don't hurt me, don't hurt me, no more!

                                          GCS d--- s-/++ a- C++++ U+++ P- L- E-- W++ N++ o+ K- w+++ O? M-- V? PS+ PE- Y+ PGP t++ 5? X R++ tv-- b+ DI+++ D++ G e++>+++ h--- ++>+++ y+++*      Weapons extension: ma- k++ F+2 X If you think 'goto' is evil, try writing an Assembly program without JMP. -- TNCaver

                                          S Offline
                                          S Offline
                                          Slacker007
                                          wrote on last edited by
                                          #20

                                          I chuckled.

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups