Open GL tutorial - triangle not showing on OSX

I’m following this tutorial Tutorial 2 : The first triangle, compiled the code, and saw a window appear but with no triangle. I ended up pulling the code from here ogl/tutorial02_red_triangle at master · opengl-tutorials/ogl · GitHub. I see a window with a dark background, but don’t see a triangle.

I’m on OSX 10.12.5 and glfw3. What could be causing this problem?

Any errors reported by OpenGL (glGetError) ? Or reported by the compilation/linking of the shaders ?

What hardware do you have ? What version of OpenGL are you using ?

Finally, from what I know, depending on your OSX version, supported OpenGL version might differ and can stuck to some specific version only. Read this for example. If that does not match your version, investigate further (maybe someone else here will give more targeted clues/solutions).