Check if selected loop is a disconnected loop using python
This will do the trick in your case:

import bpy, bmesh

bm = bmesh.from_edit_mesh( bpy.context.object.data )

selectedVerts = set( [ v.index for v in bm.verts if v.select ] )

bpy.ops.mesh.select_all( action = 'DESELECT' )
bpy.ops.mesh.select_non_manifold()

nonManifoldVerts = set( [ v.index for v in bm.verts if v.select ] )

commonVerts = selectedVerts.intersection( nonManifoldVerts )

bpy.ops.mesh.select_all( action = 'DESELECT' )
for i in selectedVerts: bm.verts[i].select = True
bm.select_flush( True )

msg = "Not connected" if commonVerts else "Connected"
print( msg )


EDITED:

This will now work with any loop that is completely manifold (i.e doesn't have any non-manifold edge/vert)