delph-in / delphin-viz

JavaScript visualizations of various DELPH-IN structures.
http://delph-in.github.io/delphin-viz/demo/
MIT License
15 stars 4 forks source link

mrsData.variables[varName] is undefined #6

Open goodmami opened 6 years ago

goodmami commented 6 years ago

The following error occurs when parsing "Adi tahu bahwa hujan sudah turun." with INDRA:

mrsData.variables[varName] is undefined

This appears to be because every EP has an argument CARDIN bool, which seems to be a bug in the grammar (at least, the MRS is ill-formed), and bool is not a valid variable name.

The problem is that this error causes the DMRS to fail to be displayed, although it does display if the MRS box is unchecked (it appears to just ignore the rogue roles). The MRS layout function could be a bit more robust for bad inputs like this.

goodmami commented 6 years ago

Note, the issue no longer shows up since I updated INDRA because the grammar bug was fixed, but the problem occurred around here:

https://github.com/delph-in/delphin-viz/blob/1d48c200755e9141530bbd33aeb0f234f4f39cab/viz/mrs.js#L329-L335