Skip to content

Commit db6e407

Browse files
authored
fix: restore the Marketplace listing; guard action.yml metadata (#196)
* fix: restore the Marketplace listing; guard action.yml metadata v1.7.2 delisted the Action from the GitHub Marketplace. To document the runner requirement I had grown action.yml's `description` to 133 characters; the Marketplace caps it at 125. GitHub validates that metadata only when publishing a release to the Marketplace, in the release UI. Nothing else looks at it — not treefmt, the test suite, zola check, nor the release guards — so the change merged green, released green, and the only symptom was github.com/marketplace/actions/policypress returning 404 and vanishing from Marketplace search. The release UI reports it as "Your action.yml needs changes before it can be published / Description must be less than 125 characters". The description returns to its previous 110-character wording. The runner requirement loses nothing: it is already in the README (which is the listing body), the installation guide, and the action's own fail-fast guard, none of which are length-capped. A comment above `name` now records why the detail must not migrate back into `description`. Adds an `action-metadata` flake check, so this class of break cannot merge again. It validates description length, a present name free of "GitHub", and branding icon/colour against GitHub's accepted set. It is verified against the real 1.7.2 action.yml, which it rejects with the character count, and against the fixed file, which it accepts. Note the listing cannot be restored by editing v1.7.2: a published release is immutable, so the fix has to ride a new release. * chore: release 1.7.3
1 parent 0c820bc commit db6e407

6 files changed

Lines changed: 133 additions & 3 deletions

File tree

CHANGELOG.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,35 @@ versioning; breaking changes to it bump the major version.
88

99
## [Unreleased]
1010

11+
## [1.7.3] - 2026-07-31
12+
13+
### Fixed
14+
15+
- **The GitHub Marketplace listing is restored.** v1.7.2 delisted the Action:
16+
1.7.2 had grown `action.yml`'s `description` to 133 characters to mention the
17+
runner requirement, and the Marketplace caps it at 125. GitHub validates that
18+
metadata *only* when publishing a release to the Marketplace, so the change
19+
merged green, released green, and the sole symptom was
20+
`github.com/marketplace/actions/policypress` returning 404 with the listing
21+
gone from search. The description is back to its previous 110-character
22+
wording; the runner requirement stays in the README (which is the listing
23+
body), the installation guide, and the Action's own fail-fast guard, none of
24+
which are length-capped.
25+
26+
Restoring the live listing needs a *release* carrying the fix — a published
27+
release is immutable, so v1.7.2 can never be published to the Marketplace.
28+
29+
### Added
30+
31+
- **`action-metadata` check** (`nix run` via `nix flake check`, or
32+
`bash tools/check-action-metadata.sh`) validates action.yml against the
33+
Marketplace's publish rules on every PR: `description` under 125 characters,
34+
`name` present and free of "GitHub", and `branding.icon`/`branding.color`
35+
present with an accepted colour. Nothing previously inspected this metadata —
36+
not the formatter, the test suite, `zola check`, or the release guards — which
37+
is why a listing-breaking value shipped. The check is verified against the
38+
actual 1.7.2 `action.yml`, which it rejects with the character count.
39+
1140
## [1.7.2] - 2026-07-31
1241

1342
### Fixed

action.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
11
# Requires a Linux or macOS runner (`runs-on: ubuntu-latest` is recommended).
22
# Windows runners are not supported: the action builds on Nix, which has no
33
# Windows support, and release binaries are published for Linux and macOS only.
4+
# That requirement is documented in the README (which is the Marketplace listing
5+
# body), the installation guide, and the action's own fail-fast guard below —
6+
# deliberately NOT in `description`, which GitHub caps at 125 characters and
7+
# validates only when publishing a release to the Marketplace.
48
name: PolicyPress
5-
description: Compliance policy management on Linux/macOS runners - write policies in Markdown, publish a branded policy site and audit-ready PDFs.
9+
description: Compliance policy management - write policies in Markdown, publish a branded policy site and audit-ready PDFs.
610
author: sc2in
711

812
branding:

build.zig.zon

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// In a future version of Zig it will be used for package deduplication.
1313

1414
// When bumping this, also update extra.version in config.toml.
15-
.version = "1.7.2",
15+
.version = "1.7.3",
1616

1717
// Together with name, this represents a globally unique package
1818
// identifier. This field is generated by the Zig toolchain when the

config.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ include_content = true
155155

156156
[extra]
157157
homepage_style = "marketing"
158-
version = "1.7.2"
158+
version = "1.7.3"
159159
# release = "https://api.github.com/repos/getzola/zola/releases/latest"
160160
favicon = "https://www.getzola.org/favicon.ico"
161161
easydocs_logo_always_clickable = true

flake.nix

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -406,6 +406,22 @@
406406

407407
# Zola validates templates, content, and internal links in the sandbox.
408408
# PDF links use hardcoded hrefs so they are not checked here.
409+
# GitHub validates the Marketplace metadata in action.yml only when
410+
# a release is published to the Marketplace, in the release UI — no
411+
# local tool or CI step looked at it. v1.7.2 delisted the action that
412+
# way: `description` had grown to 133 characters against a
413+
# 125-character cap, which merged green, released green, and showed
414+
# up only as the listing 404ing. This check runs on every PR.
415+
checks.action-metadata =
416+
pkgs.runCommand "action-metadata"
417+
{
418+
nativeBuildInputs = [ pkgs.yq-go ];
419+
}
420+
''
421+
bash ${./tools/check-action-metadata.sh} ${./action.yml}
422+
touch $out
423+
'';
424+
409425
checks.zola-check =
410426
pkgs.runCommand "zola-check"
411427
{

tools/check-action-metadata.sh

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
#!/usr/bin/env bash
2+
# GitHub Marketplace metadata guards for action.yml, runnable locally
3+
# (`bash tools/check-action-metadata.sh`) and as the `action-metadata` flake
4+
# check on every PR.
5+
#
6+
# Why this exists: GitHub validates this metadata only when a release is
7+
# published to the Marketplace, in the release UI. Nothing in `zola check`, the
8+
# formatter, the test suite, or the release guards looks at it. So an invalid
9+
# value merges green, releases green, and the only symptom is the Marketplace
10+
# listing going 404 — which is exactly how v1.7.2 delisted the action: the
11+
# `description` had grown to 133 characters against a 125-character cap, and the
12+
# failure surfaced only as "Your action.yml needs changes before it can be
13+
# published" in the UI, after the tag was already immutable.
14+
#
15+
# Limits below are GitHub's documented Marketplace requirements. `::error::`
16+
# lines are GitHub Actions annotations; harmless when run locally.
17+
set -euo pipefail
18+
19+
file="${1:-action.yml}"
20+
status=0
21+
22+
# GitHub's cap. The message says "less than 125 characters", so 125 itself is
23+
# over the line and the check is >=.
24+
readonly DESCRIPTION_MAX=125
25+
26+
field() { yq -r ".$1 // \"\"" "$file"; }
27+
28+
name="$(field name)"
29+
description="$(field description)"
30+
icon="$(field branding.icon)"
31+
color="$(field branding.color)"
32+
33+
# A listing needs a name, and GitHub rejects one containing "GitHub".
34+
if [ -z "$name" ]; then
35+
echo "::error file=$file::action.yml has no 'name'; the Marketplace listing requires one."
36+
status=1
37+
elif printf '%s' "$name" | grep -qi 'github'; then
38+
echo "::error file=$file::action name '$name' contains \"GitHub\", which the Marketplace rejects."
39+
status=1
40+
else
41+
echo "name: '$name' ✓"
42+
fi
43+
44+
# The limit that actually bit us.
45+
if [ -z "$description" ]; then
46+
echo "::error file=$file::action.yml has no 'description'; the Marketplace listing requires one."
47+
status=1
48+
elif [ "${#description}" -ge "$DESCRIPTION_MAX" ]; then
49+
echo "::error file=$file::action.yml 'description' is ${#description} characters; the Marketplace requires fewer than ${DESCRIPTION_MAX}. Publishing a release to the Marketplace will fail and the existing listing will 404. Shorten it — put runner requirements and other detail in the README, which is the listing body."
50+
status=1
51+
else
52+
echo "description: ${#description}/${DESCRIPTION_MAX} characters ✓"
53+
fi
54+
55+
# branding drives the listing's icon and tile colour; absent, the listing cannot
56+
# be published. GitHub accepts a fixed colour set.
57+
if [ -z "$icon" ]; then
58+
echo "::error file=$file::action.yml has no 'branding.icon'; required to publish to the Marketplace."
59+
status=1
60+
else
61+
echo "branding.icon: '$icon' ✓"
62+
fi
63+
64+
case "$color" in
65+
white | yellow | blue | green | orange | red | purple | gray-dark)
66+
echo "branding.color: '$color' ✓"
67+
;;
68+
"")
69+
echo "::error file=$file::action.yml has no 'branding.color'; required to publish to the Marketplace."
70+
status=1
71+
;;
72+
*)
73+
echo "::error file=$file::branding.color '$color' is not one of GitHub's accepted values (white, yellow, blue, green, orange, red, purple, gray-dark)."
74+
status=1
75+
;;
76+
esac
77+
78+
if [ "$status" -ne 0 ]; then
79+
echo "action.yml would be rejected by the GitHub Marketplace." >&2
80+
fi
81+
exit "$status"

0 commit comments

Comments
 (0)