Hi,
I'm having this warning, and don't know how to solve it. I have update from version 1.5 to dev, without success:

Tokens Problems detected
The following token types are not defined but have tokens:
$info['types']['commerce_customer_profile']

Thanks for help.

Comments

rszrama’s picture

Category: bug » support
Status: Active » Postponed (maintainer needs more info)

Think we need more info on how to reproduce the message you're seeing. Looks like some third party module conflict. : ?

dan_metille’s picture

Here are the modules that I have related to Commerce or user profile:

- Commerce Addressbook
- Checkout Login
- Realname registration
- Simplenews RealName
- Entity & Entity Token

However, I don't know exactly when the problem started. What kind of other information can be useful?

rszrama’s picture

My guess is Entity Token. : ?

dan_metille’s picture

Well, that was also my first insight and I tried to update to the last entity_token dev version without success.
Actually, to be honest, I'm not sure even to understand the meaning of this problem message, neither its possible consequences.
Also all the entity_token dependencies make it difficult to uninstall it. Any other insight that posting a issue on the Entity page?

dan_metille’s picture

Just made a simple search on my Finder in my local install for 'commerce_customer_profile' and find out that the following (sub)modules are mentioning it:

- Commerce Addressbook
- Commerce Cart
- Commerce Checkout
- Commerce Customer
- Commerce Order
- Commerce Payment
- Commerce Paypal (7.2)

So, the 2 third party modules of the list are Addressbook & Paypal, right?

Should I try to uninstall them?

dan_metille’s picture

Still have the issue after Addressbook and Paypal uninstall. Any hint about the next step?

dan_metille’s picture

Category: support » bug

rszrama, I really think that this have to do with Commerce:

- the message don't disappears while uninstalling other modules.
- the message disappears if I drop the Commerce module from my local install to the trash, while I'm then getting the following messages:

Warning : Invalid argument supplied for foreach() dans commerce_line_item_field_views_data() (line 1537 in xxx/sites/all/modules/commerce/modules/line_item/commerce_line_item.module).

Warning : Invalid argument supplied for foreach() dans commerce_customer_field_views_data() (line 436 in xxx/sites/all/modules/commerce/modules/customer/commerce_customer.module).

- and I get again the

The following token types are not defined but have tokens:
$info['types']['commerce_customer_profile']

when I put the Commerce module back to its place.

As I'm not developer, I cannot really tell more, if you have some hints about how to debug this, it would be welcome.

PS: I've the today's last dev version of Commerce and all other modules up to date.

rszrama’s picture

Category: bug » support

Ok, I can look into it further. I've never seen the error message before, though, so I'll have to be able to reproduce it to determine if it's a bug or an incompatibility with a third party module.

dan_metille’s picture

Thank you rszrama, I have although never seen it before. The other thing is that I'm not aware about the implication of this warning. Is it serious one?
Just in case, is there any quick way to export my products (around 50) and reinstall all Commerce modules?

rszrama’s picture

Nah, you shouldn't have to do that. It isn't a serious warning message, especially if you don't notice any other problems anywhere.

rszrama’s picture

Status: Postponed (maintainer needs more info) » Closed (works as designed)

Looking at this further, I see now that the issue is your tokens are defined using the type "commerce_customer_profile" when the token type used by core Commerce is "commerce-customer-profile." The difference is hyphens vs. underscores. Some module on your site is adding customer profile tokens using the wrong token type string. The Entity Token module itself uses the proper token type thanks to the parameter we include in our entity info, so the culprit is some other contributed module on your site. I did a quick check and neither the Addressbook nor PayPal modules define tokens.

You may just need to search your source code to find out which module is doing it. I'd recommend searching all of your contributed modules for "commerce_customer_profile" and see if any of them include it in a reference to token definition. If you find the culprit, please reopen this issue and move it to the module's issue queue.

dan_metille’s picture

Project: Commerce Core » Phone
Version: 7.x-1.x-dev » 7.x-2.x-dev
Component: Other » Code
Category: support » bug
Status: Closed (works as designed) » Active

Thank you rszrama. Was not easy to search through all source code for me, but looks like while deleting my Phone field, the warning vanished.

So I'm now reopening the issue into the Phone project.

cdale’s picture

Status: Active » Needs review

Thanks. Did not know about "token type" in entity info.

This is fixed by http://drupalcode.org/sandbox/cdale/1925578.git/commit/07fa877cf683cc61b.... Waiting on @cweagans to do a code pull into 7.x-2.x.

cweagans’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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