Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Benefits/Disadvantages of version Object/

by jawnsy (Novice)
on Jan 31, 2009 at 21:44 UTC ( #740469=perlquestion: print w/replies, xml ) Need Help??
jawnsy has asked for the wisdom of the Perl Monks concerning the following question:

Hello wise Monks:

I develop modules for CPAN. Generally, I see modules that are included in the Core of the perl distribution to be the "preferred" modules when solving a particular problem. So naturally, when I discovered, I started using version objects/qv() in my code.

This is a question I've searched for, on Google, on PerlMonks, but so far I have turned up nothing substantive.

Today I was discussing with mst@freenode#perl the benefits and disadvantages of I myself use it "just because" it seems like the "generally accepted" thing to do - seeing as how it's a core module. Perhaps this is the wrong way to think. It might be an important module to use, but the reasoning behind it isn't as obvious as "use warnings" or "use strict."

So, I ask you all, as a CPAN developer (ie, where there are many modules that may interact with each other in unpredictable ways), do the benefits of outweigh any reasons against its use? In general, should CPAN developers version their modules this way?

  • Comment on Benefits/Disadvantages of version Object/

Replies are listed 'Best First'.
Re: Benefits/Disadvantages of version Object/
by Herkum (Parson) on Feb 01, 2009 at 00:07 UTC
    Damian Conway encouraged its use in the Perl Best Practices, so I tried to use it. I eventually gave up because it ended up being a pain to actually try and use consistently. Since then I have not noticed many modules that actually use the module.
Re: Benefits/Disadvantages of version Object/
by bsb (Priest) on Feb 02, 2009 at 03:34 UTC

    $VERSION Archeology has info on $VERSION styles commonly used, and one comment remarking on being hard to use.

    There was a p5p thread: UNIVERSAL::VERSION and, that discusses various oddities.

    I'd be inclined to stick to old school $VERSIONs, simply because there's more useful things to work on.

Re: Benefits/Disadvantages of version Object/
by Anonymous Monk on Jan 31, 2009 at 22:09 UTC
    I find that version isn't of very little at present, maybe in a few years.
Re: Benefits/Disadvantages of version Object/
by pileofrogs (Priest) on Feb 04, 2009 at 19:23 UTC

    I think the original idea was that it would be easer to compare version notation styles. EG you could do qv('v0.1.2') == qv('0.1.2'). But, it didn't seem to survive contact with reality.