-
Notifications
You must be signed in to change notification settings - Fork 63
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
fix: target tough-cookie 2.x to preserve node 6 support #33
Conversation
@@ -146,7 +146,7 @@ describe('Request-Promise-Native', function () { | |||
var cookiejar = rp.jar(); | |||
|
|||
expect(function () { | |||
cookiejar.setCookie(sessionCookie, 'https://api.mydomain.com'); | |||
cookiejar.setCookie(sessionCookie.toString(), 'https://api.mydomain.com'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See: request/request-promise#277
Gets the CI back to being green for modern node versions. Likely a similar issue plagues Node 0.12.0 and iojs builds.
package.json
Outdated
"stealthy-require": "^1.1.0", | ||
"tough-cookie": ">=2.3.3" | ||
"stealthy-require": "^1.1.1", | ||
"tough-cookie": "^2.5.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fix
package.json
Outdated
}, | ||
"peerDependencies": { | ||
"request": "^2.34" | ||
"request": "^2.88.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jasonmit if you update the peer dep here you will need to update the dev dep below too. but why did you update the peer dep in the first place? is it required for the fix to work? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, removed! (Left over fragment as I was debugging the broken CI pipeline)
@analog-nico do you have time to look at this in the next days? seems like this is breaking CI for quite a lot of packages lately, especially incombination with salesforce/tough-cookie#140, which essentially now retroactively makes this project support only Node 8 and above 😞 |
/cc @mikeal since you're still active and part of the org. Any chance you have publishing rights? |
Hey @jasonmit @Turbo87 quick question: My assumption is that |
the problem is that npm and yarn will install the latest compatible version, ignoring the Node.js compatibility. means if you run Node 6 it would try to install the latest version, which needs Node 8+ and then the install will fail. |
Thank y’all!
|
awesome, thanks! do you have access to the other request-promise packages too? I think they had similar problems |
My pleasure @Turbo87 ! Yes, I updated all packages in this family at the same time. |
Tough-cookie now ends up resolving to 3.0.0 (published today) which drops support for Node 6.
Node 0.12.0 and iojs builds are failing but not because of this PR.