Bug 120707 - Cannot open .pages file in Writer
Summary: Cannot open .pages file in Writer
Status: RESOLVED FIXED
Alias: None
Product: Document Liberation Project
Classification: Unclassified
Component: libetonyek (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: David Tardon
URL:
Whiteboard:
Keywords:
: 120709 120714 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-10-19 13:56 UTC by Daniel
Modified: 2019-09-20 14:01 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Project Proposal.pages (144.90 KB, application/vnd.apple.pages)
2018-10-19 13:58 UTC, Daniel
Details
An Error Occured (91.44 KB, image/png)
2018-10-19 13:59 UTC, Daniel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel 2018-10-19 13:56:49 UTC
Description:
LibreOffice should support Apple Pages file. But why doesn't it happen?

Steps to Reproduce:
1. Open .pages file in LibreOffice
2. Pick .pages file to open
3. Error occured

Actual Results:
It should be supported .pages file and automatically open in Writer

Expected Results:
But in fact it didn't happen.


Reproducible: Always


User Profile Reset: No



Additional Info:
I have made some document in Apple Pages via iCloud Web Browser and pick-up some template and save it as .pages file. If I open in Writer, error occurred was happened.
Comment 1 Daniel 2018-10-19 13:58:58 UTC
Created attachment 145828 [details]
Project Proposal.pages

This is some sample Apple pages file that I couldn't have to open it.
Comment 2 Daniel 2018-10-19 13:59:47 UTC
Created attachment 145829 [details]
An Error Occured
Comment 3 Dieter 2018-10-19 18:53:13 UTC
When I try to open the file; i get the following message:

The file 'Project Proposal.pages' is corrupt and therefore cannot be opened. LibreOfficeDev can try to repair the file.

The corruption could be the result of document manipulation or of structural document damage due to data transmission.

We recommend that you do not trust the content of the repaired document.
Execution of macros is disabled for this document.

Repairing the docuemtn failed. So I would say NOTABUG.
Comment 4 Daniel 2018-10-20 16:44:37 UTC
That's not corrupt, why not try to open with Apple Pages?(In reply to Dieter Praas from comment #3)
> When I try to open the file; i get the following message:
> 
> The file 'Project Proposal.pages' is corrupt and therefore cannot be opened.
> LibreOfficeDev can try to repair the file.
> 
> The corruption could be the result of document manipulation or of structural
> document damage due to data transmission.
> 
> We recommend that you do not trust the content of the repaired document.
> Execution of macros is disabled for this document.
> 
> Repairing the docuemtn failed. So I would say NOTABUG.

That's not corrupted, I can open it normally in Apple Pages app in my iPad, even in iCloud website and free to edit. This content was trusted originally from Apple Pages app and pick-up some template to create new or edit document freely.
Comment 5 Alex Thurgood 2018-10-21 08:18:07 UTC
Confirming with 

Version: 6.1.2.1
Build ID: 65905a128db06ba48db947242809d14d3f9a93fe
Threads CPU : 8; OS : Mac OS X 10.13.6; UI Render : par défaut; 
Locale : fr-FR (fr_FR.UTF-8); Calc: group threaded

The Pages file opens correctly in Apple Pages 7.2, but fails to open in Writer with an error message that the file is corrupt.

If an attempt to repair the file is made by Writer, as suggested by the error message, the file still fails to open.
If the user decides not to try and repair the file, an error message is displayed that the file can not be opened and that an IO Error has occurred.
Comment 6 Alex Thurgood 2018-10-21 08:26:43 UTC
Reproduced also in LO5472, so I'm guessing that this is a filter problem.
Comment 7 osnola 2018-10-22 09:04:26 UTC
This file "Project Proposal.pages" is a repository and last time, I looked the sources(but this may have changed) when a file is a repository, the mechanism to find a filter stops within asking any filters if it can open or not this file. 

So I guess that the first thing to check is if org_libreoffice_comp_Writer_PagesImportFilter_get_implementation ( in core/writerperfect/source/writer/PagesImportFilter.cxx ) is called.

If yes, the problem is either in libetonyek or in writerperfect.
If not, the problem is before...
Comment 8 David Tardon 2018-12-24 10:14:09 UTC
There is an extra top-level directory in the file that contains the standard data files, e.g., "Index.zip" is stored as "Project Proposal.pages/Index.zip". I've never seen this before; consequently, libetonyek doesn't support it.
Comment 9 David Tardon 2018-12-24 10:14:55 UTC
*** Bug 120709 has been marked as a duplicate of this bug. ***
Comment 10 David Tardon 2018-12-24 10:17:07 UTC
*** Bug 120714 has been marked as a duplicate of this bug. ***