Let $A$ be a commutative Noetherian ring and $I=(a_1,\cdots,a_n)$ an ideal. Then the $I$-adic completion of $A$ is isomorphic to $A [[ x_1,\cdots,x_n ]]/(x_1-a_1,\cdots,x_n-a_n)$. Now let $e$ be an idempotent of $A$ and apply the above result to the ideal generated by $e$. Then $\hat{A}=A[[x]]/(x-e)$. On the other hand, by definition of the $I$-adic completion we have that $\hat{A}=A/(e)$. Clearly, $A/(e) \neq A[[x]]/(x-e)$. What am i missing?
Here is the way i think about it: To construct the $I$-adic completion, we first start by considering the product $\prod_{i>0} A/I^i$. Since $e^2=e$, for $A=(e)$ this product becomes $\prod_{i>0} A/(e)$. The completion is the subspace of coherent sequences of this product. But each such coherent sequence can be identified with a single element of $A/(e)$.