Aspose.Words convert doc to markdown error

error_message: “doc = aw.Document(file_path)
pmRuntimeError: Proxy error(InvalidCastException): Unable to cast object of type ‘Aspose.Words.Drawing.Shape’ to type ‘Aspose.Words.Paragraph’.”
code:

document = aw.Document(source_file)

aspose.words for python,version=25.1.0

@David_Matin Could you please attach the problematic input document here for testing? We will check the issue and provide you more information.

This is file : Loading Google Docs

@David_Matin The document is damaged and cannot be opened y MS Word. It looks like there is problems with document structure. So Aspose.Words cannot open it.

@alexey.noskov Another error,use same code

document = aw.Document(source_file)

error message:
document = aw.Document(source_file)
Tue, Jun 17 2025 10:11:55 amRuntimeError: Proxy error(FileCorruptedException): The document appears to be corrupted and cannot be loaded. —> ArgumentNullException: Value cannot be null. (Parameter ‘codec’)
document:https://drive.google.com/file/d/1T0kjx4-2Mi0Jit5xze7cxJ5J8BhrxDGR/view?usp=sharing

@David_Matin The attached PDF is also corrupted. Acrobat Reader shows the following error: