Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.10.18

Bug #6675 postinstallscript validation fails
Submitted: 2006-02-02 17:53 UTC
From: hans at velum dot ent Assigned: cellog
Status: No Feedback Package: PEAR (version 1.4.6)
PHP Version: 5.1.2 OS: Gentoo Linux
Roadmaps: (Not assigned)    
Subscription  


 [2006-02-02 17:53 UTC] hans at velum dot ent
Description: ------------ When attempting to install a package that uses <task:postinstallscript> I get errors like this (I'm trying to install Chiara_PEAR_Server): task <tasks:postinstallscript> in file Server/mysqlinstall.php is invalid because of "Post-install script "Server/mysqlinstall.php" must declare exactly 1 class" Parsing of package.xml from file "/tmp/tmpOvtlaj/package.xml" failed Cannot initialize 'Chiara_PEAR_Server-0.18.3.tgz', invalid or missing package file Package "Chiara_PEAR_Server-0.18.3.tgz" is not valid install failed Well, Server/mysqlinstall.php does declare exactly 1 class. This would appear to be a bug in PEAR_Task_Postinstallscript and/or PEAR_PackageFile_v2 (depending on how you look at it). What seems to be the problem: On/around line 82, PEAR_Task_Postinstallscript calls $pkg->analyzeSourceCode($file, true); $file is the contents of the file, not the file _name_ which appears to be what is expected by PEAR_PackageFile_v2.

Comments

 [2006-02-04 02:15 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2006-02-06 21:25 UTC] hans at velum dot ent
When I upgrade PEAR per CVS instructions (which incidentally seem wrong, since 'anoncvs' is not a valid CVS user), I get the same error. Furthermore after the upgrade (which it says was successful), PEAR is still at version 1.4.7.
 [2006-02-07 03:39 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2006-02-07 15:50 UTC] hans at velum dot ent
oh, ok, my apologies. yes, I think this is a differnet type of bug afterall. I am missing the tokenizer and the analyzeSourceCode() in the validator is returning false if the tokenizer is not present. -- It also returns false if it can't open the file, which is I think what made me think it was related to the param type. I see the error of my ways, though, by the if ($string) check :)
 [2006-02-08 01:15 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2006-02-08 01:21 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!