I recently ran the upgrade of our 25.10 server to 26.04 on a cloned VPS to make sure all is well.
We had Apache and php installed in a standard way, v 2.4.64 and php 8.4
During upgrade to 26.04 our server displayed the content of all php files for a few minutes.
The upgrade somehow had Apache running while the php installation was removed and the new one not installed yet.
Stopping apache before upgrade did not solve this.
No need to say this was a huge shock.
We solved this with an Apache IfModule for php configuration, which is sensible anyway.
But remember, this was a standard installed Apache and php !