This isn't an answer as such, but it might help you find out if the file is genuinely corrupt. The file could be truncated, there might be encoding errors etc.
(Having said that, I can't remember the last time this happened to me - if at all...)
The .QGS file for your project is an XML file. This means it is human readable, and can be opened with other applications - including Web Browsers ;-)
- First, back up your .qgs and .qgs~ files.
- Next, create a copy of your .qgs project file.
- Rename the copy to have an .xml extension e.g. myproject.xml
- Open this XML file in your browser (probably right click the file, not sure about Windows). Or you can open your browser and use File > Open File
I deliberately corrupted a QGIS project file by removing parts of a tag, so it's no longer valid XML. If I open it up in the browser (Chrome in this case) I see an error message...
You might get better results with different browsers.
The reason for renaming the copy of the file to .xml is to stop the browser from treating the file as if it was a download. (Browsers don't understand what .qgs files are)
That's probably the easiest way to check that the file is genuinely corrupt (without writing code).
If the file opens and displays correctly, it's something else. If you do get an error, edit and update your question with any message you get.