[armedbear-devel] Spaces in pathnames (jar:file:/x/y/z/a space/...)

Mark Evenson evenson at panix.com
Sat Jun 4 06:59:36 UTC 2011


On 6/4/11 6:43 AM, Theam Yong Chew wrote:
[…]

> What's the effect of the latest Pathname.java work on this bug I
> reported a few months ago?

If you are referring to the changes culminating [r13302 as the latest 
work on Pathname.java][r13302], I wouldn't expect any change in the URI 
escaping behavior as this work only dealt with the version component. 
Ville had done some other work about a month ago, but I think he 
retracted his patch as it caused more problems than it solved.

[r13302]: http://trac.common-lisp.net/armedbear/changeset/13302
	
> The one line patched I included then seemed to fix the loading of jar
> files with spaces in their pathnames, but then fails when loading .abcl
> files with spaces in their pathnames... so it still wasn't right.
>
> I haven't been able to follow in detail (but I haven't looked too
> deeply) the pathname creation, defaulting of various fields and path
> escaping logic myself. Any ideas on the right thing to do?

Initially, I couldn't reproduce your problems, so I didn't file a bug, 
apply your patch or investigate much further.  From re-reading the 
conversation, it looks like I assumed that your initial misunderstanding 
of the URI escaping bit was cleared up, and that things were working for 
you.  Sorry for my confusion.

After your latest email, I was able to find a problem, but not in any of 
the cases your explicitly mention:

To be clear I can

a)  LOAD a fasl ("an *.abcl file") with a space in its pathname

(load "/Users/evenson/work/abcl/bugs/foo bar.abcl")
	
b)  LOAD a fasl from a jar file with a space in the jar pathname

(load 
"jar:file:/Users/evenson/work/abcl/bugs/a%20space/foo%20bar.abcl!/foo._")

what I can't do with the current trunk code is

c)  Load a fasl with a space in its name from a jar

;;; FAILS
(load "jar:file:/Users/evenson/work/abcl/bugs/xx.jar!/xx/foo bar.abcl")

Can you verify that only the last case fails for you without your patch? 
  Can you provide additional examples of bad behavior?

Alessio's point that we need to clearly identify which parts of the 
Pathname need escaping should clearly be addressed.

I've filed [ticket #151][#151] to keep track of this issue.  When we 
agree to the extent of the problem, i.e. identify all the failures, 
we'll take a stab at fixing things.  Currently, I'm thinking we should 
add flags for Pathname components that can be strings to record when we 
have already performed URI conversions.

Apologies for my initial misinterpretation: let's try to be as clear as 
possible to fix this correctly.

[#151]: http://trac.common-lisp.net/armedbear/ticket/151

-- 
"A screaming comes across the sky.  It has happened before, but there
is nothing to compare to it now."




More information about the armedbear-devel mailing list