Page MenuHomePhabricator

Restore missing ledes for Techblog posts imported to Diff
Closed, ResolvedPublic

Assigned To
Authored By
Krinkle
Jun 12 2026, 4:14 AM
Project Tags
Referenced Files
F88206423: excerptable.tsv
Jun 12 2026, 10:14 PM
F88205015: Screenshot 2026-06-12 at 5.00.17 PM.png
Jun 12 2026, 10:14 PM
F88074956: Screenshot 2026-06-12 at 05.12.56.png
Jun 12 2026, 4:14 AM
F88074957: Screenshot 2026-06-12 at 05.12.44.png
Jun 12 2026, 4:14 AM
F88074244: Screenshot 2026-06-12 at 05.06.57.png
Jun 12 2026, 4:14 AM
F88074051: Screenshot 2026-06-12 at 05.04.54.png
Jun 12 2026, 4:14 AM
F88074050: Screenshot 2026-06-12 at 05.05.06.png
Jun 12 2026, 4:14 AM

Description

This is essentially the inverse of T322476: Techblog: Lead paragraph missing in feed readers.

By default in WordPress, including on the Diff, the "excerpt" is something shown only on the homepage and maybe in a few other listings but never when the article itself is shown in full.

The Techblog, however, did something usual through its "Modern" theme, which is to repurpose this as the lead paragraph. Because the theme forced this, and because editors want to avoid a jarring repetition between the lede and first regular paragraph, it got used as what it looked like: The lede paragraph.

Example: https://web.archive.org/web/20250910050035/https://techblog.wikimedia.org/2023/02/24/from-hell-to-html/

Techblog homeTechblog post
Screenshot 2026-06-12 at 05.05.06.png (850×1,076 px, 157 KB)Screenshot 2026-06-12 at 05.04.54.png (1,406×1,342 px, 338 KB)

For articles that had such a lede, they now begin with their second paragraph. The lede is gone.

https://diff.wikimedia.org/2023/02/24/from-hell-to-html/

Screenshot 2026-06-12 at 05.06.57.png (1,512×1,378 px, 381 KB)

Now, because I anticipated this issue, and as workaround for the T322476 bug, this doesn't affect articles I wrote. What I did for the past couple years, whenver publishing an article, copied the lede into the body content as first paragraph and used CSS to hide the duplicate except rendered by the Techblog/Modern theme. As a result, that lede wasn't missing in feed readers, and is now preserved in the Diff:

https://web.archive.org/web/20260410232928/https://techblog.wikimedia.org/2023/05/08/around-the-world-how-wikipedia-became-a-multi-datacenter-deployment/
https://diff.wikimedia.org/2023/05/08/around-the-world-how-wikipedia-became-a-multi-datacenter-deployment/

TechblogDiff
Screenshot 2026-06-12 at 05.12.44.png (1,290×958 px, 282 KB)
Screenshot 2026-06-12 at 05.12.56.png (1,460×1,036 px, 359 KB)

Succes! But, I do realize this may complicate a bulk action. I'd be happy to fix these up myself, so feel free to bulk action on any Techblog-imported posts on Diff, and simply take any custom excerpt and prepend it as opening paragraph to the content.

Event Timeline

What I did for the past couple years, whenver publishing an article, copied the lede into the body content as first paragraph and used CSS to hide the duplicate except rendered by the Techblog/Modern theme.

Sneaky! :)

Screenshot 2026-06-12 at 5.00.17 PM.png (1,400×1,020 px, 314 KB)

Looking at the post on Diff, the excerpt is there, which is good. But as you note, is not shown in our theme. On Diff we've used the excerpt feature almost exclusively for posts that are featured (sticky in WordPress parlance) on the home page to provide a, well, excerpt of what's in the post.

I ran a query against all the imported tech blog posts to get a list of those that have an excerpt. This includes their IDs, so you can access them via diff.wikimedia.org/?p=12345

@Krinkle I've (temporarily) made you an "Editor" on Diff. This should allow you to edit the published posts to fix this issue.

Thanks. All done now.

  • Copied excert into a new paragraph with medium font-size, similar to how it was on Techblog.
  • Cases where it was there already (i.e. mine) I left as-is, and removed my CSS hack.
  • Cases where the excerpt was a near-enough duplicate of the first paragraph, I left as-is, instead of prepending the excerpt again. (This was more common on some older posts. I suspect the lede feature was not enabled yet or not realized yet.)
  • I noticed that posts by Gilles no longer had his first/last name but were attributed to gdubuc. There was already an author for Gilles Dubuc so I re-assigned these accordingly.

For two posts, I noticed that their URL differed from the original Techblog post, because the slug was already occupied on Diff, and so the import added a -2 suffix. This means that, given the Techblog redirect is a domain-redirect (and not a post-redirect), the old posts actually redirect to the pre-existing post rather than to the imported ones.

This isn't a big deal because the posts are essentially identical anyway. These were either cross-posted or imported from the same common source. I've improved the formatting/tags of the original entries, and un-published the duplicates. Feel free to delete these. Or, if you see a use for them, feel free to publish them again.

CKoerner_WMF claimed this task.

Thanks @Krinkle. I appreciate you also cleaning up the other issues you discovered along the way. I neglected to let other Diff editors know about this work on Friday and so they saw these edits as new submissions. Confusion ensued, of my own doing! Thankfully all resolved now. You may have seen a few editorial comments related to these two posts. Those can be safely ignored.