You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have python embedded in C# and are putting into scope objects that have Nullable<Decimal> properties and running (user provided python) code which tests for null(None). This fails when the property has a value and we compare the value to None using the == and != operators. It appears to work when we use the pythonic syntax not x or x is not None. We have upgraded from 2.5.2 to 3.0.3, also went from from Python 3.8 to 3.12. This code worked in previous versions.
## This does not workx=Noneprint(x==None)
x=System.Decimal(1.23)
print(x==None)
## This worksx=Noneprint(notx)
x=System.Decimal(1.23)
print(notx)
## This also worksx=Noneprint(xisnotNone)
x=System.Decimal(1.23)
print(xisnotNone)
If there was a crash, please include the traceback here.
Activity