Extending rational maps of nodal curves Let $R$ be a discrete valuation ring with fraction field $K$ and $C, D$ two nodal (=prestable) curves over $\operatorname{Spec} R$. If I have a map $C_K \to D_K$ between the restriction of the curves to the generic point $\operatorname{Spec} K$,

*

*can I blow up $C$ to extend this to a map $C \to D$ over $\operatorname{Spec} R$?


*If I blow up $C$ to do this, can I ensure that the result remains a nodal curve and the generic fiber $C_K$ is unchanged?
If it helps, the map $C_K \to D_K$ is a "partial stabilization" -- it contracts $\mathbb{P}^1$'s.
Remark: This is pretty clear for smooth curves, and well documented in the stacks project.
(My plan of attack so far:
A) Stacks 0BX7 should let me extend the map away from a finite set of closed points in the special fiber of $C$.
B) I believe these closed points should be nodes that get smoothed out in the generic fiber -- if the node persists, then maybe I can define the map at the node via specialization of the two generic points without a problem.
C) If the node gets smoothed out, this is etale-locally pulled back from $\mathbb{A}^2 \to \mathbb{A}^1$ and one can see directly the blowup at this node remains nodal.
D) By taking the closure $\Gamma$ of the graph of the rational map $C \dashrightarrow D$, I can argue that the projection $\Gamma \to C$ is a blowup at nodes in the special fiber that get smoothed out, since the map can be extended already away from those points.
I don't completely believe any of these steps -- this is more of a sketch than a proof. I'd very much like citations and references to any argument, esp. to the stacks project. )
 A: After lots of help from others, I realized the question boils down to some sort of stable reduction, which is a properness statement for the moduli of stable or relative stable maps $\overline{M}(X/V)$.
The isomorphism $C_K \simeq D_K$ provides a point $C_K \to C_K \times D_K$ over $K$ of $\overline{M}(C \times D/\operatorname{Spec} R)$. Properness (=stable reduction) extends this to a map $C' \to C \times D$ over $\operatorname{Spec}R$. The maps $C' \to C, C' \to D$ must be partial stabilizations because that's a closed condition in the base, and they're blowups because they're proper birational.
The blowups are at closed subschemes supported at a finite number of points in the special fiber, and I wish I could say the centers are smooth or something (or iterated blowups at smooth centers), but I don't need it.
Can anyone see why that would be, say by the fact that the exceptional divisors are chains of $\mathbb{P}^1$'s or something?
I apologize if this question and answer were obvious to the broader community.
