sidekiq 中报告的 UserNotificationRenderer 问题

你好

我是这个论坛的新手。
我们在一周前将一个生产环境的 phpBB 论坛迁移到了 Discourse。

不得不说,Discourse 非常棒……一切都很顺利。

只有一个小小的问题让我有些担心。

Sidekiq 报告了以下错误:

Jobs::UserEmail 	
{"type"=>"user_private_message", "user_id"=>xxxx, "notification_id"=>yyyyy, "notification_data_hash"=>{"topic_title"=>"aaaa", "original_post_id"=>zzzz, "original_post_type"=>1, "original_username"=>"uuuu", "revision_number"=>nil, "display_username"=>"uuuu"}, "notification_type"=>"private_message", "post_id"=>pppp, "current_site_id"=>"default"}
	
Jobs::HandledExceptionWrapper: Wrapped NoMethodError: **undefined method `with_view_paths'** for UserNotifications::UserNotificationRenderer:Class Did you mean? with_options

除了这个链接外,我没有找到任何关于 UserNotificationRenderer 的建议:
https://review.discourse.org/t/dev-add-support-for-rails-6/3186

受影响的文件是:
app/mailers/user_notifications.rb

在我看来,通知或消息似乎没有发送出去……
请问有人知道如何修复这个问题吗?

补充信息:我们使用的是 v2.4.0.beta2 + 183 版本,基于 Docker 容器部署……

非常感谢。

Stephane

您是否使用了任何非标准插件?

我不这么认为。全部来自 Discourse。
这是我们使用的:

discourse-email-all
discourse-events
discourse-sidebar-categories
discourse-sitemap
docker_manager

我也遇到了同样的错误,但已经成功解决:

  1. 我将 Ubuntu 升级到了最新版本(但错误仍然存在)。
  2. 我重新构建了应用(sudo ./launcher rebuild app),问题得以解决。我目前运行的是最新版本,否则我可能会先尝试升级而不是重新构建。

非常感谢,我们会尝试一下。
我们运行的是 Ubuntu 18.04。
关于 Discourse,你们现在的版本是多少?

好的,重建后看起来没问题了。非常感谢你的提示。