Obviously, $p+p\to d + \pi^+$ can occur in a world in which the weak interaction is turned off. In particular, it respects all the conservation laws of the strong interaction. (If you want to think in terms of Feynman diagrams: One of the $u$ quarks in the proton can pair produce, via gluons, a
$d\bar{d}$ pair $u\to d +\bar{d}+u$, and the $u\bar{d}$ forms a charged pion. The proton is now a neutron, and can capture on the other proton to form a deuteron.)
What is it that we might mean by $p+p\to d+\pi^+$ occuring via the weak interaction? Clearly, the $d$ and $\pi^+$ are strongly interacting particles, and if we turn off the strong interaction these states cannot be formed. What we mean by $n\to p+e+\bar{\nu}$ being caused by the weak interaction is that it needs to involve at least one weak interaction (and many strong interactions). This is not the case here.
Having said this, it is of course not forbidden for one weak interaction to occur during the process $p+p\to d+\pi^+$. This could be a $u\to d+W^+$ transition followed by $W^+\to\pi^+$, but it could be other things as well. What this really describes is a weak correction to a strong interaction rate.
How would we ever know that this happens, given that the weak interaction is weak? The trick is to look for effects that are forbidden in the strong interaction, for example a parity violating spin asymmetry in $p+p\to d+\pi^+$. These effects are small, but they have been seen in experiment.