TypeError: Cannot read properties of undefined (reading 'varType') #621
Replies: 1 comment
-
Hi @LSarribouette, sorry for the trouble. In general the compiler will normally include details in the error message when there is an issue with a specific variable, but in this case unfortunately there is not. This looks to be a case where an error isn't expected, and I'm not sure yet what's causing it. Is your model (or some subset of it that might be triggering the issue) open source by any chance? If I had access to the mdl files, that would be the easiest way for me to diagnose, but I totally understand if you're not able to share your model openly (or even privately). If not, the next thing to try would be to add some logging to the compiler to help debug. Unfortunately where it's failing is earlier than some existing logging code, so we can't rely on that existing code. I made a temporary build to help you diagnose (see this branch diff for the code change). To use it, change your diff --git a/package.json b/package.json
index b87e16a..e18a269 100644
--- a/package.json
+++ b/package.json
@@ -12,10 +12,13 @@
"packages/core",
"packages/app"
],
+ "overrides": {
+ "@sdeverywhere/compile": "climateinteractive/gitpkg-registry-public#sde-compile-599895f"
+ },
"dependencies": {
"@sdeverywhere/build": "^0.3.4",
"@sdeverywhere/check-core": "^0.1.2",
- "@sdeverywhere/cli": "^0.7.23",
+ "@sdeverywhere/cli": "climateinteractive/gitpkg-registry-public#sde-cli-599895f",
"@sdeverywhere/plugin-check": "^0.3.5",
"@sdeverywhere/plugin-config": "^0.2.4",
"@sdeverywhere/plugin-vite": "^0.1.8", If you Or, if you don't mind going deeper and making changes to the compiler to see what else is going wrong, you can clone the SDEverywhere repo and change your diff --git a/package.json b/package.json
index b87e16a..46ef32a 100644
--- a/package.json
+++ b/package.json
@@ -12,10 +12,13 @@
"packages/core",
"packages/app"
],
+ "overrides": {
+ "@sdeverywhere/compile": "file:../../SDEverywhere/packages/compile"
+ },
"dependencies": {
"@sdeverywhere/build": "^0.3.4",
"@sdeverywhere/check-core": "^0.1.2",
- "@sdeverywhere/cli": "^0.7.23",
+ "@sdeverywhere/cli": "file:../../SDEverywhere/packages/cli",
"@sdeverywhere/plugin-check": "^0.3.5",
"@sdeverywhere/plugin-config": "^0.2.4",
"@sdeverywhere/plugin-vite": "^0.1.8", |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
We are progressively compiling more and more complex models until having our complete model running, dealing with the errors one at a time. It seems all our XLSX calls work now and we now have a TypeError.
We get this error both when we run
npm create @sdeverywhere
(but we kept going since we got the message 'The mdl file failed to load (...) diagnose the issue later.') and thennpm run dev
.What do you think? Do you have a simple way to find which variable is causing trouble?
Here is the full error:
Beta Was this translation helpful? Give feedback.
All reactions