Skip to content

window.p5._report is not defined #2327

Closed as not planned
Closed as not planned
@quinton-ashley

Description

@quinton-ashley

p5.js version

v1.7.0

What is your operating system?

Mac OS

Web browser and version

114.0.5735.198 (Official Build) (arm64)

Actual Behavior

Only when using the p5.js web editor I get an error saying _report is not defined at undefined.

It's on line 105 of previewEntry.js

// Monkeypatch p5._friendlyError
const { _report } = window.p5;

It seems window.p5 doesn't exist at that point.

Expected Behavior

No errors.

Steps to reproduce

Press play to see the error show up in the console:

https://editor.p5js.org/quinton-ashley/sketches/B9bcs2HOK

Working example with no errors:

https://editor.p5js.org/quinton-ashley/sketches/aRSwZGkfg

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugError or unexpected behaviors

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions