Upgraded from Workflow 2.8 to Workflow 2.13 on a drupal 7 site (currently running 7.67).

The configured workflows are using Workflow Field

Since upgrading workflow Content created under the previous workflow version no longer correctly transitions between states,

If the node is saved without the workflow state being changed then the workflow behaves as normal. (finding and resaving every affected piece of content isn't practical on the site affected.)

it appears that the transition pre operation is not being triggered correctly.

logging the value of $op and $transition in an existing implementation of hook_workflow shows that on the node edit page load for an affected node the transition permitted op is triggered, but $transition is an instance of WorkflowConfigTransition, rather than the expected instance of WorkflowTransition.

On save of an affected object the transaction pre operation is not triggered at all.

Also on saving an affected object the workflow state id is updated on the workflow field, however workflow_node_history isn't updated at all.

Comments

jkeasley created an issue. See original summary.

jkeasley’s picture

I have identified where the issue we have been experiencing was caused.

the following patch https://www.drupal.org/files/issues/workflow-integration-with-revisionin..., as applied in the workflow 2.8 - 2.9 update, prevents any of the workflows created by workflow 2.8 in the affected system from updating state transitions correctly unless the node has been saved through the edit form interface without the state being changed first.

removing the code added by the above patch allows the workflow transitions to operate correctly.

Looking at the data returned by the two calls (same db, reloaded after the node has been saved) there is a mismatch between the vuuid values returned, and in the failing iteration the returned object lacked a value for vid.

jkeasley’s picture