This is an automated email from the git hooks/post-receive script.
git pushed a commit to branch wl/browser-all
in repository enlightenment.
View the commit online.
commit c03d495fa2b19d05cfbbd0bb52a9095289bcf330
Author: Cedric BAIL <[email protected]>
AuthorDate: Sun Aug 16 20:36:00 2026 -0600
tests - do not pin the version of a global E does not create
wl-globals fails here: E advertises wl_shm 2, the file says 1. Nothing in this
tree changed. wl_shm is the one global E does not create - e_comp_wl.c calls
wl_display_init_shm() and libwayland makes it, at whatever version the linked
libwayland implements. This machine has 1.26.0, which added wl_shm.release and
so advertises 2.
meson requires wayland-server >= 1.11.0, so across the range E claims to
support that number is not constant. Pinning it exactly records a property of a
dependency rather than of E, and fails on a correctly built tree for a reason
that has nothing to do with the tree. That is the sort of failure that gets a
test deleted rather than read.
So let the expected version be written ">=N" as well as an exact number, and
use it for wl_shm alone. The reviewable property for a global E does not choose
is that it is advertised at all; every other line in the file is E's own
decision and stays exact, because an exact version is the entire point of the
file and ">=" on one of those would hide a real regression.
Raising the wayland-server floor to whichever release added wl_shm 2 would also
have made it deterministic. That is a large jump to E's dependencies bought
purely to make one line of a test file well-defined, so no.
The comparison moves from diff -u to awk, which the ">=" needs. The report
keeps diff's '-' and '+' idiom because that is what the file's readers already
know, and adds '!' for present-but-wrong-version, which diff used to render as
a confusing -/+ pair. Every path checked with synthetic input: missing global,
extra global, exact version wrong, ">=" satisfied at the floor and above it,
">=" below the floor.
The refresh hint now warns that a blind refresh turns ">=" back into an exact
version, because it does.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
---
src/tests/wayland/check-globals.sh | 70 ++++++++++++++++++++++++++++++++++----
src/tests/wayland/globals.expected | 2 +-
2 files changed, 65 insertions(+), 7 deletions(-)
diff --git a/src/tests/wayland/check-globals.sh b/src/tests/wayland/check-globals.sh
index 432f415ce..02c7cffd4 100755
--- a/src/tests/wayland/check-globals.sh
+++ b/src/tests/wayland/check-globals.sh
@@ -7,6 +7,15 @@
# version) or an intentional change that has not been recorded yet. For the
# latter, update globals.expected in the same commit as the protocol change --
# that file is the reviewable record of E's Wayland protocol surface.
+#
+# Each line of globals.expected is "<interface><TAB><version>", and the version
+# may be written ">=N" instead of an exact number. That is for the globals E
+# does not create and whose version it therefore does not choose: pinning those
+# exactly records a property of a dependency rather than of E, and fails on a
+# machine with a different one for a reason that has nothing to do with this
+# tree. Use it sparingly -- an exact version is the whole point of the file for
+# everything E does decide, and ">=" on one of those would hide a real
+# regression.
set -eu
@@ -24,19 +33,68 @@ trap 'rm -f "$ACTUAL"' EXIT INT TERM
"$RUNNER" "$DUMPER" >"$ACTUAL"
-if diff -u "$EXPECTED" "$ACTUAL"; then
- exit 0
-fi
+# The report keeps diff's '-' and '+' idiom, because that is what the file's
+# readers already know, and adds '!' for a version that is present but wrong.
+REPORT=$(awk '
+FILENAME == ARGV[1] {
+ want[$1] = $2
+ order[++n] = $1
+ next
+}
+{
+ got[$1] = $2
+}
+END {
+ for (i = 1; i <= n; i++)
+ {
+ name = order[i]
+ if (!(name in got))
+ {
+ print "-" name "\t" want[name] " (not advertised)"
+ bad = 1
+ continue
+ }
+ if (want[name] ~ /^>=/)
+ {
+ floor = substr(want[name], 3) + 0
+ if (got[name] + 0 < floor)
+ {
+ print "!" name "\t" got[name] " (expected " want[name] ")"
+ bad = 1
+ }
+ }
+ else if (got[name] != want[name])
+ {
+ print "!" name "\t" got[name] " (expected " want[name] ")"
+ bad = 1
+ }
+ }
+ for (name in got)
+ if (!(name in want))
+ {
+ print "+" name "\t" got[name]
+ bad = 1
+ }
+ exit bad ? 1 : 0
+}
+' "$EXPECTED" "$ACTUAL") && exit 0
+
+printf '%s\n' "$REPORT" >&2
cat >&2 <<EOF
check-globals: advertised globals do not match $EXPECTED
- '-' lines are expected but missing -> a regression, or a global that moved
- '+' lines are advertised but new -> update globals.expected in the same
- commit that added them
+ '-' expected but not advertised -> a regression, or a global that moved
+ '!' advertised at another version -> a version bump, intended or not
+ '+' advertised but not expected -> update globals.expected in the same
+ commit that added them
To refresh the file after an intentional change:
$RUNNER $DUMPER > $EXPECTED
+
+but read the result before committing it: a blind refresh turns every ">="
+line back into an exact version and quietly re-pins something this tree does
+not control.
EOF
exit 1
diff --git a/src/tests/wayland/globals.expected b/src/tests/wayland/globals.expected
index e374ea9f2..e8dfe02f8 100644
--- a/src/tests/wayland/globals.expected
+++ b/src/tests/wayland/globals.expected
@@ -5,7 +5,7 @@ wl_data_device_manager 3
wl_output 4
wl_seat 8
wl_shell 1
-wl_shm 1
+wl_shm >=1
wl_subcompositor 1
wp_fractional_scale_manager_v1 1
wp_viewporter 1
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.