Bug 45690 - poi-3.5-beta1 ExtractorFactory.createExtractor doesn't work for .docm files
Summary: poi-3.5-beta1 ExtractorFactory.createExtractor doesn't work for .docm files
Status: RESOLVED FIXED
Alias: None
Product: POI
Classification: Unclassified
Component: XWPF (show other bugs)
Version: 3.5-dev
Hardware: PC Windows XP
: P2 normal with 2 votes (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-26 01:57 UTC by Khalid
Modified: 2009-11-03 17:36 UTC (History)
0 users



Attachments
Common docm file (Word 2007 macro-enabled document) causes error described (48.43 KB, application/ms-word-2007)
2009-05-22 01:19 UTC, Anton Chertov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Khalid 2008-08-26 01:57:35 UTC
ExtractorFactory.createExtractor(pkg) doesn't work for the macro-enabled Word (.docm) with mimetype: 
- "application/vnd.ms-word.document.macroEnabled.12"

Exception:
java.lang.IllegalArgumentException: No supported documents found in the OOXML package

It is not desperately necessary because with the XWPFWordExtractor class it works too. But it would be nice when this can be fixed.

Best regards,

Khalid
Comment 1 Nick Burch 2008-08-27 03:32:13 UTC
Any chance you could upload a sample .docm file?

We'll want that so we can write unit tests to ensure things work after the fix, and don't get broken again later on
Comment 2 Anton Chertov 2009-05-22 01:19:24 UTC
Created attachment 23706 [details]
Common docm file (Word 2007 macro-enabled document) causes error described
Comment 3 Anton Chertov 2009-05-22 01:21:21 UTC
The bug appears in apache-poi-3.5-beta5.
File that causes error is uploaded as an attachment.
Comment 4 Nick Burch 2009-11-03 17:36:17 UTC
I've just added a unit test for this, and it all passes just fine. I think this bug has already been fixed