Let $k$ be some field, algebraically closed and of characteristic $0$, if you like.


Let $U= \mathbb{A}^2\_k \setminus \{ (0,0) \}$ be the punctured affine plane over $k$. Write $U$ as the union of $U\_1 = \mathrm{Spec} k[x^{\pm 1},y]$ and $U\_2 = \mathrm{Spec} k[x,y^{\pm 1}]$. Then deformations $U^\prime$ of $U$ to $k[t]/t^2$ are given in the following way:


We have $U^\prime = U\_1^\prime\cup U\_2^\prime$, where $U\_1^\prime = \mathrm{Spec} (k[t]/t^2) [x^{\pm 1},y]$ and $U\_2^\prime = \mathrm{Spec} (k[t]/t^2)[x^{\prime},y^{\prime \pm 1 }]$, and they are glued along an isomorphism of $\mathrm{Spec} (k[t]/t^2) [x^{\pm 1},y^{\pm 1}]$ with $\mathrm{Spec} (k[t]/t^2) [x^{\prime \pm 1},y^{\prime \pm 1}]$ which can be brought in a unique way into the form
$$
x^\prime = x + t (\sum\_{i,j>0} a\_{ij} x^{-i} y^{-j})\ ,\
y^\prime = y + t (\sum\_{i,j>0} b\_{ij} x^{-i} y^{-j})\ ,
$$
where both sums are finite. In particular, the simplest case is given by an isomorphism of the form
$$
x^\prime = x + atx^{-1}y^{-1}\ ,\
y^\prime = y + btx^{-1}y^{-1}\ ,
$$
where $a,b\in k$ are parameters.


Moreover, deforming $U$ is unobstructed, so there exists a formal lifting of $U$ to a formal scheme $\mathcal{U}$ over $\mathrm{Spf} k[[t]]$. My question is whether there exist algebraic deformations to $\mathrm{Spec} k[[t]]$. In other words:



> 
> Question: Does there exists a flat separated scheme $X$ of finite type over $\mathrm{Spec} k[[t]]$ together with an open subscheme $U^\prime\subset X\otimes\_{k[[t]]} k[t]/t^2$ such that $U^\prime$ is a nontrivial deformation of $U$?
> 
> 
> 


Note that up to now, I could not construct a single such example, but I couldn't figure out an obstruction either.


One attempt might be to find an affine scheme $X$. This essentially boils down to choosing a subring $R\subset k[x,y]$ which contains a power of the ideal $(x,y)$, and deforming $R$ to $k[[t]]$. One can check that for any given deformation $U^\prime$ to $k[t]/t^2$, one can find such a ring $R$ that lifts to $k[t]/t^2$, and gives rise to the deformation $U^\prime$ (upon removing the origin). However, typically $R$ will be obstructed, and it is far from clear that one can further find a lift of this $R$ to $k[[t]]$.


[Question edited to account for Angelo's comment. Sorry for a stupid second question!]



Deformations of the punctured affine plane
I think I can prove the following



> 
> Theorem: Let $R$ be a $k$-algebra of finite type with a closed point $x\in \mathrm{Spec} R$ such that $\mathrm{Spec} R\setminus \{x\}\cong \mathbb{A}^2\_k\setminus \{(0,0)\}$. Let $\tilde{R}$ be a $t$-adically complete flat lift of $R$ to $k[[t]]$. Then $\mathrm{Spf} \tilde{R}\setminus \{x\}\cong \mathbb{A}^2\_{\mathrm{Spf} k[[t]]}\setminus \{(0,0)\}$.
> 
> 
> 


As mentioned in the question, there do exist nontrivial deformations to $k[[t]]/t^n$ for any $n$; for that reason, I find this result surprising: Lifting to $k[[t]]$ poses a strong rigidity that I was not previously aware of.


In particular, there are no examples to the above question with $X$ affine. The proof below also shows that my intended application of algebraic deformations of the punctured affine plane cannot work, so I consider my question as answered in the negative (although strictly speaking the question posed is still open).


Let me start with something seemingly unrelated.



> 
> Proposition: Let $K$ be some field, let $X/K$ be a smooth surface, and let $C\cong \mathbb{P}^1\subset X$ be a smooth rational curve in $X$ with self-intersection $C^2 = 1$. Then there is an open subset $U\subset X$ containing $C$ and an open embedding $U\hookrightarrow \mathbb{P}^2$ (carrying $C$ into a line).
> 
> 
> 


I deduced this (hopefully correctly) from the classification of surfaces (showing first that $X$ has to be rational); probably there is a more direct argument.


Now consider $Y=\mathbb{P}\_k^2\setminus \{(0:0:1)\}$, with its line $C\subset Y$ at infinity. Let $R$ and $\tilde{R}$ be as above. Glue $Y$ with $\mathrm{Spec} R$ along $\mathbb{A}^2\_k\setminus \{(0,0)\}$ to $\bar{Y}$ over $k$; this is projective, with $C$ an ample divisor. As $H^2(\mathbb{P}\_k^2,T\_{\mathbb{P}\_k^2}(-C))=0$, one checks that any deformation of $R$ can be extended to a deformation of $\bar{Y}$ which also lifts $C$. In particular, $\tilde{R}$ can be extended to a proper flat formal scheme $\tilde{\bar{Y}}$ with a lift $\tilde{C}$ of $C$, over $\mathrm{Spf} k[[t]]$. By formal GAGA, this is algebraizable, to a projective surface $Z$ over $\mathrm{Spec} k[[t]]$, and $D\cong \mathbb{P}^1\subset Z$. The smooth locus of the generic fibre of $Z$, together with the generic fibre of $D$, satisfies the assumptions of the Proposition. It follows that there is a birational map from the smooth locus of the generic fibre of $Z$ to $\mathbb{P}^2\_{k((t))}$. It cannot contract anything: If a curve $E$ was contracted, then this curve would meet the generic fibre of $D$ (as $D$ is ample), but in a neighborhood of $D$, the map is well-defined. Moreover, it cannot have critical points, as the target $\mathbb{P}^2\_{k((t))}$ contains no exceptional curves. It follows that the smooth locus of the generic fibre of $Z$ is open in $\mathbb{P}^2\_{k((t))}$. As its image contains an ample curve, it follows that the codimension of the image is at least $2$.


Now consider the reduction map $H^0(Z^{\mathrm{sm}},\mathcal{O}(nD))\to H^0(Y,\mathcal{O}(nC))$, where $Z^{\mathrm{sm}}\subset Z$ denotes the smooth locus; it induces an injection $H^0(Z^{\mathrm{sm}},\mathcal{O}(nD))/t\to H^0(Y,\mathcal{O}(nC))$. Both have the same dimension as $H^0(\mathbb{P}^2,\mathcal{O}(n))$. It follows that the map has to be surjective. It follows that $\mathrm{Proj} \bigoplus H^0(Z^{\mathrm{sm}},\mathcal{O}(nD))$ is a flat deformation of $\mathbb{P}^2\_k$, thus is isomorphic to $\mathbb{P}^2\_{k[[t]]}$. We get an open embedding $Z^{\mathrm{sm}}\hookrightarrow \mathbb{P}^2\_{k[[t]]}$, which restricts to an isomorphism $\mathrm{Spf} \tilde{R}\setminus \{x\}\cong \mathbb{A}^2\_{\mathrm{Spf} k[[t]]}\setminus \{(0,0)\}$, as desired.


Addendum: For completeness, I deduce the Proposition (in case $K$ is algebraically closed -- one can then remove this hypothesis) from the paper "Curves with high self-intersection on algebraic surfaces" of Hartshorne (I will use freely notation from there). We may assume that $X$ is proper. First, $X$ is rational: Fix a point $x\in C$. Because $C$ is very free, there is a $1$-parameter family of rational curves which contain $x$. As these curves intersect with multiplicity $1$, no two of them can have the same tangent vector at $x$. It follows that this family is defined over a rational base, thus $X$ is (uni-, and thus) rational. Now we use Theorem 3.5 in Hartshorne's paper. Case a) means that $C\subset X$ is equivalent to a section of a rational Hirzebruch surface $F\_e\to \mathbb{P}^1$. The condition $C^2=1$ will then ensure that $e=1$, and that the curve $C$ does not meet the exceptional locus of $F\_1\to \mathbb{P}^2$, giving the result. Case b) cannot occur. Case c) could cause trouble. Looking into the proof, only the case $m=2$ might occur. Looking at how the case $m=2$ comes about in Proposition 3.2, we see that we must have $e+n=1$. The case $e=0$, $n=1$ is impossible because of condition b) in Proposition 3.1, and the other case $e=1$, $n=0$ is impossible because of condition e) in Proposition 3.1.


