hi Any one facing this error when running `wasmJs...
# webassembly
a
hi Any one facing this error when running
wasmJsBrowserTest
?
Copy code
Module parse failed: Identifier 'startUnitTests' has already been declared (20:4)
File was processed with these loaders:
 * ../../node_modules/source-map-loader/dist/cjs.js
You may need an additional loader to handle the result of these loaders.
| export const {
|     startUnitTests,
>     startUnitTests,
|     _initialize,
|     memory
b
Which kotlin version do you use? Have you tried
clean build
?
a
I did ☝️ I'm using kotlin
2.0.20
full error looks like this
Copy code
./gradlew wasmJsBrowserTest
Reusing configuration cache.

> Task :project:wasmJsBrowserTest FAILED




Module parse failed: Identifier 'startUnitTests' has already been declared (20:4)
File was processed with these loaders:
 * ../../node_modules/source-map-loader/dist/cjs.js
You may need an additional loader to handle the result of these loaders.
| export const {
|     startUnitTests,
>     startUnitTests,
|     _initialize,
|     memory
unable to locate 'project/build/node_modules/sql.js/dist/sql-wasm.wasm' glob


  |     memory
  at /var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/commons.js:68:1
  |     memory
      at ./kotlin/project-wasm-js-test.mjs (/var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/commons.js:68:7)
      at __webpack_require__ (/var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/runtime.js:23:41)
      at ./static/load.mjs (/var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/commons.js:80:104)
      at __webpack_require__ (/var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/runtime.js:23:41)
      at __webpack_exec__ (load.1185632245.js:4:48)
      at load.1185632245.js:5:55
      at __webpack_require__.O (/var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/runtime.js:57:23)
      at load.1185632245.js:6:56
      at webpackJsonpCallback (/var/folders/82/f5564_g57qdcc42m46pz5_yr0000gp/T/_karma_webpack_633714/runtime.js:116:39)
      at load.1185632245.js:2:121

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':project:wasmJsBrowserTest'.
> command '~/.gradle/nodejs/node-v22.0.0-darwin-arm64/bin/node' exited with errors (exit code: 1)
I do have a custom karma configuration, but it is working for js target
b
Could you please file an issue
1
a
Thanks ! KTOR-7577