bcoin icon indicating copy to clipboard operation
bcoin copied to clipboard

Always give stack traces for error logs

Open braydonf opened this issue 5 years ago • 7 comments

This update will log stack traces for errors (e.g. this.logger.error).

braydonf avatar May 15 '19 22:05 braydonf

@chjj Can you publish the latest changes to blgr so that this PR can include a blgr npm version in the package.json instead of referencing a specific commit?

The update to blgr in particular is this commit: https://github.com/bcoin-org/blgr/commit/f8e21fce4082835674d4f9dbe74c399de5633277

It is so that stack traces are logged for errors, it makes debugging production errors much easier

tynes avatar May 16 '19 19:05 tynes

I have another solution at https://github.com/bcoin-org/blgr/pull/5 that doesn't need the changes made to pool.js.

braydonf avatar May 17 '19 01:05 braydonf

Codecov Report

Merging #771 into master will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff           @@
##           master    #771   +/-   ##
======================================
  Coverage      62%     62%           
======================================
  Files         147     147           
  Lines       25379   25379           
======================================
  Hits        15737   15737           
  Misses       9642    9642

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update a35516d...c1d74cd. Read the comment docs.

codecov-io avatar May 17 '19 03:05 codecov-io

Okay, I've updated, and now changes to net/pool.js are not necessary.

braydonf avatar May 17 '19 03:05 braydonf

@braydonf Can you update all other dependencies as well ?

Current deps are not compatible with node-12.

nodech avatar May 17 '19 08:05 nodech

Can be done in another PR, addressing the logger stack trace issue with this one (which is now mostly https://github.com/bcoin-org/blgr/pull/5).

braydonf avatar May 17 '19 20:05 braydonf

Until blgr is released, the stacks should be available in debug.log, for anyone that finds this and needs to find the stack. Unfortunately there isn't a sha512 integrity hash for git referenced dependencies, and is without semver.

braydonf avatar May 31 '19 21:05 braydonf