Closed chris-twosense closed 2 years ago
Hi @chris-twosense, thanks for reporting this.
Something is definitely wrong here. I should have time to look into it next week.
Hi @chris-twosense, It took me a couple of minutes of debugging to spot it, but there's a subtle error in your example.
[[tool.poe.tasks.download-env]]
There should be only single square brackets around the task name header. Having double square brackets makes it a key with a value that is an array containing the task config, instead of just the task config directly as the value.
This means that you get
tool.poe.tasks.download-env = [{...}]
instead of just
tool.poe.tasks.download-env = {...}
This causes the task to be interpreted as a sequence task containing a shell task, which means there's no way to pass the arguments to the shell task defined inside the sequence.
I've taken a note that poe should catch this kind of error in the config validation stage to make such errors easier to avoid, but I believe the resolution of your issue is just to remove the excess brackets :)
I am trying to set up a poe task which runs a script with a single argument:
Running the above task produces the following error:
I have tried running this from a clean project, bash, zsh, as well as removing around with the "required" option, which produces the following:
I am unsure if this is an issue with the project or my environment but as I've been unable to find much documentation on the issue I figured this is the best forum to ask. Thanks!