Skip to content

[wasm-mt] Hook up webworker console to xharness websockets #72606

Closed
@lambdageek

Description

@lambdageek

Similar to what is done for the crypto WebWorker, we need to redirect console.{log,info,warn,error,trace} to a websocket back to xharness for testing purposes.

See

export function setup_proxy_console(id: string, originalConsole: Console, origin: string): void {

and

async function mono_wasm_pthread_worker_init(): Promise<void> {

(note we don't want to set up the redirection on pthread creation - we want to do it when the worker that will run pthreads is created. Emscripten reuses workers to run pthreads when one thread shuts down and another one starts)

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions