Hi,

I've created a workflow and it seems to be working fine, but I am getting intermittent errors displayed when viewing pages with workflow connected content, or their node forms across all pages (edit).

The errors are (repeated 5 x):
Notice: Undefined index: node in workflow_tokens() (line 188 of /~serverpath/workflow.module)
Notice: Trying to get property of non-object in workflow_tokens() (line 189 of /~serverpath/workflow.module)

Workflow is:
For 'supporter' content type
Actions (creation) > 'Review' state
1) Send new supporter notification e-mail
2) Redirect to Supporter thankyou page

Roles -
author
anonymous user
authenticated user
Can perform transition (creation) > Review

Email notification is working, and redirect is working, just that these errors are appearing - any ideas as to why?

Comments

azoho’s picture

I restored a previous db backup prior to the errors and found that the root of the problem was another module(s), the 'Social Media' and/or 'Widgets' modules.

As soon as I enabled those and starting configuring them I got the errors first about the Widgets module and then the Workflow_token errors above.

So not an issue with the Workflow module.

Bastlynn’s picture

It may be an error that only shows up in combination though.
Try the patch from here: #1418622: Tokens replacement does not respect hook_tokens documentation and tell me if that helps?

videographics’s picture

I'm seeing quite a bit of this without using the 'Social Media' or 'Widgets' modules.

I've been playing with using rules to create nodes and relations lately which I thought might be responsible. I know this lacks scientific testing and therefore may not be too helpful, but I'm getting a general sense that workflow 7.x has some issues when content with workflows get created and updated via rules.

Workflow tokens has been the other thing that I was thinking might be behind this.

I'm focused on other things right now so I haven't been paying so much attention to these errors, but hopefully this helps provide some insight into this issue...

highermath’s picture

We successfully applied that patch to deal with this issue.

highermath’s picture

We successfully applied that patch to deal with this issue.

berenddeboer’s picture

Category: support » bug
Status: Active » Reviewed & tested by the community

Had the same issue with the social media/widget modules. I applied this patch: #1570814: Notice: Undefined index: node in workflow_tokens()

And this works well. It's a very simple patch, the other patch seems to involve far more changes.

gkom’s picture

nancydru’s picture

Is this still an issue in the latest -dev?

nancydru’s picture

Status: Reviewed & tested by the community » Fixed

I am marking this as fixed because I can no longer reproduce it with recent changes.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

errors displaying across all pages