When I define my sources as absolute paths and trigger my task with the --watch option, the change detected works unreliably after a couple of file changes. Please find attached an example Taskfile.yml, to make this issue reproducible:
version: '2'
tasks:
ok:
cmds:
- date -u +"%Y-%m-%dT%H:%M:%SZ"
sources:
- ./client/src/**/*
generates:
- ./client/dist/*
silent: true
fail:
cmds:
- date -u +"%Y-%m-%dT%H:%M:%SZ"
sources:
- /Users/Batman/Desktop/app/client/src/**/*
generates:
- /Users/Batman/Desktop/app/client/dist/*
silent: true
The fail task in combination with the --watch option will stop working after a couple of changes. If I run the the same command without the watch option, the change detection for caching works perfectly fine with absolute paths.
Tested with:
Task version: 2.7.0
Environments: Debian, MacOS, Alpine (Docker)
Hi @philippwaller, thanks for opening this issue!
This is a pretty curious bug indeed.
I haven't had the time to debug and fix it yet, but plan to do so once possible.
Most helpful comment
Hi @philippwaller, thanks for opening this issue!
This is a pretty curious bug indeed.
I haven't had the time to debug and fix it yet, but plan to do so once possible.