emscripten
                                
                                
                                
                                    emscripten copied to clipboard
                            
                            
                            
                        Running browser.test_wasmfs_opfs_jspi twice causes tack overflow error
It seems like maybe some state must be left behind and affecting the second run.
+/report_result?exception:
Maximum call stack size exceeded / RangeError: Maximum call stack size exceeded    at 
test.wasm.operator_new_impl(unsigned long) (http://localhost:8888/test.wasm:wasm-function[142]:0x68bf)    at 
test.wasm.operator new(unsigned long) (http://localhost:8888/test.wasm:wasm-function[141]:0x68b0)    at
test.wasm.(anonymous namespace)::OPFSBackend::createDirectory(unsigned int) (http://localhost:8888/test.wasm:wasm-function[297]:0x8848)    at
 test.wasm.doMkdir(wasmfs::path::P[..]
                                    
                                    
                                    
                                
Is there a command line option to run the test twice or how are you running it twice in one session?
FWIW, I tried just duplicating the two self.btest_exit lines multiple times and it seems to run fine.
Hmm.. I as able to repro the other day, and I've seen in in the CI.. but I'm not sure if it consistent. I'll try again now..
I'm seeing this issue on some CI runs. e.g.: https://app.circleci.com/pipelines/github/emscripten-core/emscripten/34717/workflows/01f23013-b724-4ec3-81b3-33a49727d0ab/jobs/775610
======================================================================
FAIL [3.019s]: test_wasmfs_opfs_jspi (test_browser.browser_2gb)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/root/project/test/common.py", line 2080, in run_browser
    self.assertContained(expected, output)
  File "/root/project/test/common.py", line 1410, in assertContained
    additional_info
  File "/usr/lib/python3.6/unittest/case.py", line 670, in fail
    raise self.failureException(msg)
AssertionError: Expected to find '/report_result?exit:0
' in '/report_result?exception:Maximum call stack size exceeded / RangeError: Maximum call stack size exceeded    at http://localhost:8888/test.wasm:wasm-function[108]:0x7059    at http://localhost:8888/test.wasm:wasm-function[44]:0xfd5    at http://localhost:8888/test.wasm:wasm-function[167]:0xdf46    at http://localhost:8888/test.wasm:wasm-function[127]:0xb271    at http://localhost:8888/test.wasm:wasm-function[266]:0x10c39    at http://localhost:8888/test.wasm:wasm-function[197]:0xec9c
', diff: