docs: rewrite the author-facing copy in plain language
The copy was written for someone who had read the spec. It named UTF-8, RFC 3339, canonical form, code points and frontmatter fields, and the one place it gave instructions it gave them as fumi command lines, which say nothing to anyone using carrier or gsmol. Now it uses the words the clients put on screen: "header", with the "+ header" button both of them have, and "Requests folder", which is what both call it. One word per idea throughout — post, feed, header, Requests folder — and reasons are whole sentences that say what happened and what to do, so the reply no longer opens "Reason:" followed by a lowercase fragment. The first-contact mail is the one a stranger reads before anything else, so it now covers accepting this address: a recommendation, not the mechanism behind it. The mechanism would also have aged badly, since a client that delivers its token once makes accepting cost a single refused post rather than all of them. A refused post gets a detail paragraph where one line cannot hold the fix. It tells the author their token arrived and to send again, and what to do if it is refused a second time, which is what happens on a client that attaches the token to everything. A first post on an empty feed says so differently: the author is watching their first attempt fail and needs to hear the feed is fine. Seven admin strings were built with format! and never reached the catalogue, so an ack opened its body in lowercase and could not be translated. They are entries now, and say what blocking does rather than naming the mechanism. The cap warning said "90% of its 1048576 byte limit". It says 1 MB. Four rig assertions matched the old wording and now match the new. They have to read rendered mail, so they stay coupled to it in a way the unit tests, which assert on Reason variants, do not.
This commit is contained in:
parent
9c9dce57e7
commit
72c353cb5a
5 changed files with 271 additions and 128 deletions
18
tests/rig.sh
18
tests/rig.sh
|
|
@ -144,7 +144,7 @@ for i in 1 2 3 4 5; do
|
|||
continue # different seconds; try again
|
||||
fi
|
||||
fumi fetch >/dev/null
|
||||
if fumi list --requests 2>/dev/null | grep -q "timestamp .* already exists"; then
|
||||
if fumi list --requests 2>/dev/null | grep -q "already has a post at"; then
|
||||
collided=1
|
||||
break
|
||||
fi
|
||||
|
|
@ -163,7 +163,7 @@ fumi send "$DAEMON_ADDR" --body "over the cap" >/dev/null
|
|||
sleep 3
|
||||
grep -q "over the cap" "$FEED" && fail "a capped feed published a record"
|
||||
fumi fetch >/dev/null
|
||||
fumi list --requests 2>/dev/null | grep -q "feed is at its size cap" \
|
||||
fumi list --requests 2>/dev/null | grep -q "Your feed is full" \
|
||||
|| fail "no cap rejection reply"
|
||||
|
||||
step "retention: fifo mode"
|
||||
|
|
@ -173,7 +173,7 @@ fumi send "$DAEMON_ADDR" --body "fifo post" >/dev/null
|
|||
wait_for "$FEED" "fifo post"
|
||||
[[ "$(grep -cE '^[0-9]' "$FEED")" == 1 ]] || fail "fifo did not prune down to one record"
|
||||
fumi fetch >/dev/null
|
||||
fumi list --requests 2>/dev/null | grep -q "90% of its size cap" \
|
||||
fumi list --requests 2>/dev/null | grep -q "your feed is nearly full" \
|
||||
|| fail "no 90% warning reply"
|
||||
"$SMOLBOID" check "$FEED" >"$RIG/check.log" || { cat "$RIG/check.log"; fail "check"; }
|
||||
grep -q "1 verified, 0 unsigned, 0 invalid" "$RIG/check.log" \
|
||||
|
|
@ -289,9 +289,9 @@ done
|
|||
MAIL="$(dana_mail)"
|
||||
[[ "$MAIL" == *"accept token"* ]] \
|
||||
|| { echo "$MAIL"; fail "no explanation for the refused post"; }
|
||||
# The whole sentence must survive as a subject: a line break in a frontmatter
|
||||
# value makes the block malformed and strips the subject entirely.
|
||||
[[ "$MAIL" == *"withdraw the acceptance and resend"* ]] \
|
||||
# The whole sentence must survive as a subject: a line break in a mail header
|
||||
# makes the block malformed and strips the subject entirely.
|
||||
[[ "$MAIL" == *"your client attached"* ]] \
|
||||
|| { echo "$MAIL"; fail "the reason was truncated in the subject"; }
|
||||
dana block "$DAEMON_ADDR" >/dev/null
|
||||
|
||||
|
|
@ -319,11 +319,11 @@ sleep 4
|
|||
[[ ! -f "$DATA/feeds/erin.txt" ]] || fail "registration is closed but erin got a feed"
|
||||
for ((i = 0; i < 20; i++)); do
|
||||
erin fetch >/dev/null 2>&1 || true
|
||||
[[ "$(erin list --requests 2>/dev/null || true)" == *"registration is closed"* ]] && break
|
||||
[[ "$(erin list --requests 2>/dev/null || true)" == *"not taking new feeds"* ]] && break
|
||||
sleep 1
|
||||
done
|
||||
[[ "$(erin list --requests 2>/dev/null || true)" == *"registration is closed"* ]] \
|
||||
|| fail "erin was not told registration is closed"
|
||||
[[ "$(erin list --requests 2>/dev/null || true)" == *"not taking new feeds"* ]] \
|
||||
|| { erin list --requests || true; fail "erin was not told registration is closed"; }
|
||||
|
||||
step "rig passed"
|
||||
echo "feeds: $FEED"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue