Repository navigation
fix(ci): stop concatenating per-module versions into RELEASE_VERSION - #1910
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes malformed daemon self-registration versions by ensuring RELEASE_VERSION resolves to a single value from versions.yaml, preventing multi-line version strings from being embedded into ldflags and propagated into OASF records.
Changes:
- Replace
grep | awkwith anawkearly-exit pattern to avoid concatenating multipleversion:values. - Add inline comments documenting why only one module-set version should be selected.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Signed-off-by: András Jáky <[email protected]>
Signed-off-by: András Jáky <[email protected]>
akijakya
force-pushed
the
fix/concatenated-versions
branch
from
July 29, 2026 10:33
6248c38 to
a3db8fc
Compare
tkircsi
approved these changes
Jul 29, 2026
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.
Problem
When the local
dirdaemon starts, it self-registers anorg.agntcy/directoryOASF record describing the node. That record'sversionfield came out malformed with an embedded newline — e.g."v1.6.1\n1.6.1"— which downstream tooling then rendered as two lines (this surfaced as a broken row in the lazydir Records panel).Root cause
RELEASE_VERSIONinTaskfile.vars.ymlwas computed as:versions.yamlis a multi-module config with aversion:key per module-set (apiandserver).greptherefore matched both lines andawkemitted the two values separated by a newline. Task'ssh:only strips the trailing newline, so the interior\nsurvived into the-X ...version.Version=ldflag, intoapi/version.Version, and into the self-registered record'sversion.Fix
Select a single module-set's version and stop before the second match:
This takes the first (
api) version — the one that stampsapi/version.Version— and produces exactly one clean value. No new tool dependency (staysawk, portable across GNU/BSD).Verification
v1.6.1\nv1.6.1\n(interior newline); after →v1.6.1\n(single value; Task trims the trailing newline).task build --drynow renders...version.Version=v1.6.1.task --list-all/task build --drysucceed → the Taskfile still parses.