From a3933eaf40732b13dccbc0def49ef5657bc0ed06 Mon Sep 17 00:00:00 2001 From: Mariusz Nowak Date: Fri, 27 Sep 2019 12:04:22 +0200 Subject: [PATCH] Document reasoning on error silencing --- scripts/postinstall.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/postinstall.js b/scripts/postinstall.js index 9305b849b..81f5a4bdd 100644 --- a/scripts/postinstall.js +++ b/scripts/postinstall.js @@ -27,5 +27,8 @@ try { .then(() => serverless.utils.logStat(serverless, 'install')) .catch(() => {}); } catch (error) { - // fail silently + // Ignore any eventual errors. + // Package when installed globally may be installed in uncommon user contexts, + // that may lead to fs access related crashes + // when e.g. trying to access user's .serverlessrc config }