Friday, August 1, 2008

Err: Error on executing Symfoclipse Commands

Error:

            !ENTRY org.eclipse.ui 4 0 2008-06-17 19:12:57.943
            !MESSAGE Unhandled event loop exception
            !STACK 0
            java.lang.NumberFormatException: For input string: "(C:"
                at sun.misc.FloatingDecimal.readJavaFormatString(Unknown Source)
                at java.lang.Double.valueOf(Unknown Source)
                at cc.noy.eclipse.symfony.popup.actions.SymfonyAction.is1_1(SymfonyAction.java:89)
                at cc.noy.eclipse.symfony.popup.actions.SymfonyClearCacheAction.run(SymfonyClearCacheAction.java:14)
                at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)....... etc


Reason:

 
            Symfoclispe uses the symfony command “symfony -V” to find out the current version of the symfony all the times. But the command return the version with the installed path. So while trying to get the version no from the string could not give the correct version no.

            In that time no command is executed and nothing will be shown in output pane.

Solution:

            Simply edit the file usr/shar/php/symfony/command/sfSymfonyCommandApplication.class.php and change the line

            return sprintf('%s version %s (%s)', $this->getName(), $this->formatter->format($this->getVersion(), 'INFO'), sfConfig::get('sf_symfony_lib_dir'))."\n";

            to

            return sprintf('%s version %s', $this->getName(), $this->formatter->format($this->getVersion(), 'INFO'))."\n";


No comments:

Post a Comment