DTStack / monaco-sql-languages

SQL languages for monaco-editor

Home Page:https://dtstack.github.io/monaco-sql-languages/

Repository from Github https://github.comDTStack/monaco-sql-languagesRepository from Github https://github.comDTStack/monaco-sql-languages

cannot read properties of undefined

Samrose-Ahmed opened this issue · comments

I'm getting this error trying to use with trinosql:

TypeError: Cannot read properties of undefined (reading 'get')
    at _CodeCompletionCore.collectCandidates (http://localhost:3000/trinosql.worker.js:68773:33)
    at TrinoSQL.getSuggestionAtCaretPosition (http://localhost:3000/trinosql.worker.js:50222:29)
    at TrinoSQLWorker.<anonymous> (http://localhost:3000/trinosql.worker.js:63071:41)
    at Generator.next (<anonymous>)
    at http://localhost:3000/trinosql.worker.js:63030:67
    at new Promise (<anonymous>)
    at __awaiter (http://localhost:3000/trinosql.worker.js:63012:10)
    at TrinoSQLWorker.doComplete (http://localhost:3000/trinosql.worker.js:63068:12)
    at EditorSimpleWorker.fmr (http://localhost:3000/trinosql.worker.js:61720:58)
    at SimpleWorkerServer._handleMessage (http://localhost:3000/trinosql.worker.js:58454:59)

Please provide the SQL content and the version you have installed, so that we can fix the problem more quickly.

This is on the latest version and happens with any content from single character to full sql string

I tried changing to a few versions earlier and the issue is there as well

This problem should be caused by the version update of antlr4-c3. See this issue . If the version of antlr4-c3 in the node_modules is above 3.2.x, you can confirm that this issue is causing it. We will release a new version as soon as possible to fix this issue.

Thanks much for the update. I can confirm the antlr4-c3 version is 3.3.4. I will try overriding it now.

can confirm it works by downgrading to 3.1.1

@Samrose-Ahmed
Sorry for the trouble!
Now the new version v0.12.0-beta.6 has been released. If you confirm that your issue has been resolved, please close this issue, or we will close it in a week.

I can confirm issue is resolved thanks.