Point.Z Error (Dereferencing a non-pointer)

#1

Hi Guys

I am try to extract Z-values (levels) from a list of coordinates. I can see the Z-values in the list, but somehow it still returns an error (Warning: Internal error, please report: Dereferencing a non-pointer (3f47aacd). Any ideas to work around this please?

 

Thanks

Fennen

0 Likes

#2

Hi Fennen,

It looks like your list has some empty elements . Unless the struture of the list is important, try and flatten it.

0 Likes

#3

Hi Mostafa

Thanks for your suggestion and prompt response. I shall have a look into that. I have had the nodes wired exactly the same in a different scenario and it returned Z-values even with empty lists as shown below.

 

0 Likes

#4

Hi Fennen,

There’s some geometry and revit related nodes that automatically fail for the whole list if the first item in the list is a null or an empty list. It seems that you’ve stumbled on another one with “Point.Z”. I don’t keep a running list but I did report the issue some time ago here:

https://github.com/DynamoDS/Dynamo/issues/5238

Haven’t heard back since then. You could post a new issue and tag the one above, to check with the dev team if there’s been any progress on the matter.

 

0 Likes

#5

Hi Mostafa

Thanks. Flatten does return Z-values, but I am interested in keeping the structure of the list.

 

Hi Dimatar

Thank you for your example. I shall have a go at it and see what happens.

 

Cheers

Fennen

 

 

0 Likes

#6

Hi Dimitar

You’re absolutely right about the first item in the list having a null value, Point.Z fails to give a result. However, knowing this now, I can work around this.

 

Many thanks.

Fennen

0 Likes

"Dereferencing a non-pointer" problem
#7

If you’d like to keep the original list structure and still ensure that your graph will work for cases where the first item may be a null value or an empty list, you could route the list through a “List.Map” node. It’ll catch and ignore the initial error:

0 Likes

#8

Dimitar

Thanks for that. It does the trick. :wink:

 

0 Likes