You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Malcolm Rowe <ma...@farside.org.uk> on 2007/09/21 14:44:54 UTC

Re: [Issue 2938] "svn log --xml" output should include encoding information

On Fri, Sep 21, 2007 at 02:35:09PM -0000, adejong@tigris.org wrote:
> ------- Additional comments from adejong@tigris.org Fri Sep 21 07:35:09 -0700 2007 -------
> Are you saying that svn log --xml always produces output in UTF-8? I was under
> the impression that it didn't but I haven't looked at the code.
> 

This is actually a good question.  I know (or at least, I think I know)
that svn:* properties (including the svn:log revprop) are UTF-8 by
definition, but I'm not sure what the output of 'svn log --xml' (or any
other command-line tool XML output) is supposed to be: UTF-8, or
platform native.

Anyone?

Regards,
Malcolm

Re: [Issue 2938] "svn log --xml" output should include encoding information

Posted by Malcolm Rowe <ma...@farside.org.uk>.
On Fri, Sep 21, 2007 at 10:53:12AM -0400, C. Michael Pilato wrote:
> > definition, but I'm not sure what the output of 'svn log --xml' (or any
> > other command-line tool XML output) is supposed to be: UTF-8, or
> > platform native.
> > 
> > Anyone?
> 
> I guess I always assumed that our XML output was, as a rule, UTF-8
> throughout.  I can't speak (right now) to the actuality, though.
> 

Then for 'svn log', at least, it appears to DTRT: $LANG for 'svn log',
UTF-8 for 'svn log --xml'.

Regards,
Malcolm

Re: [Issue 2938] "svn log --xml" output should include encoding information

Posted by "C. Michael Pilato" <cm...@collab.net>.
Malcolm Rowe wrote:
> On Fri, Sep 21, 2007 at 02:35:09PM -0000, adejong@tigris.org wrote:
>> ------- Additional comments from adejong@tigris.org Fri Sep 21 07:35:09 -0700 2007 -------
>> Are you saying that svn log --xml always produces output in UTF-8? I was under
>> the impression that it didn't but I haven't looked at the code.
>>
> 
> This is actually a good question.  I know (or at least, I think I know)
> that svn:* properties (including the svn:log revprop) are UTF-8 by
> definition, but I'm not sure what the output of 'svn log --xml' (or any
> other command-line tool XML output) is supposed to be: UTF-8, or
> platform native.
> 
> Anyone?

I guess I always assumed that our XML output was, as a rule, UTF-8
throughout.  I can't speak (right now) to the actuality, though.

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand


Re: [Issue 2938] "svn log --xml" output should include encoding information

Posted by Arthur de Jong <ad...@tigris.org>.
On Fri, 2007-09-21 at 17:13 +0200, Erik Huelsmann wrote:
> The normal output should be platform-locale, but all XML output is
> supposed to be UTF-8. I say supposed, because Subversion assumes UTF-8
> data everywhere and doesn't verify in all places that it actually *is*
> UTF-8. So, if an svn:log property doesn't contain valid UTF-8, svn log
> --xml won't output valid UTF-8...

Thanks for the clarification. It turns out that there were probably non
UTF-8 log messages coming from a conversion from CVS that triggered the
original report.

Anyway, having the encoding explicitly in the XML declaration (original
request in the issue) could avoid further confusion. I more or less
assumed that since svn log was locale-dependant, svn log --xml would
also be.

-- 
-- arthur - adejong@tigris.org - http://ch.tudelft.nl/~arthur --

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: [Issue 2938] "svn log --xml" output should include encoding information

Posted by Erik Huelsmann <eh...@gmail.com>.
On 9/21/07, Malcolm Rowe <ma...@farside.org.uk> wrote:
> On Fri, Sep 21, 2007 at 02:35:09PM -0000, adejong@tigris.org wrote:
> > ------- Additional comments from adejong@tigris.org Fri Sep 21 07:35:09 -0700 2007 -------
> > Are you saying that svn log --xml always produces output in UTF-8? I was under
> > the impression that it didn't but I haven't looked at the code.
> >
>
> This is actually a good question.  I know (or at least, I think I know)
> that svn:* properties (including the svn:log revprop) are UTF-8 by
> definition, but I'm not sure what the output of 'svn log --xml' (or any
> other command-line tool XML output) is supposed to be: UTF-8, or
> platform native.
>
> Anyone?

The normal output should be platform-locale, but all XML output is
supposed to be UTF-8. I say supposed, because Subversion assumes UTF-8
data everywhere and doesn't verify in all places that it actually *is*
UTF-8. So, if an svn:log property doesn't contain valid UTF-8, svn log
--xml won't output valid UTF-8...


bye,

Erik.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org