Hugh Sasse <[EMAIL PROTECTED]> writes:

>> Really? String#<=> is pretty well-understood as far as I can tell.
>
> Oh, I bet will get scarier than that: Locale, current character set, 
> multibyte chars, utf-[8,16,32], and is the -K option in use, and are
> we doing case sensitive matches or not?  {Is anyone still using EBCDIC?
> I hope not, that's scarier than some of the things lurking in Dwemthy's
> Array! :-)}

It shouldn't be a surprise that things will break if you put a character
with locale-dependent sorting in your version string. We don't have to
support *every* string, merely that subset of strings that gem authors (on
the whole a reasonable bunch, if I may generalize) would pick as version
numbers.

True; there's some potential insanity lurking there. But I think if
you're going to go off the beaten track, it's pretty easy to make sure
things are sorting the way you expect using IRB.

>> 1.0.0.1 looks like a very-minor increment on a 1.0.0 release. If I were
>> to see that version available without reading through all the release
>> announcements, I would have gone ahead and installed it. Any scheme that
>> relies on users being thorough about reading the release notes is
>> suspect in my mind.
>
> Agreed, but we do have a tradition in the Ruby world about odd minor
> version numbers

Well, we *had* that tradition, but now Ruby 1.9.1 is going to be
considered the stable release.

> so another convention for what I've called tiddler numbers seems
> possible. Staying numeric would be better. 

The problem with this is that it makes the number of digits
significant. Rubygems doesn't currently force the use of three
dot-separated parts. Most projects use that, but it's not enforced.

If we change what is allowed, it should be as a superset of what's
currently allowed, or we will introduce resistance to upgrades.

> If not negatives, then maybe a number that can only be read as Hex
> might work, except a naive to_i would turn it to 0.  "To 0xff thou
> shalt not count, and complex is right out!".  That only leaves
> rationals unexplored and allowing a / in the version number might
> allow people to be scared off sufficiently, version 1.0.0.2/3 looks
> pretty odd.
>
> I only offer these in the hope that they'll spark something useful,
> since in themselves they are not, I think.  Lateral thinking is about
> getting to a better place from here if there is such a place.

There's certainly a place for brainstorming, as long as it's clear
that's what's happening rather than a serious suggestion. =)

-Phil
_______________________________________________
Rubygems-developers mailing list
Rubygems-developers@rubyforge.org
http://rubyforge.org/mailman/listinfo/rubygems-developers

Reply via email to