SCARY MODULE!

autarch on 2002-03-13T17:15:26

So some guy named Mark Veltzer released a distro on CPAN called "Meta".

Meta includes several _hundred_ modules!

I've looked at a few so far and many were basically empty, like Meta::Tool::Tar which appears to be a placeholder without any working code. Others add trivial extensions to existing modules like Meta::Visualization::Graph, which subclasses GraphViz to add a single method.

I wonder what exactly prevented him from sending a patch to acme. It's not like acme is inaccessible or a big jerk or something. I sent him a patch for GraphViz and he used it with some tweaks and we were all happy. I had the feature I needed, I didn't have any code to maintain, and acme had a slightly more useful module on his hands. Everyone is happy.

Some of the code in Meta might actually be useful on its own, like Meta::Lang::Perl::Pod::Docbook, which is a POD => Docbook translator. It's quite primitive at the moment, but has potential. But do I really need this guy's other 250 or so modules to use it?

Someone restrict this man's access to hallucinogenic drugs before he codes again!


Link

darobin on 2002-03-13T18:06:21

It's hard to believe, it's hard to describe... I think that one really needs to see it to grasp the sheer size of it! It's quite simply amazing.

Re:Link

autarch on 2002-03-13T19:24:09

So after I wrote my journal entry I couldn't stop looking (you know, like a traffic accident ;) There's some really great stuff in there.

Meta::Imdb::Get - for getting info off of IMDB.

Meta::Math::Matrix - cause once you have that IMDB data you just _know_ you'll want to do some matrix math with it!

Of course, the matrix module doesn't implement any useful methods, like multiplication. It just has a constructor and methods to get and set individual matrix elements.

Then, there's the Meta::Ds classes, including Meta::Ds::Ohash, which implements an ordered hash, _just like_ Tie::IxHash (which has been on CPAN for _years_). It also implements Meta::Ds::String with handy methods like set_text, for when $string = "text" is just too damn complicated.

There's a butt-load of XML related stuff, both generic and Docbook. A config file reader (or more than one, I can't tell?). Then we move over to Meta::Utils, which has Meta::Utils::String! This contains such gems as this:


sub compare($$) {
        my($a,$b)=@_;
        return($a cmp $b);
}


Because "cmp" is just not sufficient for me!

There's some code under Neta::Widget::Gtk cause _obviously_ none of this would be useful without Gtk support. Of course, 2 of the 4 modules in that hierarchy are empty placeholders.

How about some DB stuff? You got it. Check out Meta::Db::Dbi, which contains such gems as this:


sub begin_work($) {
        my($self)=@_;
        my($sth)=$self->{HANDLE}->begin_work();
        if(!defined($sth)) {
                Meta::Utils::System::die("unable to begin_work");
        }
}


Umm, the begin_work method does _not_ return a statement handle, but this code will work because it does it does return a boolean result code.

The doubly amusing thing is that this is a DBI wrapper that it mostly has pretty much exactly the same names as the relevant DBI methods! When most people write DBI wrappers they at least make it simpler than DBI in various ways.

Meta::Db::Reserved contains some 500 or so lines like this in a BEGIN{} block:


$hash->{"ABS"};
$hash->{"ABSOLUTE"};


Apparently, it contains a list of all the reserved words for _every_ RDBMS under the sun. Um, useful.

Then there's modules that simply define a Class::DBI subclass for a table like "person" for a movie database or "section" for a man page schema.

Apparently it all interacts with the Aegis system in some strange way, since various random classes (like the SOAP server class) make calls to Aegis-related modules.

Ok, I really need stop and take a tranquilizer now. I feel funny.

Re:Link

djberg96 on 2002-03-13T19:37:09

Meta::Imdb::Get - for getting info off of IMDB. Meta::Math::Matrix - cause once you have that IMDB data you just _know_ you'll want to do some matrix math with it!

Didn't you know? That method is specially designed for information retrieved from IMDB about The Matrix. :-P

Sorry, I couldn't resist

What is it _for_?

davorg on 2002-03-13T19:12:05

The README isn't exactly enlightening either.

The idea is to provide a full class library to accomplish many tasks.

But what sort of tasks?

Re:What is it _for_?

autarch on 2002-03-13T19:24:44

I think the main thing accomplishes, at least for me, is stimulating a convulsive clenching of my stomach.

Re:What is it _for_?

jdavidb on 2002-03-13T22:18:39

Did you check out the "autogenerated" license?

Damnit

Matts on 2002-03-14T00:14:40

Its art. You need ask no more. It's just art.

This module is EXACTLY what I've been looking for all my life.

Re:Damnit

autarch on 2002-03-14T06:00:39

It took you this long to find a giant steaming turd? Apparently, you have poor looking skills.

Re:Damnit

Matts on 2002-03-14T10:01:41

What got in your knickers?

Re:Damnit

koschei on 2002-03-14T14:38:36

If it's anything like what I'm thinking: I may release some crap on CPAN, but I also release some good stuff. And I keep them separate, not in one extensive package.

Basically, it'd be nice seeing a lot of these modules as individual modules. e.g. WWW::IMDB. Ah well.

Maybe someone should send him an email =) autarch? =)

Re:Damnit

autarch on 2002-03-14T16:51:39

I don't think I'm the right one to do that. I have something in my knickers ;)

Re:Damnit

koschei on 2002-03-14T16:56:37

Sure you are - you're passionate =)

Re:Damnit

autarch on 2002-03-14T17:49:00

I'm just grumpy ;)

Re:Damnit

koschei on 2002-03-14T23:31:06

There's a difference between the two states?