cyberland cow
cyberland cow
LTLeaning Technologies
Created by cyberland cow on 12/15/2023 in #support
r[((0 + c) | 0)] is not a function when instantiating object
Hello, thank you all for developing CheerpJ, it is an impressive tool! I am playing around with trying to run hail, a scientific computing stack based on the JVM, in the browser using CheerpJ as I would love to eventually develop in-browser runnable documentation. I am able to load my JAR successfully, run some static methods on classes of mine and even instantiate some simple classes/case classes (this is a Scala project), but I'm running into the following error when trying to instantiate one of my core classes:
a.message: r[((0 + c) | 0)] is not a function
a.stacktrace: "TypeError: r[((0 + c) | 0)] is not a function\n at Object.u4 [as a0] (https://cjrtnc.leaningtech.com/3.0rc2/cj3.js:1:10866)\n at PG (https://cjrtnc.leaningtech.com/3.0rc2/cj3.js:1:67131)\n at MessagePort.Uo (https://cjrtnc.leaningtech.com/3.0rc2/cj3.js:1:20680)"
a.message: r[((0 + c) | 0)] is not a function
a.stacktrace: "TypeError: r[((0 + c) | 0)] is not a function\n at Object.u4 [as a0] (https://cjrtnc.leaningtech.com/3.0rc2/cj3.js:1:10866)\n at PG (https://cjrtnc.leaningtech.com/3.0rc2/cj3.js:1:67131)\n at MessagePort.Uo (https://cjrtnc.leaningtech.com/3.0rc2/cj3.js:1:20680)"
This class has a lot of dependencies, including some objects that do filesystem access that I would expect not to work in the browser, but this error is happening during object construction where it's just setting a couple String fields. The project is fully open source so I can provide a branch and steps to reproduce this error but I was hoping first to distill it into a more minimal example. Unfortately, I'm quite stuck as to what might be the problem here. Does this error mean anything to anyone / could I get some pointers as to how to further debug the error? Thank you in advance!
17 replies