http-party/node-portfinder

stopPort is now exclusive since 1.0.22 (Breaking change?)

yuchenshi opened this issue · 1 comments

Before, if stopPort is 9000, portfinder will try up to 9000 and see if it is open. With the new 1.0.22 release, portfinder seems to exclude 9000. This is seen in the code to generate candidatePorts, where it now reads i < options.stopPort instead of <=.

This is especially troublesome in firebase-tools, where we use the same port and stopPort (effectively only check if a single port number is open or not). The change in 1.0.22 completely broke firebase-tools where portfinder is used. See
firebase/firebase-tools#1606 (comment)

this should be fixed, i rolled back v1.0.23 -> v1.0.21