commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Mansell <>
Subject [SCXML] Eventless transitions not selected after event?
Date Tue, 16 Jul 2019 02:09:08 GMT
I could easily be misunderstanding the SCXML specification, but it looks like that if you have
(a tweaked example of my actual code):

<scxml xmlns="" version="1.0" initial="start"> 


    <data id="data">{ "result": "unknown"}</data>


  <state id="start">

    <invoke id="lookup" type="data">

      <content expr="'blah'" />


        <assign location="data.result" expr="'found'" />



    <transition cond="data.result == 'found'" target="found" />


  <state id="found" />


Basically, you're issuing an invoke, and during it's finalize, you're updating some data model.
The transition for that state is waiting until the data changes before moving to the next

The interesting part here is that the transition has no event. As far as I can understand
the specification, specifically the section on mainEventLoop(), after an event (in this case
the done.invoke.lookup) and after any event-based transition, the "event-less" transitions
should be selected. However, the code in SCXMLSemanticsImpl, specifically the nextStep() only
handles event-less code (via the macroStep()) if there was at least one transition that was
selected by the event, which in this case, there is not.

It seems like a pretty simple fix, but I'm not 100% sure that I'm reading the spec right (I'm
reasonably new to SCXML).


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message