Stop flagging a blank seo_title when the article title covers it - #196
Merged
Conversation
The SEO audit read the seo_title column directly and warned whenever it was empty. But a blank seo_title is not a defect: the public site renders the article title in its place (Scalene ArticleLayout.astro), and the editor's preview does the same. The page ships a correct <title> either way, so the warning fired on articles whose output was already fine -- essentially the entire legacy WordPress import, which never had the column populated. At ~1,900 issues it buried the error-level findings that do reflect broken output. Resolve the effective title the way the renderer does, then audit that. A blank seo_title with a usable title is no longer reported, and the 60-character check now runs against the fallback, catching over-long headlines that get truncated in search results but were previously silent. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The SEO audit warned "Missing SEO title" whenever the
seo_titlecolumn was empty. But blank is the normal, working state: the public site renders the article title in its place (ScaleneArticleLayout.astro:63), and the editor previews the same fallback — its input placeholder even says "Defaults to the article title." Nothing ever persists that default, so the column stays empty and the page still ships a correct<title>.The result was a warning firing on articles whose output was already fine — essentially the whole legacy WordPress import. At ~1,900 total issues it buried the
error-level findings (missing meta description, missing featured image) that do reflect broken output.Change
Resolve the effective title the way the renderer does, then audit that:
seo_title+ a usable article title → no longer reported.<title>.Testing
TestAuditArticleFallsBackToTitleForSEOTitlecovers all three branches. Package tests andgo vetpass.Notes
The 49-error count on the dashboard won't move — this only touched a
warning. What drops is the 1,932 total. I haven't measured the new number against prod; happy to run that count if it's worth knowing before merge.🤖 Generated with Claude Code