ILSpy find the source of the error - it is coming from Sitecore.ExperienceEditor.Web.ResourceCollector.SessionResourceCollector looking for EE js files - noted a way to disable this with WebEdit.EnableJSBundling false - tested that which made it fast but the EE is broken with JS errors
Sitecore.ExperienceEditor.Speak.Ribbon.RibbonComponentControlBase is the one adding a PageCodeScriptFileName. To me this means there is an ribbon component that is not correctly configured. Considering that this issue is recent , might be a core DB upgrade issue or maybe an issue with a custom module.
I notice we have 2 custom modules - Global Link and KeyStone on the ribbon. Likely one of these is not configured right.
Try and click on Global Link and KeyStone ribbons icons - these are triggering a 404 on js files!
After checking requirements, we don't actually need these modules anymore.
Deleted core:/sitecore/content/Applications/WebEdit/Ribbons/WebEdit/Global Link and
core:/sitecore/content/Applications/WebEdit/Ribbons/WebEdit/Keystone - Issue resolved!
I hope this helps others if they have a similar issue.