The penalty is waived if you had no coverage for LESS than 3 months; its called a short gap exemption. The short gap exemption applies to the federal and NY tax returns.
Also, just to let you know... if your income was low due to unemployment and let's say, you don't have file income taxes this year because your income was too low... you do not have a penalty for not having the health insurance coverage, either.