Question Answer Plugin

実験の1つで大きな成功を収めました。

複数のエントリーがあり、いくつかのエントリーには追加のコメントが付いています。興味深いことに、アップボート自体はあまり使われていませんが、これは新しいアイデアであり、人々が慣れていないからかもしれません。

さて、予期していなかった問題の1つは、これほど多くの活動がある中で、タイムラインからリンクされている最後のコメント以外は、新しいコメントを見つけるのが簡単ではないことです。何か見落としていることはありますか?例えば、投稿を時系列で表示する隠された代替方法などですか?あるいは、何か考えやアドバイスはありますか?

「いいね!」 1

特定のカテゴリで少なくとも1つのアップボートを獲得した回答を少なくとも1つ提出した人にバッジを付与するSQLクエリを作成しようとした人はいますか?この素晴らしいプラグインを中心に、シルバーやゴールドのバッジを作成するために、より多くの回答や/またはより多くのアップボートを持つクエリの例が非常に役立ちます。 :slight_smile:

「いいね!」 1

私と同じように、しっかりとした基盤があり、オープンソースで、活発で活気のあるコミュニティを持つStack OverflowのようなQ&Aサイトを探していました。Discourseは、そのプラグインのおかげで(ほぼ)自然な選択肢だと思われます。

そして、別のスレッドであなたのプラグインについての言及を見つけました。上の投稿を読むと、これは非常に有望に見えます。このプラグインがどのように機能し、どのように感じられるかを感じ取るために、このプラグイン(そしてできればそれ以外のものはあまり多くない)を最新またはほぼ最新のDiscourseで使用しているサイトはありますか?

アンガス様

このプラグインを「廃止」して #plugin:broken-plugin に移動するか、このまま長期的に維持したいか、検討する必要があります。

公式のQ&Aプラグイン(このプラグインに大きく触発されています)がベータ版の準備ができました。そのため、このプラグインをどうするか決める必要があります。

「いいね!」 3

これを廃止します。新しいものがリリースされたら、これを #plugin:broken-plugin に移動し、新しいものへの誘導通知を置くことができます。リポジトリのREADMEも更新します。

移行スクリプトが必要な場合は、喜んで作成しますが、このプラグインの既存ユーザーの間で必要とされている場合に限ります(もしあなたがそうであれば、お知らせください)。

「いいね!」 5

Angusさん、

公式Discourse Question Answerプラグインの新しいトピックを公開しました。

「いいね!」 4

I have a customer that is going to need it.

Seemed to be interested. No. I think they just mean an existing normal topic. I’m a bit surprised that this isn’t solved, or perhaps all I need to do is to install Discourse Upvotes and it’ll just work?

I don’t see any rake tasks in the new plugin, and glancing at the migrations it doesn’t appear that there is any magic there, though I could be wrong on one or both counts.

EDIT: OOps. It does look like the first migration handles moving stuff to the new plugin right here. . . I’m running the upgrade now and will delete this when it works.

EDIT 2: Sigh. It didn’t work. It’s failing with "PG::InvalidParameterValue: ERROR: cannot extract elements from a scalar",

Here’s the problem. A bunch of the post_custom_fields look like this:

  "\"[\\\"[{\\\\\\\"direction\\\\\\\":\\\\\\\"up\\\\\\\",\\\\\\\"action\\\\\\\":\\\\\\\"create\\\\\\\",\\\\\\\"user_id\\\\\\\":51,\\\\\\\"created_at\\\\\\\":\\\\\\\"2018-11-02T14:21:49.785+00:00\\\\\\\"}]\\\",{\\\"direction\\\":\\\"up\\\",\\\"action\\\":\\\"create\\\",\\\"user_id\\\":61,\\\"created_at\\\":\\\"2018-11-15T18:49:43.875+00:00\\\"}]\"",

rather than, maybe, this

 "[{\"direction\":\"up\",\"action\":\"create\",\"user_id\":6,\"created_at\":\"2018-07-18T16:37:42.446+00:00\"}]",

Some are worse:

 "\"[\\\"[\\\\\\\"[\\\\\\\\\\\\\\\"[\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"[\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"[\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"[{\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
\\\\\\\\\\\\\\\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\\\\\\\\\\\\\\\\\\\\\\"created_at\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"2018-11-15T18:41:44.680+00:00\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"}]\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\",{\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"direction\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"up\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"action\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"create\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"user_id\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\":21,\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"created_at\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"2018-11-15T18:41:52.440+00:00\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\"}]\\\\\\\\\\\\\\\",{\\\\\\\\\\\\\\\"direction\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\"up\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"action\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\"destroy\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"user_id\\\\\\\\\\\\\\\":21,\\\\\\\\\\\\\\\"created_at\\\\\\\\\\\\\\\":\\\\\\\\\\\\\\\"2018-11-15T18:41:56.158+00:00\\\\\\\\\\\\\\\"}]\\\\\\\",{\\\\\\\"direction\\\\\\\":\\\\\\\"up\\\\\\\",\\\\\\\"action\\\\\\\":\\\\\\\"create\\\\\\\",\\\\\\\"user_id\\\\\\\":3,\\\\\\\"created_at\\\\\\\":\\\\\\\"2019-05-17T17:21:51.066+00:00\\\\\\\"}]\\\",{\\\"direction\\\":\\\"up\\\",\\\"action\\\":\\\"create\\\",\\\"user_id\\\":43,\\\"created_at\\\":\\\"2019-06-01T14:10:48.056+00:00\\\"}]\"",

So I guess I’d need to recursively try to un-quote these a bunch of times until it got back to the right way? I guess I’ll see if I can google the Ruby un-quotify function. . . .

It looks like a real mess:

[24] pry(main)> too.value.gsub(/\\+/,"\\").undump
=> "[\"[\"[\"[\"[\"[\"[{\"direction\":\"up\",\"action\":\"create\",\"user_id\":161,\"created_at\":\"2018-11-14T01:41:18.071+00:00\"}]\",{\"direction\":\"up\",\"action\":\"create\",\"user_id\":21,\"created_at\":\"2018-11-15T18:41:37.215+00:00\"}]\",{\"direction\":\"up\",\"action\":\"destroy\",\"user_id\":21,\"created_at\":\"2018-11-15T18:41:44.680+00:00\"}]\",{\"direction\":\"up\",\"action\":\"create\",\"user_id\":21,\"created_at\":\"2018-11-15T18:41:52.440+00:00\"}]\",{\"direction\":\"up\",\"action\":\"destroy\",\"user_id\":21,\"created_at\":\"2018-11-15T18:41:56.158+00:00\"}]\",{\"direction\":\"up\",\"action\":\"create\",\"user_id\":3,\"created_at\":\"2019-05-17T17:21:51.066+00:00\"}]\",{\"direction\":\"up\",\"action\":\"create\",\"user_id\":43,\"created_at\":\"2019-06-01T14:10:48.056+00:00\"}]"
[25] pry(main)> one.value.gsub(/\\+/,"\\").undump
=> "[\"[{\"direction\":\"up\",\"action\":\"create\",\"user_id\":134,\"created_at\":\"2019-02-11T19:33:22.533+00:00\"}]\",{\"direction\":\"up\",\"action\":\"create\",\"user_id\":213,\"created_at\":\"2019-02-28T15:12:07.776+00:00\"}]"

I can do

SELECT
    post_id,
    jsonb_array_elements(value::jsonb) AS value                                   
  FROM post_custom_fields WHERE name = 'vote_history'
 and value not like '\"[%';
discourse=>   SELECT
    post_id,
    jsonb_array_elements(value::jsonb) AS value
  FROM post_custom_fields WHERE name = 'vote_history'
 and value not like '\"[%';

and get ~200 of ~250 entries, leaving a few that still look something like

    1865 | "[\"[\\\"[{\\\\\\\"direction\\\\\\\":\\\\\\\"up\\\\\\\",\\\\\\\"action\\\\\\\":\\\\\\\"create\\\\\\\",\\\\\\\"user_id\\\\\\\":161,\\\\\\\"created_at\\\\\\\":\\\\\\\"2019-06-28T15:39:44.438+00:00\\\\\\\"}]\\\",{\\\"direction\\\":\\\"up\\\",\\\"action\\\":\\\"create\\\",\\\"user_id\\\":39,\\\"created_at\\\":\\\"2019-07-03T19:29:04.663+00:00\\\"}]\",{\"direction\":\"up\",\"action\":\"create\",\"user_id\":298,\"created_at\":\"2019-07-11T13:51:52.447+00:00\"}]"
「いいね!」 1

マルチエスケープされたJSONがどのように生成されたのか分かりませんが、アップグレードを試みる前のバックアップに戻り、エスケープの問題をターゲットを絞って修正してから、標準の移行を再度使用することをお勧めします。

「いいね!」 1

これらの問題は何年も前から続いているため、バックアップは良い解決策ではありません。良いニュースは、最近あまり使用されていないようです(今年3回くらい?)、だからおそらく単に削除できるということです。

ありがとうございます。

潜在的に混乱する可能性のある唯一のことは、私が目にするドキュメントからは、新しいアップボートプラグインに切り替えるだけで「うまくいく」ことが明確ではないことです(うまくいかない場合でも、どちらのプラグインの最新バージョンにも問題がないように見えますが)。

「いいね!」 1

他のトピックで述べたように、基本的にUpvotesプラグインのマイグレーションで問題が発生しています。最終的な解決策は、このマイグレーションがDiscourseカスタムフィールドで大規模に使用される場合に発生する可能性のあるエッジケースを処理することです。

Data Explorerでトピックの合計アップボート/ダウンボート数をカウントしようとしています。Data Explorerに入力するアップボート/ダウンボートのデータ識別子を見つけた人はいますか?

このプラグインは、前回のDiscourseアップデート以降、壊れています。トピック内のメッセージ一覧を壊すJavaScriptエラーが発生しています。

「いいね!」 1

レポートありがとうございます。:+1: タグを交換します。

「いいね!」 1

素晴らしい、このプラグインを作成していただきありがとうございます。情報が表示され、メンバーが評価できる新しいプロジェクトにまさに求めていたものです。

このプラグインは broken とタグ付けされているため、Discourse Post Voting の使用をお勧めします。

「いいね!」 2

そのプラグインは「まだ活発に開発されており、頻繁に変更される可能性があります」。これは、Googleの有名なミームを思い出させます。

「いいね!」 1