これが完全にバグなのか、単に私が理解できていない挙動なのかは確信が持てませんが、投稿内で誰かを引用すると、その時点でのその人のアバターが引用と一緒に保存されているようです。例えばこちら:
これはおそらく、以下の問題の回帰(再発)ではないでしょうか:
https://meta.discourse.org/t/after-changing-avatar-quotes-still-show-the-old-avatar/21122
これが完全にバグなのか、単に私が理解できていない挙動なのかは確信が持てませんが、投稿内で誰かを引用すると、その時点でのその人のアバターが引用と一緒に保存されているようです。例えばこちら:
これはおそらく、以下の問題の回帰(再発)ではないでしょうか:
https://meta.discourse.org/t/after-changing-avatar-quotes-still-show-the-old-avatar/21122
Not a bug; it’s always been that way.
I suppose its because the posts are baked with the URL at the time. Do you want a fix for this, or is it too potentially resource intensive to trigger a rebake each time someone changes their avatar?
Changing the avatar already triggers a rebake of posts containing quotes, but it’s currently quite resource intensive to find and rebake all posts. So, it’s possible that some of them won’t be updated. Post revisions aren’t updated at all.
I have plans to fix all of this when I’m working on improvements for user renaming/anonymizing in one of the next releases. It will require a new table that keeps track of all the places where a user is quoted, mentioned, oneboxed, and what not.
If you want to work on this, please keep in mind that rebaking just to update the avatar isn’t needed. I’d suggest reusing code from UpdatUsername. It’s a lot faster.
これは after_save の後に発生しますが、will_save_change を使用するため、実際にはトリガーされないと確信しています。以前はそうだったようですが、2017年のこのコミット で(誤って、と仮定しますが)_changed から will_save_change に変更されました。
これには、いくつかの#バグトピックもあると思います。
この問題の根本原因を特定してくれた @dsims さん、ありがとうございます!修正のためのプルリクエストを作成しました。
このトピックは4日後に自動的に閉じられました。新しい返信は許可されていません。