Preparation for reworking the refine action
Here are some more preparatory commits for #1472. These are things I spotted while working on reworking the refine
action. The commits are not particularly related and should be reviewed separately.
Helps: #1472 Closes: #1324 (closed)