Skip to content

compileDslApp validation intermittently rejects a CustomFunction-predicate If wrapping Firestore actions in a Button onTap (accepts at push, then rejects identical DSL hours later) #7203

@khanmd14-max

Description

@khanmd14-max

Can we access your project?

  • I give permission for members of the FlutterFlow team to access and test my project for the sole purpose of investigating this issue.

Current Behavior

Current Behavior

Using the FlutterFlow DSL / AI tooling (flutterflow ai validatecompileDslApp),
validation intermittently rejects the onTap action chain on the button CatSaveButtonSubCat
(the sub-category Save button on the AddCategorySheet component).

That chain wraps its Firestore Create/Update actions inside an If(CustomFunction(...))
predicate, where the Custom Function (subcatNameClashes) takes a List<DocumentReference>
parameter (passed from a component Param, not an Action Output).

Over ~3 days the validator has rejected this same button with an EVOLVING set of errors:

  • Field "name" is not properly set in Database action for CatSaveButtonSubCat
  • Conditional execution for action is improperly set
  • (earlier) Field "catFormName" has an update value that is not properly set in Update App State action

The core problem is NON-DETERMINISM: the SAME byte-identical DSL validated [OK] and pushed
successfully, then was rejected by the validator a few hours later with NO project, SDK, or
code change. This has happened 3-4 times; each time I reshaped the chain to satisfy the new
error, the reshaped version was itself accepted at push and then rejected hours later.

Minimal isolation (strong repro)

Removing ONLY the If(CustomFunction(subcatNameClashes, ...)) wrapper — hoisting the Firestore
Create/Update actions directly into the parent block, every field binding kept byte-identical —
clears ALL errors immediately (compileDslApp [OK]).

A structurally similar Save chain on the SAME component (CatSaveButton, top-level category)
uses the identical field binding ('name': <WidgetState CatNameField.text>) but has NO
CustomFunction-predicate If wrapping its Firestore actions — and is NEVER flagged.

=> The trigger appears to be the outermost CustomFunction-predicate If (CF taking a
List arg) wrapping a Database action inside a Button onTap chain.

Expected Behavior

Validation should be deterministic for unchanged DSL. A valid If(CustomFunction(...))
predicate wrapping a Firestore action in a Button onTap chain should validate consistently,
and a shape accepted at push time should not be rejected hours later with no change.

Steps to Reproduce

  1. On a component, add a Button with an onTap action chain.
  2. Add a Custom Function taking a List<Document Reference> parameter, returning bool.
  3. Wrap the button's Firestore Create/Update actions in If(CustomFunction(thatFn, ...)).
  4. Run compileDslApp validation repeatedly over time (across server-side validator updates).
  5. Observe intermittent rejection with "Field ... not properly set in Database action" +
    "Conditional execution improperly set"; removing the CF-predicate If clears them.

Environment

  • FlutterFlow version: <fill in — Settings/About in the editor>
  • Platform: Web
  • Browser: Chrome (also reproduced in Safari)
  • OS: macOS

Expected Behavior

Expected Behavior

Validation should be deterministic for unchanged DSL. A valid If(CustomFunction(...))
predicate wrapping a Firestore action in a Button onTap chain should validate consistently,
and a shape accepted at push time should not be rejected hours later with no change.

Steps to Reproduce

Steps to Reproduce

  1. On a component, add a Button with an onTap action chain.
  2. Add a Custom Function taking a List<Document Reference> parameter, returning bool.
  3. Wrap the button's Firestore Create/Update actions in If(CustomFunction(thatFn, ...)).
  4. Run compileDslApp validation repeatedly over time (across server-side validator updates).
  5. Observe intermittent rejection with "Field ... not properly set in Database action" +
    "Conditional execution improperly set"; removing the CF-predicate If clears them.

Reproducible from Blank

  • The steps to reproduce above start from a blank project.

Bug Report Code (Required)

ITEShvLl25dgrs9Z1rrIbcJAhQAkH1x/bZJEl9dTd0s0fZPkE5l3Pur+VBRpTM+hdG52HWL/jmcH0N7tieHtA+0CZDadaINo+pZhEQ3MJXiub8WIPJG0Q3MlAfFnCXac5sKNmwhdJtBpV1Ejw3z/cq3qNleeY8aSfxBlZ7vfcPo=

Visual documentation

Screenshot 1: compileDslApp validation FAILING on CatSaveButtonSubCat
"Field name not properly set in Database action" ×2 and "Conditional execution
improperly set" ×2 — on byte-identical DSL that validated [OK] and pushed
successfully a few hours earlier.

Screenshot 2: isolation probe — removing ONLY the
If(CustomFunction(subcatNameClashes, ...)) wrapper clears all 4 errors ([OK]),
confirming the CustomFunction-predicate If wrapping the Firestore actions is the trigger.

Image

Environment

## Environment

- FlutterFlow version:  FF editor version
- Platform: Web
- Browser: Chrome (also reproduced in Safari)
- OS: macOS

Additional Information

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: needs triageA potential issue that has not been confirmed as a bug.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions