renovatebot / config-help

Please use the Discussions feature of https://github.com/renovatebot/renovate instead
https://github.com/renovatebot/renovate/discussions
MIT License
27 stars 16 forks source link

not updated for unstable release #20

Closed teppeis closed 6 years ago

teppeis commented 6 years ago

My package.json has "husky": "^0.15.0-rc.8" in deps and the latest version is 0.15.0.rc.12, but it is not updated by renovate.

Reading the docs,

Renovate won’t update any packages to unstable versions (e.g. 4.0.0-rc3) unless the package version was already unstable (e.g. it was already on 4.0.0-rc2). https://renovateapp.com/docs/configuration-reference/configuration-options#ignoreunstable

I expect that husky is updated, but actually not.

npm show husky shows

'dist-tags': {latest: '0.14.3', next: '0.15.0.rc.12' },

I guess renovate uses only latest tag, not the other tags like next.

rarkins commented 6 years ago

Your package.json is not updated because 0.15.0.rc.12 satisfies your range ^0.15.0-rc.8 and hence there is no need to update.

The reason to use ranges in package.json files is if you want to support a range of multiple versions and not be overly restrictive. If it's your goal to always have the latest version then you should be pinning your dependencies instead. As husky is typically a devDependency you should be pinning them if your expectation is to restrict them to the latest version anyway.

I guess renovate uses only latest tag, not the other tags like next.

No, that's not the case. next is a non-standard tag anyway so has no effect. You could have a tag called previous or really-old-version-from-2015 and they would be ignored too.

rarkins commented 6 years ago

You might also be interested in the option upgradeInRange but I think you might end up confusing yourself or other users if you (a) look like you support ranges, but (b) always end up with a range containing 1 dependency anyway. Better to pin and make it clear to everyone about which version is used/installed.

teppeis commented 6 years ago

@rarkins upgradeInRange is enabled and Renovate sends PRs to update other deps/devDeps except for husky.

I agree that pinning version is reasonable for devDeps (yes, husky is in devDeps), but it's not suitable for deps. I want to know the spec or behavior of Renovate for the future.

My following understand is correct?

rarkins commented 6 years ago

Hi @teppeis thanks for the additional details. It is not intentional/deliberate that the new husky update should be missed out if indeed you have enabled upgradeInRange, but maybe that feature is not working nicely with the stable/unstable logic. Could you raise an bug report in the main Renovate repository so that I can put it in my queue to look into and fix if necessary?