[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Escapes in configuration (svn:ignore in dir-auto-props)

From: Branko Čibej <brane_at_xbc.nu>
Date: 2005-04-08 10:32:09 CEST

Ph. Marek wrote:

>On Friday 08 April 2005 01:54, Branko Čibej wrote:
>
>
>>Ph. Marek wrote:
>>
>>
>>>If I understand you correctly you want several places calling the
>>>un-escape function (for auto-props, dir-auto-props, and authentication)?
>>>
>>>
>>How do these features need escaping?
>>
>>
>svn:ignore needs newlines.
>
Eh? I though we decided long ago that we won't support weirdness, e.g.
newlines, in file names.

> I expect that some user-defined file-property could
>need special characters too;
>
Subversion doesn't interpret user-defined properties. Some sort of user
app does that. The "unescape string" function could be a public API in
libsvn_subr, thus available to such a user app.

> I'd like to behave auto-properties the same for
>files and directories, it's hard to explain why some things would be
>un-escaped and others not.
>
>
I still don't understand why we need escaping in auto props.

>The authentication was a wish of Max.
>
>
>
>>>Well, there's not much I can do.
>>>We need special characters for svn:ignore _and_ for the auth info
>>>(http://marc.theaimsgroup.com/?l=subversion-dev&m=111175528516724&w=2), so
>>>compatibility _has_ to give somewhere.
>>>
>>>
>>It's not just about compatibility with Python, it's also about
>>compatibility with previous versions of Subversion. It'd be very weird
>>if one upgraded svn and suddenly the config files stopped working
>>because, e.g., one was on Windows an put backslashed paths into the
>>config file.
>>
>>
>I'd say, that the packagers (eg. debian) should test for this case and provide
>some support for that.
>But you're right, on upgrade it's very likely that something will break.
>
>
Indeed. And we've never relied on packagers for backward compatibility,
and I hope we don't start now.

>OpenSSH solved a similar problem by using a "authorized_keys2" file instead of
>"authorized_keys", which was parsed some other way; and by now they've
>deprecated the old format, and both files are parsed the same way.
>
>So possibly we should a "config2" file which has this parsing - people who
>need that, can rename the file and change the contents.
>
>
>Do Python config files support any way of escaping?
>
>
Not according to the Python manuals.

>I've thought about other encoding schemes, but it's always possible (and
>sometimes likely) that something will break.
>
>
Yes. That's why I really, really suggest we have a separate unescape
function. I wouldn't even object to a svn_config_get_unescaped that
would automatically call the unescape function before returinig the
data, but I'm adamantly -1 on the idea that _all_ config values were
unescaped during parsing.

-- Brane

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Apr 8 10:33:05 2005

This is an archived mail posted to the Subversion Dev mailing list.