Closed pedrolamas closed 3 years ago
Hi @PedroLamas
thanks for raising this issue. If I understand correctly this is the same issue as #138 where also a workaround was provided.
So what is supported by the task are "Variables" that are settable at queue time (interally called buildparameters) but not "Runtime Parameters".
If it is the same problem as issue 138 then you would need to go for a workaround, as I currently have not planned to add support for those kind of parameters in the TriggerBuildTask.
Please let me know whether the issue was the same and you could work around it of its a different problem.
Yes, reading through the other issue it does seem to be the same thing.
I will apply a workaround for this but maybe this is something that should be added to the docs as I suspect others will be reporting the same?
Also, would you be interested if I take a look and try to add this in and submit a PR for it?
Yes it should definelty go to the docs - I have a few things for documentation pending already:
Ideally I find time for those things and this problem to be documented properly in the next days.
Regarding the extended functionality, first of all thanks for the offer, very appreciated. I guess what could be done for sure is:
I think once these things are clarified the implementation wouldn't be too hard. Of course feel free to knock yourself out ont that as well. The problem at the moment is that for updating the calls to the REST API we will need to change https://github.com/huserben/TfsRestService as I put all the rest calls in this npm package (for easy reuse across the tasks and easy testability). This makes the implementation a bit more complex than it looks on first glance. But of course I would assist in case of questions
I am facing same problem in my case. Is there any work going on regarding this?
Hi @mohak2006
sorry to disappoint, but currently I'm too busy on other things so I cannot do much more than give basic support here via the issues. But no further development is planned on my side at the moment.
Parameters to pipelines like template parameters were added in the last several months. These are documented as Runtime Parameters, which is a bit of an unfortunate name as one key advantage is expansion time resolution. Variables cannot be guaranteed resolvable until runtime and don't some with type-safety.
So these "runtime" parameters should be handled differently than the current buildParameters
. The current name is a little unfortunate as buildParameters
is used to specify pipeline variables, but so goes the naming of things.
@jason-ha @pedrolamas @mohak2006
A new version of the task is now available that supports template parameters. Please let me know whether this solves your problems and whether it works as expected or not.
Thanks everyone for contributing, your help is appreciated!
I have a pipeline where I'm using template parameters, like on this example:
If I manually trigger the above pipeline, I will get an option to specify the Environment parameter:
This is what it shows when I run the pipeline and select "qa" as environment:
So I assumed that the "buildParameters" would work with the above, so I wrote the task like this:
Problem is that from what I can see, all this does is create a variable called "environment" on the child pipeline, not actually passing a build parameter:
Am I missing something here?