I recently upgraded from 2.7 to 3.0.4. This code worked perfectly in 2.7 but seems to have stopped working after I upgraded. I've seen similar posts to this but I don't know if the issue was ever resolved.
def FindLabel ( [SURFACTANTS], [AMMONIA], [CHLORINE] ):
surf, amm, chlor = "","",""
if float([SURFACTANTS]) >0.24:
surf = "Surfactants: " + [SURFACTANTS] + "\n"
if float([AMMONIA]) >= 0.5:
amm = "Ammonia: " + [AMMONIA] + "\n"
if float([CHLORINE]) >= 0.02:
chlor = "Chlorine: " + [CHLORINE]
return surf + amm + chlor
The error message I'm getting is:
Invalid expression.
Error on line 1.
Semicolon or new line expected
I'm not sure where a semicolon or new line is expected, but I'm hoping it's an easy fix