Suppose there is some statement $X$ that is unprovable in some system, e.g. ZFC. Let $L = \{x : x \in \Sigma^* \land X \text{ is true}\}$. Is there a Turing machine that decides $L$? I have had an argument about this where I have argued that $L$ is decidable as $X$ is either true or false, and in each case there is a deciding Turing machine. However they argued that if this were true, we could construct a proof of existence of a (dis)proof of $X$ as such:
Let $M$ be the Turing machine that decides $L$. If $M$ accepts $\varepsilon$, the proof is that $M$ accepts $\varepsilon$. If not, the proof is that $M$ does not accept $\varepsilon$.
I was of the opinion that this proof is not valid, since the proof needs to be convincing outside the context of the proof of existence of the proof, and in this case the proof depends on the output of $M$, which is not available in the proof (we don’t know what $M$ is), and the outcome of the decision in the proof of existence is not carried over to the proof. However I realize you might make the argument that if a supposed proof/disproof exists by this method, it might actually be a proof since the output of $M$ is inferrable from which proof exists.
Does such a Turing machine exist and do these arguments hold water?
If there existed such a machine, and it were known to be correct, then a transcript of its computation on an input proposition $P$ would constitute a proof of $P$. So it’s not the fact of the acceptance that would be the proof, but rather the sequence of its steps.