Skip to content

[p5.js 2.0+ Bug Report]: createVector() gives error "TypeError: this._friendlyError is not a function" #8818

@sidwellr

Description

@sidwellr

Most appropriate sub-area of p5.js?

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

p5.js version

v2.3.0-rc.1

Web browser and version

Brave 1.90.122

Operating system

Linux Mint 6.8.0-117

Steps to reproduce this

I was trying v2.3.0-rc.1 with the code snippet from issue 8117 to see if this release candidate fixed that issue. The createVector() line started giving a warning in version 2.1 to always use arguments when calling createVector. But v2.3.0-rc.1 gives a hard error "TypeError: this._friendlyError is not a function".

Snippet:

function setup() {
  createCanvas(400,400);
  const v=createVector(100,0);
  const w=createVector();
  v.sub(w);
  console.log(v.toString());
  v.rotate(1);
  console.log(v.toString());
}

Metadata

Metadata

Assignees

Type

No fields configured for Bug.

Projects

Status

No status

Relationships

None yet

Development

No branches or pull requests

Issue actions