Skip to content

[p5.js 2.0 Bug Report]: FES throws an error when processing internal errors, producing confusing output #8174

@davepagurek

Description

@davepagurek

Most appropriate sub-area of p5.js?

  • Accessibility
  • Color
  • Core/Environment/Rendering
  • Data
  • DOM
  • Events
  • Image
  • IO
  • Math
  • Typography
  • Utilities
  • WebGL
  • Build process
  • Unit testing
  • Internationalization
  • Friendly errors
  • Other (specify if possible)

p5.js version

2.0.5 (Anything 2.0 and above)

Web browser and version

Firefox 143

Operating system

MacOS

Steps to reproduce this

Steps:

  1. Trigger an internal library error, e.g. https://editor.p5js.org/davepagurek/sketches/eR9paTywq (see [p5.js 2.0 Bug Report]: p5.MediaElement.connect throws error: fn is not defined #8173)

The FES output shows two errors, the top one being:

TypeError: can't access property "functionName", stacktrace[(friendlyStack[0].frameIndex - 2)] is undefined

This is due to FES trying to parse the error stack and creating a new error accidentally.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions