Skip to content

Public API to get changelog and releases #295

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

Closed
vmarchaud opened this issue Dec 21, 2017 · 19 comments
Closed

Public API to get changelog and releases #295

vmarchaud opened this issue Dec 21, 2017 · 19 comments

Comments

@vmarchaud
Copy link

Hello everyone, first i'm not sure this is the right group for this issue, if not i'm will be happy to re-open it in the repo of the appropriate group :)

We (at @keymetrics) want our users to know when there are update (either minor or major) to nodejs that our customers can make in order to have better performance or new features.
We found this static file that contains all releases, we decided to use it to compute which version our customers can upgrade to, but we think an public API can benefit to the whole ecosystem, maybe for other vendor to notify their clients !

We also wanted to explain the changes for each update that we advise to do but we only found the changelogs in the main repository in markdown. We think it can be parsed from there and also exposed in a public API for everyone.

What do you guys think about this ?
Regards

@hutson
Copy link
Contributor

hutson commented Dec 22, 2017

@vmarchaud you may be interested in #290. A similar need has been documented in that issue, where a service would like to programmatically know when new releases of Node are made so that downstream consumers of the service can be notified.

@mhdawson
Copy link
Member

mhdawson commented Jan 3, 2018

@vmarchaud I'm wondering if a first step is a an npm module which parses the existing data to provide the API you are suggesting. That would provide a concrete idea of what the API would provide. Once its available we could assess its popularity and consider bringing it under the foundation repo if there is enough usage to justify it. @nodejs/release what do you thinks ?

@gibfahn
Copy link
Member

gibfahn commented Jan 3, 2018

@nodejs/release what do you thinks ?

Sounds like the right way to go.

@vmarchaud
Copy link
Author

Okay so we will start working on a proof of concept soon and get back to you when we think it's suitable for general use :)

@mhdawson
Copy link
Member

mhdawson commented Jan 4, 2018

@vmarchaud sounds good :)

@MylesBorins
Copy link
Contributor

Any updates?

@wallet77
Copy link

I'm working on it ;)

@elektronik2k5
Copy link

@wallet77 any updates? I'd like use the aforementioned API in order to automatically generate https://www.npmjs.com/package/node packages via @aredridel's https://github.com/aredridel/node-bin-gen project.
I see that nvs is parsing the node github releases page for this purpose. Is that a viable alternative to a dedicated, proper API? Seems hackish to me, especially if node will stop releasing on GitHub some day (for whatever reason).

@wallet77
Copy link

wallet77 commented Aug 27, 2018

Hi @elektronik2k5

"Great minds think alike".
I was thinking about that.
I have created a repo for a public API here : https://github.com/wallet77/nodejs_version_api
But as you can see in the code I'm also parsing a github page to retrieve version list and also changelog.

I'm not sure if there is a better solution. We can manage a local database but it means we should update it each time a new version is released. so we should be very reactive.

With this solution system is really up to date in real time, without changing the code.

But I agree main drawback is :

  • if github is down
  • if node is not release the same way as before

=> then API will fail.

I'm open to any ideas, you can share it on the repo ;)

Important remark : I will create another repo to create a node module, then basic methods can be used directly into an application (without requesting a public API).
And ofc the public API will also use this module.

@aredridel
Copy link

For those who find this later, https://nodejs.org/dist/index.json has info.

@wallet77
Copy link

@aredridel Yes this is one of the page I parse to get information.

@wallet77
Copy link

wallet77 commented Sep 1, 2018

Hi there,

Here is the first version of nodejs-versions, which retrieve information about version and changelog :
github : https://github.com/wallet77/nodejs-versions
npm : https://www.npmjs.com/package/nodejs-versions

Any help/advice is welcome.

@mhdawson it seems to fit your description

@nw
Copy link

nw commented Sep 25, 2018

I wrote a tool as well.. https://github.com/nw/node-release-lines

I extended the scope and included vulnerability info from nodejs/security-wg.

The api is fairly powerful for research. For example the number of commits by area touched from the recent release v10.11.0

{ assert: 2,
  build: 10,
  win: 5,
  crypto: 4,
  deps: 5,
  doc: 24,
  errors: 2,
  fs: 2,
  http2: 1,
  lib: 4,
  'n-api': 1,
  net: 1,
  path: 1,
  process: 1,
  src: 9,
  string_decoder: 1,
  test: 20,
  tools: 16,
  trace_events: 1,
  tracing: 1,
  util: 1,
  worker: 1 }

@mhdawson
Copy link
Member

Sorry its been a while, will try to look at the tools written.

@iamstarkov
Copy link

take a look at this https://github.com/chicoxyzzy/node-releases/

@jasonkarns
Copy link
Member

nodenv uses the index.json file from nodejs.org/dist/* to generate the build definition files for node-build: https://github.com/nodenv/node-build-update-defs

@knksmith57
Copy link
Contributor

also might be worth noting that, for release / version resolution, the zeit team and I updated http://resolve-node.now.sh (zeit/resolve-node) a while back in response to the lack of properly maintained, publicly available solutions.

The API is a JSON proxy in front of /dist/index.json that provides semver + codename resolution. no caching, so as soon as nodejs.org is updated, so is it.

$ curl -L resolve-node.now.sh/lts
v10.14.1

$ curl -L resolve-node.now.sh/lts/carbon
v8.14.0

$ curl -L resolve-node.now.sh/11.x
v11.4.0

@jasonkarns
Copy link
Member

It's also worth noting that getting latest for any major release (or codename) is also supported directly by the nodejs.org dist/ listings: (for simple use cases)

https://nodejs.org/dist/latest/
https://nodejs.org/dist/latest-carbon/
https://nodejs.org/dist/latest-v11.x/

@BridgeAR
Copy link
Member

There was no activity for a very long time and there are multiple modules out there that seem to solve the original request.

I am therefore closing this.

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