Let $M\_g$ be the moduli space of Riemann surfaces, as described for example in the book of Harris and Morrison - *Moduli of curves*. As a topological space, or better as orbifold, it has smooth points and singular points. Let $S\subseteq M\_g$ be the subset of **smooth points**. In the article by Cornalba ("On the locus of curves with automorphisms") this subset is identified, in the case $g>3$, with the set of those curves which have just the trivial automorphism. 


Is there any idea (or any reference) of how to compute the homotopy groups
$$\pi\_2(M\_g,S) \qquad \mbox{and} \qquad \pi\_1(S)?$$


**Edit**:
I should have included a base point above, but I intentionally didn't because I wouldn't know which one to choose. 



Homotopy groups of smooth part of moduli space
I'm not sure why you're talking about codimension $1$ components of $S$ since the smooth locus $S$ is actually dense in $\mathcal{M}\_g$.


Anyway, the fundamental group of the locus $S$ of smooth points is the mapping class group $Mod\_g$ of the surface $\Sigma\_g$. To see this, recall that $\mathcal{M}\_g$ is the quotient of Teichmuller space $\mathcal{T}\_g$ by the action of $Mod\_g$. Let $\widetilde{S}$ be the preimage of the smooth locus in $\mathcal{M}\_g$ under the projection $\mathcal{T}\_g \rightarrow \mathcal{M}\_g$. The action of $Mod\_g$ on $\mathcal{T}\_g$ preserves $\widetilde{S}$, and moreover the restriction of the action of $Mod\_g$ to $\widetilde{S}$ is free (the only fixed points of the action of $Mod\_g$ on $\mathcal{T}\_g$ come from curves with automorphisms). It follows that $\widetilde{S} \rightarrow S$ is a regular cover with deck group $Mod\_g$. To prove that the fundamental group of $S$ is $Mod\_g$, it is enough to prove that $\widetilde{S}$ is $1$-connected. For this, recall that the locus of curves with automorphisms has complex codimension $2$ in $\mathcal{M}\_g$ as long as $g > 3$. This implies that the complement in $\mathcal{T}\_g$ of $\widetilde{S}$ also has complex codimension $2$ and thus real codimension $4$, which implies in particular that the inclusion $\widetilde{S} \hookrightarrow \mathcal{T}\_g$ induces an isomorphism on fundamental groups. The desired result now follows from the fact that $\mathcal{T}\_g$ is contractible.


