question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Better stack traces

See original GitHub issue

So we’ve just shipped new stack traces in RunKit, and I’d really like Ramda to have easier to read stack traces (even outside of our tools). Currently it contains lots of Object.f2s and such, and I did a few experiments with setting functions names.

Here you can see what Ramda looks like currently:

screen shot 2017-02-01 at 9 31 39 pm

( https://runkit.com/tolmasky/ramda-current-traces )

And here is what they could look like:

screen shot 2017-02-01 at 9 31 47 pm

( https://runkit.com/tolmasky/ramda-better-traces-22 )

Basically, the trick is to do something like this:

function functionNamed(aFunction, aName)
{
    Object.defineProperty(aFunction, "name", { value: aName });
    aFunction.displayName = aName;

    return aFunction;
}

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:7
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

4reactions
CrossEyecommented, Feb 2, 2017

I was hot on this some time back, using techniques from https://medium.com/@drboolean/debugging-functional-7deb4688a08c#.f0g8hif9c but I never got finished with it. I would love to see something like this in the library, as much for debugging consoles as for stack traces.

It’s a fair bit of work, but I think it would be worth it.

1reaction
CrossEyecommented, Mar 11, 2017

Feel free. I absolutely think it is worth doing.

Read more comments on GitHub >

github_iconTop Results From Across the Web

mjpizz/better-stack-traces - GitHub
Detailed stack traces with code snippets for node. - GitHub - mjpizz/better-stack-traces: Detailed stack traces with code snippets for node.
Read more >
better-stack-traces - npm
Detailed stack traces with code snippets.. Latest version: 1.1.0, last published: 8 years ago. Start using better-stack-traces in your ...
Read more >
Stack Trace Formatter - Pretty print your exception messages
Using the .NET stack trace formatter, you can pretty print any stack trace and either copy and paste it or download a screenshot...
Read more >
Better Exception stack traces in .NET with Ben.Demystifier
Become a Patreon and get source code access: https://www.patreon.com/nickchapsasCheck out my courses: https://nickchapsas.
Read more >
The Dreaded Stack Trace - Joseph Gefroh
You can keep scrolling to go deeper and see more inner errors that may have triggered the error. Examples. Below is an example...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found