In terms of post count, it feels correct. To display this number, we are using data from the /reviewable/334.json request. Data from /admin/users/29.json request is only used for IP lookup.
The difference between those two requests is that the first one is using User.user_stat.post_count, which counts only public posts (excluding posts in private categories and PMs). The second - admin - request is returning all the posts (including those in private categories and PMs).
In my case, 32 is displayed, even if the admin’s post count is 36.
No, the posts were all in categories, just like the one I used for flagging. The number of posts was always 0 when the join date is wrong.
(I did the re-test on my site that is still on Commits · discourse/discourse · GitHub. The repro on the weekend was a dev install because I wanted to ensure nothing had changed in the past 10 days)
Excuse the delay on this one, it was quite a tricky problem.
Apparently, the serializer was skipping the extra information needed for that tab when the flagger was also the target user — I swapped the order of created_by and target_created_by which forces the serialization of target_created_by first and properly fills in the insight tab.
It is now available in latest. Let me know if you get a chance to try it out