Notation/background. Let $C_\bullet$ be a bounded chain complex of finitely generated abelian groups, with $C_i\cong\mathbb{Z}^{a_i}$. For any principal ideal domain $R$, let $C_\bullet\otimes R$ be the chain complex of finitely generated $R$-modules obtained by applying the functor $(-)\otimes_\mathbb{Z}R\colon \mathbf{Ab}\to R\mathbf{Mod}$ termwise. Furthermore, let $$\chi_R=\sum_{i\in\mathbb{Z}}(-1)^i\operatorname{rank} H_i(C_\bullet\otimes R)$$ be the Euler characteristic of $C_\bullet\otimes R$. It's a classical exercise in homological algebra (see e.g. Theorem 2.44 in Hatcher) to show that $$\chi_{R}=\sum_{i\in\mathbb{Z}} (-1)^i {a_i}$$ whenever $R$ is a field and whenever $R=\mathbb{Z}$.
Question. What happens when $R$ is some other PID? Do we still get $\chi_{R}=\sum_{i\in\mathbb{Z}} (-1)^i{a_i}$?
Attempt/thoughts. Suppose that $H_i(C_\bullet)\cong\mathbb{Z}^{b_i}\oplus T_i$, where $T_i$ is the torsion subgroup of $H_i(C_\bullet)$. The universal coefficient theorem then tells us that $$H_i(C_\bullet\otimes R)\cong (H_i(C_\bullet)\otimes _{\mathbb{Z}}R)\oplus \mathrm{Tor}_1^{\mathbb{Z}}(H_{i-1}(C_\bullet),R)\\ \cong R^{b_i}\oplus (T_{i}\otimes_{\mathbb{Z}} R)\oplus \mathrm{Tor}_1^{\mathbb{Z}}(T_{i-1},R)\,.$$ When $R$ is a field (see this thread), then all free copies of $R$ obtained from the tensor products with $T$ are cancelled by free copies of $R$ obtained from the Tor-terms when we compute the alternating sum. It intuitively doesn't feel very likely that things would work out as nicely when $R$ is a general PID, but I find it hard to come up with a counterexample...
Does anyone have any ideas or suggestions about how to approach this?