Downloading stuff from CPAN, I have found inconsistencies in the management of module dependencies.
Some explicitly check and try to get needed modules.
Some fail gracefully and CPAN.pm asks if you want to get them.
Some just fail during testing and leave you to handle it.
So... I thought it would be nice to build a graph of the dependencies.
I have put together some code to look through all of the installed modules and store in a mysql database the following :
- Package Name
- Date installed
- Array of pragmas used
- Array of modules used
The intention is to allow me to easily generate a graph and some statistics re. the modules.
Before I spend more time on this, I would appreciate some thoughts from you folks.
Has this been done before ? (I looked on CPAN and SuperSearch and didn't find anything)
Would other find it usefult to have this ?
What sort of output would be useful ?
In answer to the last, I am toying with :
- Just leave it in the database.
- A Web tool which allows browsing up and down the chains.
- A visual graph (e.g. using GraphViz)
Item 2 is my favourite and shouldn't be too hard. Visually it will be difficult to display the whole thing, since I have 1040 rows in the table (=packages installed).
Have now done some more work on item 2, sample browser is at Here.
Taking DrZaius's advice, it now also reads the perllocal.pod to get more info and throws that in as well.
Have also added a reverse table, which allows you to see which modules a modules is used by.
The overall effect allows you to browse up and down the tree as you like.
Of course, to solve the original problem of finding out what modules I need to install, this really needs to run on CPAN...
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
Outside of code tags, you may need to use entities for some characters:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
| & || & |
| < || < |
| > || > |
| [ || [ |
| ] || ] |