yiic shell problem on pardus

Oh, sorry, didn’t see your checkMethod implementation :)

Hmm. For now i’m running out of ideas. You can still try to user more Reflection features to find out why some of your objects don’t inherit methods from parent classes.

method_exists for setimport returns false and method_exists for setImport returns true but then it is providing the CList error.

in the test class as you see it doesn’t care about upper or lower case.

Did you use the CLI version for your test?


php -f mytestfile.php

yes, the cli version also passed the test and returned true for both.

i guess i should find what’s causing the “Fatal error: Couldn’t find implementation for method CList::getiterator in Unknown on line 0” error and fix it since setImport is found by method_exists().

also, i have used ReflectionClass:getParentClass($this) in __set() method. and i saw the setImport in the result:




/**

         * Sets the aliases that are used in the module.

         * @param array list of aliases to be imported  

         */                                             

    Method [ <user, inherits CModule> public method setImport ] {

      @@ /home/mengu/public_html/yii/framework/base/CModule.php 200 - 204


      - Parameters [1] {

        Parameter #0 [ <required> $aliases ]

      }                                     

    }               



You can’t fix that. As explained above this method is used automatically by PHP whenever you use a CList object in a loop. All your errors basically tell the same: That some method can’t be found which actually is there. Probably due to a case sensitivity bug. So there must be something wrong with your PHP version. Is there a chance you could use another version?

currently i have 5.2.10 and i am downloading 5.3.0 and will create a new package for my distro to be able to use it and then will let you know about the result. thank you for helping me so far. i hope to come of this problem.

also, why would it not show the same error for the test class?

i thought this was a problem caused by my linux distro. however gentoo provides the same error in my first post. but it is tried on php 5.2.10 and i have 5.2.10 too. so it is either php version or bug in yii.

I’m using Gentoo with PHP 5.2.10, too. Never had a problem and neither had others that are running Yii very fine on Gentoo, Ubuntu, Debian, whatever. So no idea, how you manage to get these problems :)

mike,

i’d be glad if you could answer the following questions…

  1. how did you build php?

  2. how did you download yii?

I have this in /etc/portage/package.use:


dev-lang/php calendar cli ctype filter imap json mysql mysqli pdo reflection simplexml soap sqlite tokenizer xmlreader xmlwriter zip



And installed of course with emerge:


emerge php




cd /tmp

wget 'http://www.yiiframework.com/files/yii-1.0.8.tar.gz'

tar xvzf yii-1.0.8.r1317.tar.gz

mv yii-1.0.8.r1317/framework/ /usr/share/php/yii-1.0.8



Then in my applications index.php i simply use:


// require_once('yii-1.0.6/yii.php');

// require_once('yii-1.0.7/yii.php');

require_once('yii-1.0.8/yii.php');



That way i can switch very easily between different Yii versions and only need one central installation for the whole sever.

a friend of mine tried again on gentoo as you explained and he got that error. he has Gentoo Base System release 2.0.1.

hi everyone.

i and the developers of pardus have no idea why this is happening.

however, i was dying to try yii so i switched to ubuntu. now i have shell working as expected.

i’d like to say that i am very thankful to imehesz and mike. thank you guys.

You’re welcome. Please let us know if you should find out what caused the problem.