Hi, so this issue is fixed as of the latest version of ITensor, version 0.2.3. Could you please update to that version?
Also, in your longer version of `op`, there should not be an ITensor `Op` as the first argument. This version ought to work:
function ITensors.op( ::OpName"YRotfunc", ::SiteType"S=1/2", s::Index)
Op = ITensor(ComplexF64,s',dag(s))
Op[s'=>1,s=>1] = 1/sqrt(2)
Op[s'=>2,s=>1] = -im/sqrt(2)
Op[s'=>1,s=>2] = im/sqrt(2)
Op[s'=>2,s=>2] = 1/sqrt(2)
return Op
end