Socket
Socket
Sign inDemoInstall

node-sass

Package Overview
Dependencies
225
Maintainers
3
Versions
148
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 7.0.2 to 7.0.3

vendor/darwin-x64-93/binding.node

2

lib/extensions.js

@@ -8,3 +8,3 @@ /*!

path = require('path'),
trueCasePathSync = require('true-case-path').trueCasePathSync,
trueCasePathSync = require('true-case-path'),
pkg = require('../package.json'),

@@ -11,0 +11,0 @@ defaultBinaryDir = path.join(__dirname, '..', 'vendor');

{
"name": "node-sass",
"version": "7.0.2",
"version": "7.0.3",
"libsass": "3.5.5",

@@ -19,3 +19,3 @@ "description": "Wrapper around libsass",

"engines": {
"node": ">=14"
"node": ">=12"
},

@@ -64,9 +64,10 @@ "main": "lib/index.js",

"lodash": "^4.17.15",
"make-fetch-happen": "^10.0.4",
"meow": "^9.0.0",
"nan": "^2.13.2",
"node-gyp": "^9.0.0",
"node-gyp": "^8.4.1",
"npmlog": "^5.0.0",
"request": "^2.88.0",
"sass-graph": "^4.0.1",
"stdout-stream": "^1.4.0",
"true-case-path": "^2.2.1"
"true-case-path": "^1.0.2"
},

@@ -73,0 +74,0 @@ "devDependencies": {

@@ -22,6 +22,6 @@ # node-sass

Node 16 | 6.0+ | 93
Node 15 | 5.0+, <7.0 | 88
Node 15 | 5.0+, <7.0 | 88
Node 14 | 4.14+ | 83
Node 13 | 4.13+, <5.0 | 79
Node 12 | 4.12+, <8.0 | 72
Node 12 | 4.12+ | 72
Node 11 | 4.10+, <5.0 | 67

@@ -82,3 +82,3 @@ Node 10 | 4.9+, <6.0 | 64

```shell
npm install -g mirror-config-china --registry=https://registry.npmmirror.com
npm install -g mirror-config-china --registry=http://registry.npm.taobao.org
npm install node-sass

@@ -496,3 +496,3 @@ ```

[@10xLaCroixDrinker](https://github.com/10xLaCroixDrinker) wrote a [DocPad](http://docpad.org/) plugin that compiles `.scss` files using node-sass: <https://github.com/docpad/docpad-plugin-nodesass>
[@10xLaCroixDrinker](https://github.com/10xLaCroixDrinker) wrote a [DocPad](http://docpad.org/) plugin that compiles `.scss` files using node-sass: <https://github.com/10xLaCroixDrinker/docpad-plugin-nodesass>

@@ -499,0 +499,0 @@ ### Duo.js extension

@@ -8,3 +8,4 @@ /*!

path = require('path'),
fetch = require('make-fetch-happen'),
request = require('request'),
log = require('npmlog'),
sass = require('../lib/extensions'),

@@ -24,4 +25,17 @@ downloadOptions = require('./util/downloadoptions');

var reportError = function(err) {
var timeoutMessge;
if (err.code === 'ETIMEDOUT') {
if (err.connect === true) {
// timeout is hit while your client is attempting to establish a connection to a remote machine
timeoutMessge = 'Timed out attemping to establish a remote connection';
} else {
timeoutMessge = 'Timed out whilst downloading the prebuilt binary';
// occurs any time the server is too slow to send back a part of the response
}
}
cb(['Cannot download "', url, '": ', eol, eol,
typeof err.message === 'string' ? err.message : err, eol, eol,
timeoutMessge ? timeoutMessge + eol + eol : timeoutMessge,
'Hint: If github.com is not accessible in your location', eol,

@@ -35,3 +49,3 @@ ' try setting a proxy via HTTP_PROXY, e.g. ', eol, eol,

var successful = function(response) {
return response.status >= 200 && response.status < 300;
return response.statusCode >= 200 && response.statusCode < 300;
};

@@ -42,12 +56,35 @@

try {
fetch(url, downloadOptions()).then(function (response) {
fs.createWriteStream(dest).on('error', cb).end(response.data, cb);
console.log('Download complete');
}).catch(function(err) {
if(!successful(err)) {
reportError(['HTTP error', err.code, err.message].join(' '));
request(url, downloadOptions(), function(err, response, buffer) {
if (err) {
reportError(err);
} else if (!successful(response)) {
reportError(['HTTP error', response.statusCode, response.statusMessage].join(' '));
} else {
reportError(err);
console.log('Download complete');
if (successful(response)) {
fs.createWriteStream(dest)
.on('error', cb)
.end(buffer, cb);
} else {
cb();
}
}
});
})
.on('response', function(response) {
var length = parseInt(response.headers['content-length'], 10);
var progress = log.newItem('', length);
// The `progress` is true by default. However if it has not
// been explicitly set it's `undefined` which is considered
// as far as npm is concerned.
if (process.env.npm_config_progress === 'true') {
log.enableProgress();
response.on('data', function(chunk) {
progress.completeWork(chunk.length);
})
.on('end', progress.finish);
}
});
} catch (err) {

@@ -54,0 +91,0 @@ cb(err);

@@ -6,5 +6,10 @@ var proxy = require('./proxy'),

/**
* The options passed to make-fetch-happen when downloading the binary
* The options passed to request when downloading the bibary
*
* @return {Object} an options object for make-fetch-happen
* There some nuance to how request handles options. Specifically
* we've been caught by their usage of `hasOwnProperty` rather than
* falsey checks. By moving the options generation into a util helper
* we can test for regressions.
*
* @return {Object} an options object for request
* @api private

@@ -14,3 +19,3 @@ */

var options = {
strictSSL: rejectUnauthorized(),
rejectUnauthorized: rejectUnauthorized(),
timeout: 60000,

@@ -20,2 +25,3 @@ headers: {

},
encoding: null,
};

@@ -22,0 +28,0 @@

@@ -11,3 +11,3 @@ var assert = require('assert').strict,

var expected = {
strictSSL: true,
rejectUnauthorized: true,
timeout: 60000,

@@ -17,2 +17,3 @@ headers: {

},
encoding: null,
};

@@ -37,3 +38,3 @@

var expected = {
strictSSL: true,
rejectUnauthorized: true,
proxy: proxy,

@@ -44,2 +45,3 @@ timeout: 60000,

},
encoding: null,
};

@@ -64,3 +66,3 @@

var expected = {
strictSSL: true,
rejectUnauthorized: true,
timeout: 60000,

@@ -70,2 +72,3 @@ headers: {

},
encoding: null,
};

@@ -84,3 +87,3 @@

var expected = {
strictSSL: false,
rejectUnauthorized: false,
timeout: 60000,

@@ -90,2 +93,3 @@ headers: {

},
encoding: null,
};

@@ -104,3 +108,3 @@

var expected = {
strictSSL: true,
rejectUnauthorized: true,
timeout: 60000,

@@ -110,2 +114,3 @@ headers: {

},
encoding: null,
};

@@ -124,3 +129,3 @@

var expected = {
strictSSL: true,
rejectUnauthorized: true,
timeout: 60000,

@@ -130,2 +135,3 @@ headers: {

},
encoding: null,
};

@@ -132,0 +138,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc