** Has the church ever infallibly taught that creation exnihilo is true? Or is it more of just theological speculation?**

I am just a simple Catholic but I have been wrestling with the idea of panentheism for some time now, hence my interest in this thread.
In answer to your question I would say that the Church teaches that creation ex nihilo is true.
According to:
catecheticsonline.com/SourcesofDogma19.php
1800 [The true progress of knowledge, both natural and revealed] .For, the doctrine of faith which God revealed has not been handed down as a philosophic invention to the human mind to be perfected, but has been entrusted as a divine deposit to the Spouse of Christ, to be faithfully guarded and infallibly interpreted. Hence, also, that understanding of its sacred dogmas must be perpetually retained, which Holy Mother Church has once declared; and there must never be recession from that meaning under the specious name of a deeper understanding [can. 3]. "Therefore . . . let the understanding, the knowledge, and wisdom of individuals as of all, of one man as of the whole Church, grow and progress strongly with the passage of the ages and the centuries; but let it be solely in its own genus, namely in the same dogma, with the same sense and the same understanding.’’ *
Canons (of the Catholic Faith)*
- God the Creator of all things
1801 T.[Against all errors about the existence of God the Creator] . If anyone shall have denied the one true God, Creator and Lord of visible and invisible things: let him be anathema [cf. n. 1782 ].
1802 2. [Against materialism]. If anyone shall not be ashamed to affirm that nothing exists except matter: let him be anathema [cf. n. 1783].
1803 3.[Against pantheism] .If anyone shall say that one and the same thing is the substance or essence of God and of all things: let him be anathema [cf. n.1782 ].
1804 4. Against special forms of pantheism]. If anyone shall say that finite things, both corporeal and spiritual, or at least the spiritual, have emanated from the divine substance, or, that the divine essence by a manifestation or evolution of itself becomes all things, or, finally, that God is universal or indefinite being, because by determining Himself, He created all things distinct in genera, in species, and in individuals: let him be anathema.
1805 5. Against pantheists and materialists].If anyone does not confess that the world and all things which are contained in it, both spiritual and material, as regards their whole substance, have been produced by God from nothing [cf. n. 1783 ],
[Against the Guentherians] , or,shall have said that God created not by a volition free of all necessity, but as necessarily as He necessarily loves Himself [cf. n. 1783],
Against the Guentherians and the Hermesians],or, shall have denied that the world was created to the glory of God: let him be anathema.