Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Class "Civi\Token\CiviTokens" used for service "crm_civitoken" cannot be found. #62

Open
chumkui opened this issue Feb 8, 2023 · 2 comments

Comments

@chumkui
Copy link

chumkui commented Feb 8, 2023

I've just done a fresh Civi (v5.58) on Drupal 9 locally to do some testing with the default dummy data and nothing enabled. I enabled only this extension at first as a test re enabling extensions (it is used on our prod Drupal 7 site).

The errors in the log are:

Referrer | https://mws.email/civicrm/admin/extensions?action=update&id=nz.co.fuzion.civitoken&key=nz.co.fuzion.civitoken

Messages:

Symfony\Component\DependencyInjection\Exception\InvalidArgumentException: Class "Civi\Token\CiviTokens" used for service "crm_civitoken" cannot be found. in Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass->process() (line 111 of /var/www/html/vendor/symfony/event-dispatcher/DependencyInjection/RegisterListenersPass.php).

Symfony\Component\DependencyInjection\Exception\InvalidArgumentException: Class "Civi\Token\CiviTokens" used for service "crm_civitoken" cannot be found. in Symfony\Component\EventDispatcher\DependencyInjection\RegisterListenersPass->process() (line 111 of /var/www/html/vendor/symfony/event-dispatcher/DependencyInjection/RegisterListenersPass.php).

We do not have any issues using it in prod so I am wondering if there are any dependencies that I need to be aware of?

If I use the browsers back button and click install again, it's fine... so I wonder if it is my setup in some way.

@eileenmcnaughton
Copy link
Owner

@totten this seems like a load order issue in core - but the steps to replicate seem like they are very 'clean' & hopefully repeatable. CiviToken does have <psr4 prefix="Civi\" path="Civi"/> in the info.xml and there is nothing in the CRM folder

@totten
Copy link

totten commented Feb 8, 2023

Interesting. Agree that's a good report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants