SKShader failed to compile but it doesn't show the error

I have a shader that works on an iphone:


#define BLUR_SAMPLES 90
#define BLUR_RADIUS .015
#define BLUR_BRIGHTNESS .6


void main(){
    vec2 uv = v_tex_coord;
    vec4 tc = texture2D(u_texture, uv);

            
    vec2  c = vec2(0.5,0.5);
    vec3  s = vec3(0.);
    float w = 1./float(BLUR_SAMPLES);

    for(int i = 0; i < BLUR_SAMPLES; i++) {
        float tc = 2.85;
        float tt = texture2D(u_texture,uv).r + texture2D(u_texture,uv).g + texture2D(u_texture,uv).b;
        if (tc < tt && tt < 3.0){
            s += texture2D(u_texture,uv).a;
        }
        uv += (c-uv) * BLUR_RADIUS;
    }
    tc.xyz += s*w*BLUR_BRIGHTNESS;
    gl_FragColor = tc;
}

but when I try to run it on the computer I get this error:

2019-01-23 09:48:44.429226-0600 shadersMac[2344:11343186] Metal API Validation Enabled

2019-01-23 09:48:44.495977-0600 shadersMac[2344:11343186] SKShader failed to compile:


And the shader doesn't work, the image displays without the shader.

I tried adding the PrefersOpenGL property on the info.plist to YES and the error disappears but when I do the whole SKEffectNode turns black.