Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BC-break: working directory prepended twice to watch directories #81

Open
MasonM opened this issue Jan 23, 2025 · 0 comments
Open

BC-break: working directory prepended twice to watch directories #81

MasonM opened this issue Jan 23, 2025 · 0 comments

Comments

@MasonM
Copy link

MasonM commented Jan 23, 2025

v0.1.28 (specifically, 0c28810) changed the watch attribute so the workingDir is automatically prepended to each file. I think that change makes sense, but unfortunately it's backwards-incompatible, since it means the workingDir will be prepended twice if you were relying on the previous behavior. Here's a minimal reproduction example (adapted from https://github.com/argoproj/argo-workflows/blob/main/tasks.yaml):

apiVersion: kit/v1
kind: Tasks
metadata:
  name: argo-workflows
spec:
  tasks:
    - name: ui-deps
      command: yarn install
      workingDir: ui
      watch: ui/package.json ui/yarn.lock

In v0.1.27, this worked:

$ kit -v
v0.1.27

$ kit ui-deps

isCI=false
noWatch=false
[ui-deps] starting process "yarn install"
[ui-deps] waiting for process 143744 pgid 143744 ("yarn install")
[ui-deps]  yarn install v1.22.22
[ui-deps]  [1/5] Validating package.json...
[ui-deps]  [2/5] Resolving packages...
[ui-deps]  success Already up-to-date.
[ui-deps]  Done in 0.20s.
[ui-deps] process exited 143744: <nil>
[ui-deps] context cancelled, stopping process
[ui-deps] terminating process 143744
[ui-deps] waiting 3s before killing 143744

In v0.1.72, you get an error:

 $ ~/go/bin/kit -v ui-deps
v0.1.72

 $ ~/go/bin/kit ui-deps
no such file or directory

Also, it seems v0.1.46 changed the error reporting so it's less useful, because you used to get more detailed error messages for missing files, e.g.

$ ./kit -v && ./kit ui-deps
v0.1.45

[ui-deps] (running) starting process
stat ui/ui2/package.json: no such file or directory
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant