First of all there are syntax errors in both of the contrib modules (even, i18n) - the if patterns start with : instead of { but end with } instead of endif;
The after installing i got a missed function error regarding some toke function i could not remember. After complete deinstalling of the pathauto module this was gone. Now when i go to the settings page i get a few errors which get even more when trying to update the settings:
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto_user.inc on line 63.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto_user.inc on line 16.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto.module on line 194.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto.module on line 194.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto_user.inc on line 63.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto_user.inc on line 16.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto.module on line 194.
* warning: Invalid argument supplied for foreach() in /.../modules/pathauto/pathauto.module on line 194.
(i just removed parts of the path and substituted it with...)
Comment | File | Size | Author |
---|---|---|---|
#16 | token_includes.patch | 2.36 KB | greggles |
#8 | node_i18n.patch | 714 bytes | fhelmschrott |
#7 | node_event.patch | 966 bytes | fhelmschrott |
Comments
Comment #1
gregglesThanks for testing the 5.x-2 version of pathauto which is not stable, but does need help testing.
I committed those contrib files without much testing (as you can see) so I will need to fix them soon.
Can you provide the fix to the syntax problem you found as a patch? http://drupal.org/patch/create
Comment #2
fhelmschrott CreditAttribution: fhelmschrott commentednote that the second (bigger) problem doesn't have to do with the contrib files. Will try my best with the patch but as i didn't do it before it would surely take some time. Probably it would be better if you fix the two lines yourself.
Comment #3
gregglesOk, I fixed those typos. It's a great practice to create/submit patches for issues when you know the solution. It doesn't take much more time and is very helpful to other users.
I'm unable to repeat the problem that you mentioned on the settings page. Can you try uninstalling pathauto (from admin/build/modules/uninstall ) and then reinstall it and see if it works? Is that what you already did? If so can you try installing it on a second (test) site to see if the problem still occurs?
Thanks.
Comment #4
fhelmschrott CreditAttribution: fhelmschrott commenteduninstalling and reinstalling was what i already did and didn't bring up any changes. I'll try to install another D5-instance today and install it there once more. Will report later.
Comment #5
gregglesfhelmschrott - in irc today dldedge confirmed this issue, so I must be missing something. I'll do a clean/install checkout myself to confirm this.
Thanks.
Comment #6
fhelmschrott CreditAttribution: fhelmschrott commentedi just also did a clean install. The problem seems to be within / in the use of the tokens. function token_get_list() seems to return inappropiate values sometimes.
in pathauto_users e.g. the array $patterns which is filled by the function doesn't contain an array 'user'. Also token_get_list('taxonomy'); and token_get_list('node'); return the same content. unfortunately i'm not the big coder so i couldn't find the problem myself but hopefully my findings will help you.
Comment #7
fhelmschrott CreditAttribution: fhelmschrott commentedI did my first diff try today and built the 2 patches for the contrib modules. please doublecheck them. Next time i'll try cvsdiff then.
Comment #8
fhelmschrott CreditAttribution: fhelmschrott commentedlooks like i cannot attach archives so another post required for the second one.
Comment #9
gregglesWell, I just did some testing and still cannot get the "invalid argument supplied foreach" problem, so I'm really confused. I'll try one more time tonight.
I already patched the two inc files in contrib, though I appreciate you providing the patch. In general they look fine.
Comment #10
gregglesI think I got it!!!
Ok, to use Pathauto 5.x-2 you need to use the latest code in token module . I'm doing that, but I imagine that you are using Token 5.x-1.6. That won't work :(
Can you try again with a checkout of the Token module from cvs?
You can get the code with this command:
cvs -d :pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal-contrib co -r DRUPAL-5 contributions/modules/token
Comment #11
gregglesIn a couple minutes there will be a new official release of token at http://drupal.org/node/140568
When that node is publicly available you'll be able to get the right file directly yourselves and it should work :)
Let me know if you still have problems after that.
Thanks.
Comment #12
fhelmschrott CreditAttribution: fhelmschrott commentedunfortunately this doesn't change anything. i completely uninstalled pathauto and token and reinstalled both (token first). I stillt get the same errors:
* warning: Invalid argument supplied for foreach() in /net/web/_local/ss/htdocs/modules/pathauto/pathauto_user.inc on line 63.
* warning: Invalid argument supplied for foreach() in /net/web/_local/ss/htdocs/modules/pathauto/pathauto_user.inc on line 16.
* warning: Invalid argument supplied for foreach() in /net/web/_local/ss/htdocs/modules/pathauto/pathauto.module on line 194.
* warning: Invalid argument supplied for foreach() in /net/web/_local/ss/htdocs/modules/pathauto/pathauto.module on line 194.
Comment #13
yettyn CreditAttribution: yettyn commentedHi,
the problem seam to still be there, got this above General Settings when clicking Pathauto in siteconfiguration
using pathauto 5.x-2.x-dev dated 20 march and token 1 May release.
Y
Comment #14
yettyn CreditAttribution: yettyn commentedcorrection, pathauto is the latest of course as I downloaded it today :-) 20 march was just the initial release.
Comment #15
fhelmschrott CreditAttribution: fhelmschrott commentedthe errors still appear but it seems to work now. I just did some testing and it saves the values. The errors seem to come from the description part where the single fields get described beneath each of the forms.
btw: pathauto makes '039' out of a single quote '. is this intentionally or can it be changed?
Comment #16
gregglesOk, now I really think I've got it...
I don't know why it was working OK for me for a while, but I finally was able to reproduce the bug and figured out that it's because pathauto calls token_get_list directly which doesn't include the token_user.inc, for example.
Here is a patch which will include the necessary files in either theme_token_help or token_get_list - whichever is called. I separated out the include code into a separate function so that I'm not pulling the old "copy past antipattern" ;)
Testing and reviews welcome.
Comment #17
yettyn CreditAttribution: yettyn commentedApplied your patch and now I get:
maybe something needs to be done in pathauto as well? I'm no php pro so can't really tell.
Comment #18
gregglesMaybe I'm crazy - but the other night I had a similar problem on a test site where I was running postgresql. Is anyone who gets these errors running postgres? As I said, it could have just been a really confused installation on my part...
Comment #19
yettyn CreditAttribution: yettyn commentedmysql 4.1.22, sorry ;-)
Comment #20
fhelmschrott CreditAttribution: fhelmschrott commentedjust wanted to let you know it seems to work after applying the patch. Great work - thanks ;)
Comment #21
David N CreditAttribution: David N commentedI'm getting the same errors as post #13, on lines 16 and 194. Using current Token (May 1) and Pathauto releases.
Comment #22
gregglesI had a small problem with the patch, but I committed this to help people test pathauto5.x-2.
Once the tarball gets rerolled it should be working reasonably well.
Comment #23
Christefano-oldaccount CreditAttribution: Christefano-oldaccount commentedIs this issue really closed? I'm having the same errors with token with this patch listed at #16 with pathauto 2-dev.
Comment #24
greggles@christefano - currently this is only checked into the 5.x-dev version of Token. Did you get your token tarball from http://drupal.org/node/143907 ?
Comment #25
fhelmschrott CreditAttribution: fhelmschrott commentedjust to let you know - the latest dev-version of token still doesn't include that patch. i still got the errors installing from the latest dev-version. After applying the token_include.patch everything's working fine.
Comment #26
(not verified) CreditAttribution: commented