Sepasoft MES Module Suite
executeStepCommand(batchQueueEntry, path, command, changedBy)
Sends a batch command targeted at a single recipe step for an active batch queue entry. The runtime validates the step path, resolves the step for the running controller, and delivers a SET_STEP_COMMAND notification so the batch execution controller and equipment phase logic can apply the command (for example Hold, Reset, Stop) at that step. Use system.mes.batch.queue.COMMAND_* helpers for the command argument so the string matches the supported command vocabulary.
executeStepCommand(batchQueueEntry, path, command, changedBy) → void
Syntax
Python |
system.mes.batch.queue.executeStepCommand(batchQueueEntry, stepPath, command) system.mes.batch.queue.executeStepCommand(batchQueueEntry, stepPath, command, changedBy="operator") |
Parameters
Parameter | Type | Required | Description |
|---|---|---|---|
batchQueueEntry | BatchQueueEntry | Required | The queue entry whose running batch controller should receive the command. |
stepPath | str | Required | Full path to the step in the batch recipe. Must follow /Procedure/Unit_Procedure/Operation:Step. You may use {} as the procedure placeholder, for example /{}/My_UP/My_Op:My_Step. |
command | str | Required | Command to execute at the step. system.mes.batch.queue.COMMAND_ABORT() system.mes.batch.queue.COMMAND_HOLD() system.mes.batch.queue.COMMAND_PAUSE() system.mes.batch.queue.COMMAND_RESET() |
changedBy | str | Optional | Optional label stored with the change (for example an operator or screen name). Associates user actions with parameter changes. |
Return Type
Type | Description |
|---|---|
None | The function returns nothing when the command is accepted; failures raise an exception. |
Scope / Availability
Registered on system.mes.batch.queue (Sepasoft Batch / MES).
Gateway: Executes on the gateway that hosts the batch queue and active controller for the entry.
Designer / Client: Same API; calls are forwarded via the production RPC layer to the owning gateway (including Enterprise routing where applicable), consistent with other system.mes.batch.queue.* operations.
Excluded / Edge Cases
The queue entry’s batch controller must be active. If it is not, the call raises IllegalStateException with a message indicating the entry is not currently active.
system.mes.batch.queue.COMMAND_START() and system.mes.batch.queue.COMMAND_ABORT() cannot be used at step scope; the implementation rejects them with IllegalArgumentException. Use executeEntryCommand (or async/blocking variants) for Start and Abort at the batch entry level.
Unrecognized commands (including None / empty resolution) raise IllegalArgumentException (Invalid command.).
If stepPath does not resolve to a valid step for the running recipe logic, the call raises Exception with Invalid stepPath.
If E-Signature is enabled and the command has a configured Signature Template, if the script path does not bypass signatures; the call raises IllegalAccessException instructing you to use the Batch Controller Perspective component to run the command with authorization.
If the handler returns a non-empty error message after sending the notification, that text is thrown as Exception.
A missing or unknown BatchQueueEntry (not present on this gateway’s queue) surfaces as BatchQueueEntryNotFoundException (or related gateway errors). A null entry raises IllegalArgumentException.
The MES / batch subsystem must be started; otherwise checkMESSystemStarted failures apply as for other queue APIs.
Sepasoft MES Module Suite