Closed (fixed)
Project:
Conference Organizing Distribution
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
30 Aug 2007 at 00:06 UTC
Updated:
27 Feb 2008 at 13:42 UTC
When initially installing pathauto via a drupal install profile, I had a PHP Fatal error: Call to undefined function token_get_values() in modules/pathauto/pathauto.inc on line 315. I'm not sure if the attached patch is the "correct" way to fix it, but it does work.
| Comment | File | Size | Author |
|---|---|---|---|
| pathauto.token_.patch | 671 bytes | mfb |
Comments
Comment #1
xav commentedNot sufficient here. The error is now in pathauto_user.inc, and apparently there's an untold dependency with the "token" module ...
Comment #2
greggles@mfb - which version of token are you using? 5.x-1.8 or 5.x-1.x-dev shouldn't have this problem. Was it anything else aside from just installing it? I think the problem you face may only affect the installation profile situation and not necessarily the normal use, is that right?
@xav - please define "untold" because the dependencies is documented 1) on the pathauto project page for months now and also more directly in the pathauto.info file since april 27th.
Comment #3
mfbI am using token module current DRUPAL-5 branch.
Install profile is a "normal" usage, in my opinion, given the many profiles using pathauto: drupal wiki, bryght basic, etc.
I haven't looked into this enough to know where the bug lies, pathauto or token module?
Comment #4
gregglesBut you have to agree that the installation process is more of a corner case than every day operation of the site.
Perhaps I am just confused - Does the problem only occur during the installation or is it all the time (e.g. during node creation after the profile has been installed)?
Comment #5
mfbThis now seems to be fixed in the current DRUPAL-5--2 branch.
Comment #6
(not verified) commentedComment #7
jackbravo commentedHi. I'm using pathautho-2.0 and this doesn't seem to be fixed. I tried with current drupal 5.3 and with latest drupal branch DRUPAL-5 from CVS. I get the same error just on a different line:
Fatal error: Call to undefined function token_get_values() in /var/www/conference/web/profiles/cod/modules/pathauto/pathauto.inc on line 354
I'm also using an installation profile. The Conference Organizing Profile. Should I open a new bug?
Comment #8
jackbravo commentedFor me, the problem occurs only during installation (it doesn't let me continue after that).
Comment #9
gregglesGood points.
I will test this out and see if i can find a fix.
Comment #10
greggles@jackbravo - I think this is actually a bug with cod. They need to add "token" as a requirement and then also add it into cod_profile_modules()
Can you test out if that fixes the problem? thanks.
Comment #11
jackbravo commentedIf I can help with anything just let me know. I know PHP although but I'm not familiar with drupal internals.
Comment #12
gregglesmy comment in #10 proposes a solution - can you edit the .profile file and include the token module in your sites/all/modules and see if that fixes it?
Comment #13
jackbravo commented@greggles - Sorry, didn't see your #10 comment.
I did what you say, adding 'token' to the array on cod.profile.
And I guess it fixed that problem. But now it fails with this error:
Fatal error: Call to undefined function token_include() in /var/www/conference/web/profiles/cod/modules/token/token.module on line 32
also during the profile installation.
Comment #14
gregglesEaton just committed a fix for http://drupal.org/node/186889 which should alleviate the problem that JackBravo mentioned in comment #13.
So, this should be an issue against whichever profiles don't currently require both pathauto and token (I'm looking at you COD, since JackBravo mentioned it by name). If you use another profile affected by this then lodge an issue for that profile.
Comment #15
gregglesLooking through the COD issue queue I guess that this has been fixed in various other issues and/or is a duplicate of http://drupal.org/node/182226
Comment #16
(not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.
Comment #17
gregglesSo, I'm still not sure how to repeat this bug, but I think it's worth protecting against a bit more.
I wrapped this call in a check for whether the function exists. If not, it just returns an array which will create an ugly alias but hopefully won't create a WSOD.
So, back to "fixed" again.
Comment #18
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.