isolated-function 0.1.43 → 0.1.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "isolated-function",
3
3
  "description": "Runs untrusted code in a Node.js v8 sandbox.",
4
4
  "homepage": "https://github.com/Kikobeats/isolated-function",
5
- "version": "0.1.43",
5
+ "version": "0.1.45",
6
6
  "types": "src/index.d.ts",
7
7
  "main": "src/index.js",
8
8
  "exports": {
@@ -32,6 +32,7 @@ module.exports = async (snippet, tmpdir = tmpdirDefault) => {
32
32
  }
33
33
 
34
34
  const result = await duration('esbuild', () => build({ content, cwd }))
35
+ debug('esbuild:output', { content: result.outputFiles[0].text.length })
35
36
  content = result.outputFiles[0].text
36
37
  const cleanupPromise = duration('tmpDir:cleanup', cleanup)
37
38
 
package/src/index.js CHANGED
@@ -61,6 +61,7 @@ module.exports = (snippet, { tmpdir, timeout, memory, throwError = true, allow =
61
61
  })()
62
62
  : { isFulfilled: false, value: deserializeError(value), profiling, logging }
63
63
  } catch (error) {
64
+ console.log('DEBUG ERROR', error)
64
65
  if (error.signalCode === 'SIGTRAP') {
65
66
  throw createError({
66
67
  name: 'MemoryError',