Akismet is no longer showing the post content

AI-generated summary

A bug was reported where Akismet stopped displaying post content in the admin area when flagging spam, though clicking the Post ID still redirects to the post cpradio. Mittineague confirmed the workaround is better than the previous multi-step method. codinghorror acknowledged it as a legitimate issue needing assignment. vinothkannans identified the regression was caused by the add_excerpt parameter in PostSerializer and provided a fix via a commit. cpradio confirmed the fix works in the latest version.

Akismet when it catches a post is no longer showing the post content in the admin area. Clicking on the Post ID does take me to it though (as a workaround).

Reproduction steps

  1. Create a new user
  2. Copy the following as the title:
    BAMWAR BAMWAR bamwar BAMWAR BAMWAR
  3. Copy the following as the post content:
    BAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWARBAMWAR BAMWAR bamwar BAMWAR BAMWAR
9 Likes

Thanks, :+1: that’s better than the
avatar → profile → deleted → post
that I did a few hours ago.

3 Likes

I think this is a legit bug @sam and we should assign it.

1 Like

Looks like it regressed when we introduced add_excerpt param in PostSerializer. This commit fixes it:

https://github.com/discourse/discourse-akismet/commit/71f5193363c3ff171fb6df58573a9354469e23d0

8 Likes

Thank you! I re-tested it on latest and it works again.

6 Likes