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
Thanks for the report. Platform checks currently only apply within the if/elif/else statement. If you use an explicit else branch, this will work as expected:
importsysdeffoo() ->None:
ifsys.platform!="darwin":
print("not darwin")
returnelse:
print("darwin") # OK
Activity
brianschubert commentedon Apr 2, 2025
Thanks for the report. Platform checks currently only apply within the
if/elif/elsestatement. If you use an explicitelsebranch, this will work as expected:Closing as duplicate of #10773