fix(ax): join lib embed paths consistently

Co-Authored-By: Virgil <virgil@lethean.io>
This commit is contained in:
Virgil 2026-03-30 16:57:06 +00:00
parent eb7a6e31db
commit 95c7df04da
2 changed files with 7 additions and 6 deletions

View file

@ -423,6 +423,7 @@ Every exported function MUST have a usage-example comment:
## Changelog
- 2026-03-30: lib task bundle and recursive embed traversal now use `JoinPath` for filesystem paths, removing the last string-concatenated path joins in `pkg/lib`.
- 2026-03-30: runner workspace status projections now use explicit typed copies, and `ReadStatusResult` gained direct AX-7 coverage in both runner and agentic packages.
- 2026-03-30: transport helpers preserve request and read causes, brain direct API calls surface upstream bodies, and review queue retry parsing no longer uses `MustCompile`.
- 2026-03-30: direct Core process calls replaced the `proc.go` wrapper layer; PID helpers now live in `pid.go` and the workspace template documents `c.Process()` directly.

View file

@ -196,12 +196,12 @@ func TaskBundle(slug string) core.Result {
if !r.OK {
return core.Result{Value: b, OK: true}
}
nr := data.ListNames(core.Concat("task/", slug))
nr := data.ListNames(core.JoinPath("task", slug))
if nr.OK {
for _, name := range nr.Value.([]string) {
for _, ext := range []string{".md", ".yaml", ".yml", ".txt", ""} {
fullName := core.Concat(name, ext)
if fr := taskFS.ReadString(core.Concat(slug, "/", fullName)); fr.OK {
if fr := taskFS.ReadString(core.JoinPath(slug, fullName)); fr.OK {
b.Files[fullName] = fr.Value.(string)
break
}
@ -358,7 +358,7 @@ func listNamesRecursive(mount, dir string) []string {
return nil
}
path := core.Concat(mount, "/", dir)
path := core.JoinPath(mount, dir)
nr := data.ListNames(path)
if !nr.OK {
return nil
@ -368,10 +368,10 @@ func listNamesRecursive(mount, dir string) []string {
for _, name := range nr.Value.([]string) {
relPath := name
if dir != "." {
relPath = core.Concat(dir, "/", name)
relPath = core.JoinPath(dir, name)
}
subPath := core.Concat(mount, "/", relPath)
subPath := core.JoinPath(mount, relPath)
// Try as directory — recurse if it has contents
if sub := data.ListNames(subPath); sub.OK {
@ -389,7 +389,7 @@ func listNames(mount string) []string {
return nil
}
r := data.ListNames(core.Concat(mount, "/."))
r := data.ListNames(core.JoinPath(mount, "."))
if !r.OK {
return nil
}