Suppose $M$ is a 2-dimensional smooth Riemannian manifold and $P\subset M$ is an open and connected subset with compact closure and a piecewise geodesic boundary.

My question is: What further conditions must $P$ (and $M$) satisfy such that the Gauss-Bonnet theorem is fulfilled for $P$?

I have found a lot of different versions of the Gauss-Bonnet theorem. All of them demand for instance that $M$ is orientable. Sometimes the boundary of $\partial P$ is supposed to be simple, closed and without cusps. But can't we do better than that? Is there a good survey which treats also more general cases?

Best wishes