Home Dashboard Directory Help
Search

Calculated properties do not throw exceptions by Shuang Wang


Status: 

Closed
 as By Design Help for as By Design


1
0
Sign in
to vote
Type: Bug
ID: 782806
Opened: 4/1/2013 7:33:25 PM
Access Restriction: Public
0
Workaround(s)
view
0
User(s) can reproduce this bug

Description


Calculated properties do not throw exceptions, even when throw is explicitly specified within the Expression ScriptBlock. In the real world, we want to look up an IP Address by machine name in a calculated property, and throw if the machine does not exist. Instead of an exception during lookup, we get a $null property and silently invalid data that doesn't get caught until much later.
Details
Sign in to post a comment.
Sign in to post a workaround.