Skip to content
This repository was archived by the owner on Feb 28, 2021. It is now read-only.
This repository was archived by the owner on Feb 28, 2021. It is now read-only.

Error in Safari: createStereoPanner is not a function #144

@catarak

Description

@catarak

as reported by @limzykenneth:

Nature of issue?

  • Found a bug

Details about the bug:

The code execution on the page halts because of an error thrown by p5-accessibility.js which doesn't seem to work on Safari.

  • Web browser and version: Safari 12.0.1
  • Operating System: macOS Mojave
  • Steps to reproduce this bug:
    Code to reproduce:
function setup() {
  createCanvas(windowWidth, windowHeight);
}

function draw() {
  background(200)
  rect(0, 0, 20, 50 );
}

Error:

[Error] TypeError: audioCtx.createStereoPanner is not a function. (In 'audioCtx.createStereoPanner()', 'audioCtx.createStereoPanner' is undefined)
	(anonymous function) (p5-accessibility.js:1922)
	(anonymous function)
	draw (about:srcdoc:65)
	redraw (p5.min.js:9:19203)
	(anonymous function) (p5-accessibility.js:1631)
	(anonymous function) (p5-accessibility.js:1847)
	(anonymous function) (p5-accessibility.js:1979)
	(anonymous function) (p5.min.js:8:8386)
	(anonymous function)

Because of #801 it only shows as Script error. (: line 0) on the editor's console, making this error essentially silent for most users. Only happens on Safari when accessibility is enabled.

Maybe this belongs over at p5.accessibility and I'll move it over if so, I have not tried the p5.accessibility on its own outside the web editor. Although it would be great if the error can be caught so that it doesn't halt execution in this case.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions