Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CPAN graph? #11

Open
wchristian opened this issue Oct 1, 2015 · 1 comment
Open

CPAN graph? #11

wchristian opened this issue Oct 1, 2015 · 1 comment

Comments

@wchristian
Copy link

I don't have the JS chops to build one myself, but i can tell you where to easily get the data.

There's the ElasticSearch-based metacpan API which is documented here and here:
https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl.html
https://github.com/CPAN-API/cpan-api/blob/master/docs/API-docs.md

To get all the distributions on CPAN, you can build on this query:
http://api.metacpan.org/v0/distribution/_search

To get the dependencies for each distribution, you can build on this query:
http://api.metacpan.org/v0/search/reverse_dependencies/MetaCPAN-API

Note also that these URLs can easily be tested on the metacpan explorer:
https://explorer.metacpan.org/#/5706053

Total graph size should be around 32469 nodes.

@anvaka
Copy link
Owner

anvaka commented Oct 8, 2015

Thank you! I tried indexing CPAN as well long time ago: https://github.com/anvaka/allcpan
But that indexer had a bug in it. If I remember correctly it was assigning each package 5,000 dependents or something like this.

I didn't have time to debug it in more details but I'll come back to it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants