-
Notifications
You must be signed in to change notification settings - Fork 120
Open
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.
Description
Bug
Overview
Line 1078 in e88cece
| func IsParent(child, parent string) bool { |
When path is relative it joins with the current working.
In WASM the current working directory is / and we hit this if condition
Lines 1088 to 1090 in e88cece
| if parent == "/" { | |
| return true | |
| } |
so it returns true.
And because IsParent returns true, we try to make a path relative to an empty string '' and hit this error
move2kube/environment/environment.go
Lines 272 to 274 in e88cece
| rel, err := filepath.Rel(e.GetEnvironmentOutput(), path) | |
| if err != nil { | |
| logrus.Errorf("Unable to make path (%s) relative to output (%s) : %s ", path, e.GetEnvironmentOutput(), err) |
Fix
- Make sure all the paths are absolute before giving to these functions. We should be using absolute paths everywhere.
- Also add a
if parent == "" || child == "" { return false; }in theIsParentfunction
Metadata
Metadata
Assignees
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.
Type
Projects
Status
Backlog