Could someone help me make sense of this error that I’m seeing in my logs?
Discourse.Dialect is undefined
The discussion is about resolving the Discourse.Dialect is undefined error. tophee is seeking help to fix this issue in their logs. sam suggests that the error is caused by ancient code and recommends upgrading all plugins, and if the issue persists, removing plugins one by one to identify the culprit.
tophee suspects that the Abbreviations and Acronyms plugin, which has not been updated in months, might be the cause. sam confirms that the plugin is broken and needs to be removed.
The conversation then shifts to the topic of whether disabled plugins can still cause errors. david explains that plugins’ JavaScript and Ruby code are still loaded even when disabled, and it’s up to the plugin authors to respect the “disabled” setting. tophee suggests that it’s possible for plugins to be programmed to have no effect when disabled, but cpradio and david disagree, citing potential issues with library references and broken imports.
sam proposes two potential solutions to achieve easy and robust disabling of plugins: allowing the core to issue a “restart” to services and splitting plugins into separate JavaScript files.
tophee later reveals that removing the Abbreviations and Acronyms plugin did not resolve the issue. joebuhlig suggests that the Affiliate plugin might be the cause, as updating it solved the same error for them. However, tophee reports that they are still experiencing the error despite updating the Affiliate plugin and rebuilding their app.
Could someone help me make sense of this error that I’m seeing in my logs?
Discourse.Dialect is undefined
Yeah it is ancient code we removed, upgrade all plugins, if it persists, remove one by one till it’s gone and report back with the culprit
Is it possible that a plugin is causing this error even when it is disabled (i.e. it’s still in the app. yml but not activated in site settings)? If so, everything seems to point to the abbreviations and acronyms plugin:
The author has not been seen since months and is not responding to various bug reports. Maybe the plugin should be tagged as broken?
Yes absolutely will mark it now
Plugin needs to be removed and app rebuilt
So is this true for plugins in general: they can cause errors even when deactivated?
Yes, it is up to plugins to respect the “disabled” setting in their own programming - their javascript and ruby code is still loaded regardless. Some somewhat relavent discussion:
Okay, I read that as: it depends how the plugin is programmed, so that it is possible to program it so that it has no effect whatsoever when it is disabled. I think that is a valuable design specification for anyone sponsoring or buying a plugin: make it so that it can be fully disabled. (Can spare some headaches for many people.)
I’m not 100% sure that is true. Because some items get loaded automagically and just referencing a library that no longer exists will cause it to break, and that is before your setting check can even be invoked.
There are “ways” around that though, but to say it can be 100% disabled and not cause an issue, I think is bordering on impracticality.
Yeah, ideally that would be the case. Sadly it’s not entirely realistic, especially for things like broken imports.
(e.g. when discourse/lib/ajax was moved last year)
Edit: @cpradio beat me to it
Yeah if we wanted easy peasy 100% robust disable
(1) is surprisingly difficult.
To be fair, removing the acronyms and abbreviation did not stop those errors from occurring. So this plugin was either not causing any of them or it was not the only one doing so. Next try will be the affiliate plugin.
I can confirm that the affiliate plugin causes this error when core is upgraded but not the plugin. I dealt with this exact error earlier today. Updating the affiliate plugin solved it.
Hm, I did a complete rebuild so everything is up to date, but I’m still seeing this error
TypeError: Cannot read property 'addPreProcessor' of undefined
So if you’re saying that you are errorless with the plugin, I guess I’ll have to look elsewhere.
Edit: I just realized that this is a different error than the one I originally posted ![]()