processing / processing/p5.js

[p5.js 2.0 Bug Report]: p5.RendererGL.js Unit Test fails

Open
#7,869 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area:WebGL p5.js 2.0+
Dominant language
JavaScript
Stars
24k
Forks
3.8k
Avg merge
3d 16h
Merged PRs (30d)
25

Description

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.2

Web browser and version

Chrome, 137.0.7151.55

Operating system

MacOS Sequoia 15.1.1

Steps to reproduce this
Steps:
  1. Run npx vitest run.
  2. The tint should be reset after draw loop test in the tint() in WEBGL mode suite (path: test/unit/webgl/p5.RendererGL.js) is flaky and intermittently times out with the error shown below.
Snippet:
FAIL |unit|  test/unit/webgl/p5.RendererGL.js > p5.RendererGL > tint() in WEBGL mode > tint should be reset after draw loop
Error: Test timed out in 1000ms.
If this is a long-running test, pass a timeout value as the last argument or configure it globally with "testTimeout".
Screenshot:
Image

I have not been able to analyse root cause yet or attempt a fix.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Run npx vitest run and focus on the tint should be reset after draw loop test in test/unit/webgl/p5.RendererGL.js. Investigate why it intermittently exceeds the 1000ms timeout, then verify that the WebGL test completes reliably without timing out.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
computer-graphics, testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.