WebGPU uncaptured error

Since the 6.3 update, many errors have appeared for WebGPU.

I think it must correspond to this updates that was made:

WebGPU: Update TWGSL

Here are all the errors I get in 6.3 (In 6.2 I don’t have any errors in the console):

ping @Evgeni_Popov

I managed to reproduce the error :

Open PG with WebGPU to see errors in console

If you want to create your own engine instance, you must implement a createEngine function, so that the playground is aware of it:

But you can also simply change the engine by using the drop-down list of the Playground.

I tried to reproduce the errors I had on my project when I load the engine. The PG created a new engine and produced all the errors.

My question wasn’t how to load a motor into the playground.

Version 6.2, I had no problem and with version 6.3 I have all its errors by loading the WebGPU engine.

Since my project is not the playground, I don’t load the engine with a createEngine() function.

I end up with all its errors while it works with 6.2. What can cause its errors? Are there any changes since 6.2 that produce errors?

Sometimes I also get this error when reloading the browser (F5)

The errors I get in the console from your PG are not the errors you reported. I get:

I think you may create several engines at startup: make sure you don’t see several times the Babylon.js banner in the console. In the screenshot above, you can see there are two engines created, which should not happen.

On my project I create several engines, because I have several tabs with different canvas.

I finally understood and found the problem. So I changed my way of doing it. and it works now.
Now when I change tab, I create the engine, then I create the scene when the engine is created.

$("#RCW-GE-tabs").on( "tabsactivate", function(_event, ui) {				
			const selectedTabTitle = $(ui.newTab).text();			
			if (!zone.engine) {
				zone._createEngine().then(() => {
			if (!media.engine && selectedTabTitle == "Media") {
				media._createEngine().then(() => {
			if (!particle.engine && selectedTabTitle == "Particles") {
				particle._createEngine().then(() => {
			if (!gubbins.engine && selectedTabTitle == "Gubbins") {
				gubbins._createEngine().then(() => {
			if (!guiInterface.engine && selectedTabTitle == "Interface") {
				guiInterface._createEngine().then(() => {

@Evgeni_Popov Hi,

I figured out why I am getting his errors. In fact, if we don’t have focus on the canvas where the WebGPU engine is created, it creates all its errors.

On WebGL, I don’t have this problem.
And I didn’t have this problem with versions lower than 6.2 with WebGPU.

On my editor I have several tabs with a canvas on different tabs. If I load a WebGPU engine on a tab and I don’t have focus on that tab, it will generate the errors mentioned above. Which was not the case before 6.2. (These errors appeared with version 6.3.)

I don’t see what could cause these errors in 6.3, nothing in the list of changes between the two versions can explain it:

Can you re-test with 6.2 to make sure that it’s 6.3 that has the problem and that it’s not something else (like Chrome that has been updated in the meantime)?

I just tried again with 6.2. I have no errors.
I also just tested version 6.4 and I no longer have this problem.
the problem was therefore in 6.3, but I can’t explain it either.