Error notice in dynamo

error1

I believe this is because not every string contains a “_” character in it. You can use a combination of a string.contains node and an if statement to run the script without the error.

1 Like

Could be what you said. Not so sure

Exactly what @jacob.small said. It’s because of the null values. Some nodes are not ideal and they behave funny when outputting or inputting nulls.

An example of an if statement in a code block which accomplishes the same (or maintains the previous values if that’s desirable):

Follow your way, it run good, but it still had errorif substring

Ah! Didn’t realize you had strings that started with “_”.

On a 1-10 scale of unexpected things (Bruce being dead is a 7), this was a 9. I’ll try and remember to adjust the code accordingly in the morning. You should look into nodes that look at the first character of a string like or asks if a string starts with in the meantime. You might be able to fix this yourself.