🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
DemoInstallSign in
Socket

crashreporter

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

crashreporter

Dump node context into a file on process crash, send it by mail

1.1.0
latest
Source
npm
Version published
Weekly downloads
80
-13.98%
Maintainers
1
Weekly downloads
 
Created
Source

node-crashreporter

node-crashreporter Build StatusBuild Dependency

Dump node context into a file on process crash, send it by mail

Installing crashreporter

[sudo] npm install crashreporter

Usage

Basic

require('crashreporter');

More

require('crashreporter').configure({
    outDir: [your out directory], // default to cwd
    exitOnCrash: [true|false] // if you want that crash reporter exit(1) for you, default to true,
    maxCrashFile: [number] // older files will be removed up, default 5 files are kept
});

Advanced: send mail

See http://www.nodemailer.com/ for support

require('crashreporter').configure({
    mailEnabled: true,
    mailTransportName: 'SMTP',
    mailTransportConfig: {
        service: 'Gmail',
        auth: {
            user: "yourmail@gmail.com",
            pass: "yourpass"
        }
    },
    mailSubject: 'advanced.js crashreporter test',
    mailFrom: 'crashreporter <yourmail@gmail.com>',
    mailTo: 'yourmail@gmail.com'
});

Hidden Attributes

Hidden Attribute hide items in the email.

require('crashreporter').configure({
    ...
    hiddenAttributes: ['versions', 'error'],
    ...
});

Options

  • dateTime
  • execPath
  • argv
  • currentDirectory
  • env
  • currentDirectory
  • env
  • pid
  • gid
  • uid
  • processTitle
  • uptime
  • arch
  • versions
  • memoryUsage
  • requireCache
  • activeHandle
  • activeRequest
  • stack

File

Name

crash_YYYY-MM-DD_HH-mm-ss_zzz_UTC.txt

Dump

Date time:
-----------------------
execPath:
-----------------------
argv:
-----------------------
current directory:
-----------------------
env:
-----------------------
gid:
-----------------------
uid:
-----------------------
pid:
-----------------------
process title:
-----------------------
uptime (sec):
-----------------------
arch: x
-----------------------
versions:
-----------------------
memory usage:
-----------------------
require.cache:
-----------------------
active handle:
-----------------------
active request:
-----------------------
stack

Keywords

crash

FAQs

Package last updated on 12 Mar 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts