Skip to content

Dependents tooling #327

Open
Open

Description

@andrewhughes101

As a follow on from #307 I've started looking into the best way to get a modules dependents. So far the only way I've found how to do it is to scrape the npm site on this endpoint https://www.npmjs.com/browse/depended/express

Does anyone know of any alternative way or if there is an endpoint on http://registry.npmjs.org/ that would return the dependents?

Activity

  1. vweevers commented on Mar 16, 2020

    @vweevers

    For scraping, you might like npm-dependants. There's no official API. The only other option is to replicate the registry (can take a few hours), e.g.:

    const registry = require('package-stream')({
      // Update sequence (seq) to start from.
      since: 0
    })
    
    registry
      .on('package', (pkg, seq) => {})
      .on('up-to-date', () => {})

    I've been thinking it'd be nice to have a service that continuously replicates, puts the packages in a graph database, and exposes an HTTP API (vweevers/about-native-addons#4).

  2. ghinks commented on Mar 21, 2020

    @ghinks
    Contributor

    I was going to raise an issue with a similar request. As I have actually started to look at modules that need to be maintained within the expressJS system I see a need for a tool like this.

    I do not believe there is a tool that does this currently. Is this something that @darcyclarke or @ruyadorno could help us with? Even add hoc requests that get solved off line would be valuable.

  3. andrewhughes101 commented on Mar 24, 2020

    @andrewhughes101
    ContributorAuthor

    For the first draft of the tool I've created this repo https://github.com/andrewhughes101/dependents-testing

  4. dominykas commented on Mar 27, 2020

    @dominykas
    Member

    @andrewhughes101 did you want a repo under pkgjs for this? Do we have a name?

  5. andrewhughes101 commented on Mar 27, 2020

    @andrewhughes101
    ContributorAuthor

    @andrewhughes101 did you want a repo under pkgjs for this? Do we have a name?

    yes please, Do you think the name dependents-testing is ok?

  6. ljharb commented on Mar 27, 2020

    @ljharb
    SponsorMember

    At the moment, it just lists dependents - is it planned to test them too, or is that a separate package? If it's just for listing them, then probably just dependents?

  7. andrewhughes101 commented on Apr 1, 2020

    @andrewhughes101
    ContributorAuthor

    dependents is good with me, maybe it would be better to split the testing inot a seperate package

  8. dominykas commented on Apr 1, 2020

    @dominykas
    Member
  9. andrewhughes101 commented on Apr 27, 2020

    @andrewhughes101
    ContributorAuthor

    As discussed in the last meeting the next steps is to create the basic CLI testing tool that takes in a list of dependents from pkgjs/dependents, detects which branch you are on and opens a PR to change the version field of the package the dependent is depending upon for the current branch.

    I think we also need a new repo in pkgjs for this tool, so I will open an issue for the new repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions