Announcement

Collapse
No announcement yet.

Any way to prevent "divide by zero" from locking up Dynamo entirely?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Any way to prevent "divide by zero" from locking up Dynamo entirely?

    Doing some tutorials right now where I have a code block that divides x by y. For the Y input I have a number slider. I've run into the problem of accidentally moving the slider to zero, with Dynamo set to Automatic, locks up the program completely. I have to shut it down, shut Revit down, everything, and then open up everything again. Why doesn't it just give an error message or something?

    #2
    Oh okay I found the "Minimum" value field underneath the slider. Still it seems weird that divide by zero would lock up the whole thing instead of just generating an error, like a red node or something.

    Comment


      #3
      Might be the node you're using. I just did a bunch of division, some by zero, and didn't lock up. Instead I get NaN (Not a Number).


      Sent from my iPhone using Tapatalk
      Greg McDowell Jr
      about.me/GMcDowellJr

      Comment


        #4
        Originally posted by GMcDowellJr View Post
        Might be the node you're using. I just did a bunch of division, some by zero, and didn't lock up. Instead I get NaN (Not a Number).


        Sent from my iPhone using Tapatalk
        I just used a regular number slider, and connected it to a Code Block with "x/y" as the code, number slider connected to the Y input. Several other nodes went into the X input.

        Comment


          #5
          Hehehe. Welcome to Dynamo. A ton of stuff will shag dynamo or make Revit crash. I almost never leave it on automatic.

          Sent from my Phablet. Please excuse typos... and bad ideas.

          Aaron Maller
          Director
          Parallax Team, Inc.
          Aaron "selfish AND petulant" Maller |P A R A L L A X T E A M | Practice Technology Implementation
          @Web | @Twitter | @LinkedIn | @Email

          Comment


            #6
            I just wish it was set to manual by default for new scripts bc i keep forgetting to switch it and after the first few nodes get connected....
            There are no stupid questions, only stupid people

            Comment


              #7
              I think I'm one of the only folk who actually likes automatic... that being said, I do turn off any heavy-duty scripts to Manual pretty swiftly

              Sol Amour

              Architectural Explorer, Digital warrior, Affectual adventurer and Curious Human Being
              Portfolio Website @ Cargo Collective

              Comment

              Related Topics

              Collapse

              • Clockwork Nodes Are amamzing.....but
                all of the sudden I do not know what is going on....

                My clockwork nodes are returning NULL...

                element.location is the first...
                January 18, 2017, 05:08 AM
              • If Else Statement
                Dear Dynamo Experts,

                I have a simple question on if statement. How to implement something like if true do A things, else do B things in dynamo?...
                May 25, 2017, 07:19 AM
              • Just a small complaint
                So as I'm watching some tutorial videos, it seems like the the dynamo library changes names often.. and the search function is not really that robust....
                January 17, 2015, 06:21 PM
              • Debugging Python
                Is there any good way to debug a Python node?
                I've got one that works if I pass a single value, but if I pass a list, it fails.
                Without...
                February 26, 2018, 09:26 PM
              • Thoughts on node/graph cleanup
                I'm working on a dynamo graph that utilizes the same dozen data points in different ways and I found myself getting annoyed with all of the wires going...
                May 25, 2017, 03:33 PM
              Working...
              X