RE: Whitepsace in filenames in zip problems

Hi Nic,

 

The name comes from the pxp:unzip step. So, this name contains a space also.

 

Erik

 

Van: Nic Gibson [mailto:nicg@corbas.co.uk] 
Verzonden: donderdag 15 mei 2014 10:06
Aan: xproc-dev@w3.org
CC: Erik Siegel
Onderwerp: Re: Whitepsace in filenames in zip problems

 

Just a thought but... if you list the files in the with pxp:unzip what does the path to that file look like?

 

nic

 

  _____  

From: "Erik Siegel" <erik@xatapult.nl>
To: xproc-dev@w3.org
Sent: Thursday, 15 May, 2014 8:03:32 AM
Subject: Whitepsace in filenames in zip problems

 

Hello,

 

(Using Calabash 1.0.16-95 from within oXygen)

 

I'm trying to extract a non-xml file from a zip file. The name of this file-in-the-zip contains a space. 

 

<pxp:unzip content-type="application/octet-stream">
                <p:with-option name="href" select="(ref-to-zip-file)"/>
                <p:with-option name="file" select="'content/learningunit1/script_00006/media/Bvj_1vg_oef_th1_leerdoel 6.jpg '"/>
              </pxp:unzip>

 

What I get is an error message like:

 

Pipeline failed: java.lang.IllegalArgumentException: Illegal character in opaque part at index 144: zip:file:/home/conversion/in/VOoruit/ypub/projectToc_4592_1399461943.scorm.zip!content/learningunit1/script_00006/media/Bvj_1vg_oef_th1_leerdoel 6.jpg

 

(Character 144 is the space directly before the 6.jpg part)

 

I've tried to replace the offending space with a %20, but that gives me the message:

 

ZIP file does not contain 'content/learningunit1/script_00006/media/Bvj_1vg_oef_th1_leerdoel%206.jpg'

 

So, now I'm stuck... Anybody an idea how to solve this (except from forbidding spaces in filenames)?

 

Thanks,

Erik Siegel

 

 

-- 

Corbas Consulting / @CorbasLtd
Digital Publishing Consultancy and Training
http://www.corbas.co.uk, +44 (0)7718 906817/+44 (0)1273 930765

 

Received on Thursday, 15 May 2014 08:11:31 UTC