ansibleguy76 / ansibleforms

A webapplication to create pretty advanced forms to run ansible playbooks or awx templates.
https://ansibleforms.com/
GNU General Public License v3.0
66 stars 10 forks source link

"Let the form stabilize and try again" on linked placeholders #129

Closed MalfuncEddie closed 8 months ago

MalfuncEddie commented 8 months ago

Describe the bug

Form stuck in "stabilizing" I think the issue is that I also need the dependencies: in the last fied datadisk_size.

not sure if this is a bug tho.

When the checkbox is not checked the value diskhide is never entered and datadisk_size is never filled in. On submit this results in

It took too long to evaluate all fields before run.\r\nLet the form stabilize and try again.

I think this is because the fields are linked to each other.But since the default required is false it should go trough?

To Reproduce

  - name: datadisk
    label: Data Disk
    type: checkbox
  - name: diskhide
    type: number
    label: Disk
    noOutput: true
    dependencies:
      - name: datadisk
        values:
          - true
  - name: datadisk_size
    type: expression
    expression: $(diskhide) + 'g'
    runLocal: true
    hide: true

Expected behavior form submitted even when datadisk_size is not stable.

Workaround

  - name: datadisk
    label: Data Disk
    type: checkbox
  - name: diskhide
    type: number
    label: Disk
    noOutput: true
    dependencies:
      - name: datadisk
        values:
          - true
  - name: datadisk_size
    type: expression
    expression: $(diskhide) + 'g'
    runLocal: true
    hide: true
    dependencies:
      - name: datadisk
        values:
          - true

Version ansibleforms v4.0.19

Deployment Deployed ansibleforms with :

Additional context Add any other context about the problem here.

ansibleguy76 commented 8 months ago

unhide all fields. probably there is an expression field somewhere that can't get evaluated. you should see it spinning. there is a property ignoreIncomplete