Re: createrepo/utils.py

seth vidal <[email protected]>
Newsgroups gmane.linux.rpm.metadata
Message-ID <1208386142.823.158.camel@cutter>
On Wed, 2008-04-16 at 16:45 -0400, seth vidal wrote:
> On Wed, 2008-04-16 at 13:23 -0700, Toshio Kuratomi wrote:
> > > 
> > Yeah.  Forgive me for saying this, but utf8String() is a bit crazy :-)
> 
> I wrote/copied some of it about 4 years ago, but I can't remember where
> it came from conceptually. It doesn't seem like something I'd have
> thought of but I can't remember where it is from.
> 
>  It was mostly to deal with crazy random encodings coming out of various
> packages at the time, istr there was a hangup with random versions with
> garbage in changelog and other fields and this dealt with that.
> 
> lemme see if the mailing list archives show any of this off.

I figured out where this sort of came from:
 Java's unicode encode/decode attempts to convert a string and when it
cannot it replaces the bad characters with question marks and returns
whatever it gets to the caller. It does this b/c it is a string and it
is better to get some of it than none of it.


-sv
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.