fix: unbreak the WordPress tab layout, decode mail subjects, drop du from page load - #92
Merged
Conversation
…` from page load
LAYOUT REGRESSION, mine, from the staging-card guard in the previous
release. The `{% endif %}` landed INSIDE the actions row instead of after
it, so when no staging site existed the opening `<div>` was skipped while
its `</div>` was still emitted. That closed an ancestor early and every
card below it — Plugins, Themes — reflowed into the wrong tab. Balanced
now: the guard wraps the whole row, both branches emit the same number of
tags.
MAIL SUBJECTS rendered raw:
`=?UTF-8?Q?[Ingratia.cz]_Web_byl_aktualizov=C3=A1n?=`. Mail headers are
ASCII-only on the wire, so any subject with an accent in it — which for a
Czech site is most of them — arrives RFC 2047 encoded. Added a decoder
for Q- and B-encoded words. Deliberately lenient: an unknown charset, an
unknown encoding or a truncated word comes back UNCHANGED rather than
mangled, because an ugly subject is still useful and one rewritten into
nonsense is not. Display-only; the raw header stays in the log file.
HOSTING DETAIL SPEED. The quota probe fell back to `du -sk` over the
site's entire tree, with no timeout, whenever the kernel probe returned 0
— which is every box without kernel quotas, i.e. the default. That ran on
EVERY hosting-detail page load, before anything rendered: on a 20 GB site
with a cold page cache, seconds to tens of seconds, for a figure that is
only enforced when quotas are actually on. The fallback is gone; the
caller substitutes the last sampled usage row instead. Five minutes stale
and instant beats exact and unusable, and `du` still runs — on the
sampler's schedule, where taking a while is fine.
Co-Authored-By: Claude Opus 4.8 <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.
1. Layout regression — mine, from v0.27.0
The staging-card existence guard I added last release put its
{% endif %}inside the actions row instead of after it. With no staging site the opening<div>was skipped while its</div>was still emitted — closing an ancestor early, so every card below (Plugins, Themes) reflowed into the wrong tab.Balanced now: the guard wraps the whole row, and both branches emit the same number of tags.
2. Mail subjects rendered raw
Mail headers are ASCII-only on the wire, so any subject containing an accent — for a Czech site, most of them — arrives RFC 2047 encoded. Added a decoder for Q- and B-encoded words.
Deliberately lenient: an unknown charset, an unknown encoding, or a truncated word comes back unchanged rather than mangled — an ugly subject is still useful, one rewritten into nonsense is not. Display-only; the raw header stays in the log file. Seven tests, including the exact string from the screenshot and four that must survive intact.
3. Hosting detail was slow —
duon every page loadThe quota probe fell back to
du -skover the site's entire tree, with no timeout, whenever the kernel probe returned 0 — which is every box without kernel quotas, i.e. the default. That ran on every hosting-detail load, before anything rendered: on a 20 GB site with a cold page cache, seconds to tens of seconds — for a figure that is only enforced when quotas are actually on.The fallback is gone. The caller substitutes the last sampled usage row instead: five minutes stale and instant beats exact and unusable.
dustill runs — on the sampler's schedule, where taking a while is fine.Tests
cargo test --workspacegreen,cargo fmt --allclean.🤖 Generated with Claude Code