Skip to content

CALL JAVASCRIPT ACTION with entity <> parameter — mxcli check passes, mxbuild fails with CE0115 #1171

Description

@acarum

When mxcli writes a nanoflow via exec containing a call to a JavaScript action whose parameter is typed entity <>, the resulting MPR is rejected by mxbuild with CE0115:

▎ "The arguments that are passed to JavaScript action 'NanoflowCommons.RefreshEntity' do not match the expected parameters and need to be refreshed."

mxcli check --references does not detect the problem — the check passes with no errors.

Steps to reproduce

  1. JavaScript action with an entity <> parameter:
    NanoflowCommons.RefreshEntity(EntityToRefresh: entity <> not null)
  2. MDL written by mxcli via exec:
    mdl
    create or modify nanoflow CustomModule.ACT_Example ()
    begin
    $Var = call javascript action NanoflowCommons.RefreshEntity(
    EntityToRefresh = ReferenceData.Dimension
    );
    return;
    end;
    /
  3. ./mxcli check script.mdl -p "System.mpr" --references → ✅ Check passed
  4. ./mxcli exec script.mdl -p "System.mpr" → ✅ Replaced nanoflow
  5. ./mxcli docker check -p "System.mpr" → ❌ CE0115

Root cause (suspected)

Studio Pro internally stores a UUID binding for entity <> type parameters (generic entity type parameters). This binding is not written by mxcli exec into the MPR, leaving the call
structurally incomplete at the model level even though it is syntactically valid MDL.

Evidence: the identical nanoflow ReferenceData.ACT_CreateDimension, written by Studio Pro with the same MDL syntax, compiles without errors. DESCRIBE NANOFLOW emits the
same MDL for both, but the internal MPR representation differs.

Expected behavior

Either mxcli exec correctly serializes the entity UUID binding for entity <> parameters in JS action calls, or mxcli check detects the missing binding and blocks execution with an explicit
error rather than silently producing a broken MPR.

Environment

  • Mendix: 11.12.4
  • mxcli: 0.23.0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions