Question

Default vs explicit blank values in ServerJobSubmitter/WorkspaceRunner ?

  • 12 October 2021
  • 2 replies
  • 2 views

Userlevel 1
Badge +22

Hi.

When you have a workspace with a published parameter of type text, and it has a default (e.g. testing) value, this gets used whenever the value isn't specified in JobSubmitter/WorspaceRunner.

If I submit a blank text as a parameter value, this seems to be ignored, and the default value is used instead.

Is this WAD ?

If I want to overrule a default parameter value with a blank value, how is this achieved ?

Cheers


2 replies

Userlevel 5
Badge +25

Do you, by any chance, have a small test case?

I've tried to reproduce it and in my case it works the other way around: I'm running workpace A through a WorkspaceRunner in workspace B. It has 1 optional parameter with a default value set. If I leave the field empty in the WorkspaceRunner it will pass that empty value on to workspace A (which is what you want), but... I can't get it to use the default!

I think I can force it to use the default if I set the parameter to be required, but then I can't leave it empty...

Userlevel 1
Badge +22

Do you, by any chance, have a small test case?

I've tried to reproduce it and in my case it works the other way around: I'm running workpace A through a WorkspaceRunner in workspace B. It has 1 optional parameter with a default value set. If I leave the field empty in the WorkspaceRunner it will pass that empty value on to workspace A (which is what you want), but... I can't get it to use the default!

I think I can force it to use the default if I set the parameter to be required, but then I can't leave it empty...

Alas, I did make a small test workspace at the time, and it didn't act as my large production workspace :-S

In the test workspace a submitted blank parameter overwrites the default value, as expected and wanted.

I think I'll defer this question to a later time, if I run into it again. It may have been just a fluke.

Reply