Re: [fw-general] Zend_Loader_PluginLoader problems - fix found?

2008-10-09 Thread Taco Jung
Matthew,

Yup, fixed.

Regards, TJ.


On Thu, Oct 9, 2008 at 4:06 PM, Bart McLeod <[EMAIL PROTECTED]> wrote:

>  tested, fix comfirmed.
>
> What a speed! Thanks,
>
> Bart
>
> Matthew Weier O'Phinney schreef:
>
> -- Bart McLeod <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> wrote
> (on Thursday, 09 October 2008, 02:58 PM +0200):
>
>
>  and now with improved regex:
> //pluginloader.php line 374
> foreach ($paths as $key => $path) {
> if (preg_match('/^[a-z0-9_](?!(:\/))(?!:' . preg_quote('\\') .
> ')/i', $path)) {//works for windows paths too, like E:\myapp\etc
>
>
>  Awesome sleuthing! and I see exactly what failed in my original regex as
> well. Applied and committed to svn; please test!
>
>
>
>  foreach ($incPaths as $index => $incPath) {
> $incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
> }
> unset($paths[$key]);
> }
> }
>
> Bart
>
> Bart McLeod schreef:
>
> Think I found it (at least a quick fix that works, but you will probably
> have to fix the regex and add an else statement:
> //line 374 in pluginloader.php
> foreach ($paths as $key => $path) {
> if (preg_match('/^[a-z0-9_](?!:' . preg_quote('\\') . ')/
> i', $path)) {
> foreach ($incPaths as $index => $incPath) {
> $incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
> }
> //unset($paths[$key]);//I commented this line to keep
> the paths that I have set for specific keys that go wrong, provides a 
> quick
> fix
> }
> }
>
> Bart
>
> Matthew Weier O'Phinney schreef:
>
> -- Bart McLeod <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> wrote
> (on Wednesday, 08 October 2008, 12:10 PM +0200):
>
>
> This is what I get with 11666:
> Fatal error: Uncaught exception 
> 'Zend_Loader_PluginLoader_Exception' with
> message 'Plugin by name CmsScripts was not found in the registry; 
> paths
> searched: array ( 'Admin_View_Helper_' => array ( 0 => 
> 'D:/werkmap/
> www.houthandelwijers.nl zf/application/admin/views\\helpers/', ),
> 'Zend_View_Helper_' => array ( 0 => 'Zend/View/Helper/', ), ) 
> Original
> include_path: .;C:\Program 
> Files\PHP\pear;c:\php\includes;c:\php\PEAR\;c:\php;
> D:\ZendFramework\library' in D:\ZendFramework\library\Zend\Loader\
> PluginLoader.php:404 Stack trace: #0 
> D:\ZendFramework\library\Zend\View\
> Abstract.php(1114): Zend_Loader_PluginLoader->load('CmsScripts') 
> #1 D:\
> ZendFramework\library\Zend\View\Abstract.php(545): 
> Zend_View_Abstract->
> _getPlugin('helper', 'cmsScripts') #2 
> D:\ZendFramework\library\Zend\View\
> Abstract.php(312): Zend_View_Abstract->getHelper('cmsScripts') #3 
> [internal
> function]: Zend_View_Abstract->__call('cmsScripts', Array) #4 
> D:\ZendFramework\
> library\SpaceCMS\ActionController.php(44): 
> Zend_View->cmsScripts() #5 D:\ZendFr
> in D:\ZendFramework\library\Zend\Loader\PluginLoader.php on line 
> 404
>
> So I'll just revert back to 10753 for now! :-)
>
>
>
> Okay, so it's still an issue on Windows, then. I'll keep digging.
>
>
>
>
> Matthew Weier O'Phinney schreef:
>
> -- Bart McLeod <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> wrote
> (on Wednesday, 08 October 2008, 11:17 AM +0200):
>
>
> I updated the Loader dir to 10753 and it works again now. 
> Revision 11629 is the
> one that broke it.
>
>
>
> That makes sense -- I made changes as of r11666 that should 
> have fixed
> it.
>
>
>
>
> Matthew Weier O'Phinney schreef:
>
> -- Bart McLeod <[EMAIL PROTECTED]> <[EMAIL 
> PROTECTED]> wrote
> (on Monday, 06 October 2008, 09:10 PM +0200):
>
>
> Hi all,
>
> I had similar problems today with my custom view 
> helpers. They are in
> the location where ZF is looking for them, but it 
> can't load them. I
> thought I sent a mail to the list about it, but 
> it probably got rejected.
>
> The only thing I could think of is the directory 
> separator... I can see
> you are on windows too. In my case, everything 
> worked before and now
> nothing does, because the helpers aren't found by 
> the plugin loader.
>
>
>
> I'm pretty certain it's an OS-dependent bug, and will 
> be working when I
> can to fix this the next few days.
>
>
>
>
> 

Re: [fw-general] Zend_Loader_PluginLoader problems - fix found?

2008-10-09 Thread Bart McLeod

tested, fix comfirmed.

What a speed! Thanks,
Bart

Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Thursday, 09 October 2008, 02:58 PM +0200):
  

and now with improved regex:
//pluginloader.php line 374
foreach ($paths as $key => $path) {
if (preg_match('/^[a-z0-9_](?!(:\/))(?!:' . preg_quote('\\') .
')/i', $path)) {//works for windows paths too, like E:\myapp\etc



Awesome sleuthing! and I see exactly what failed in my original regex as
well. Applied and committed to svn; please test!

  

foreach ($incPaths as $index => $incPath) {
$incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
}
unset($paths[$key]);
}
}

Bart

Bart McLeod schreef:

Think I found it (at least a quick fix that works, but you will probably
have to fix the regex and add an else statement:
//line 374 in pluginloader.php
foreach ($paths as $key => $path) {
if (preg_match('/^[a-z0-9_](?!:' . preg_quote('\\') . ')/
i', $path)) {
foreach ($incPaths as $index => $incPath) {
$incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
}
//unset($paths[$key]);//I commented this line to keep
the paths that I have set for specific keys that go wrong, provides a quick
fix
}
}

Bart

Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Wednesday, 08 October 2008, 12:10 PM +0200):


This is what I get with 11666:
Fatal error: Uncaught exception 
'Zend_Loader_PluginLoader_Exception' with
message 'Plugin by name CmsScripts was not found in the registry; 
paths
searched: array ( 'Admin_View_Helper_' => array ( 0 => 'D:/werkmap/
www.houthandelwijers.nl zf/application/admin/views\\helpers/', ),
'Zend_View_Helper_' => array ( 0 => 'Zend/View/Helper/', ), ) 
Original
include_path: .;C:\Program 
Files\PHP\pear;c:\php\includes;c:\php\PEAR\;c:\php;
D:\ZendFramework\library' in D:\ZendFramework\library\Zend\Loader\
PluginLoader.php:404 Stack trace: #0 
D:\ZendFramework\library\Zend\View\
Abstract.php(1114): Zend_Loader_PluginLoader->load('CmsScripts') #1 
D:\
ZendFramework\library\Zend\View\Abstract.php(545): 
Zend_View_Abstract->
_getPlugin('helper', 'cmsScripts') #2 
D:\ZendFramework\library\Zend\View\
Abstract.php(312): Zend_View_Abstract->getHelper('cmsScripts') #3 
[internal
function]: Zend_View_Abstract->__call('cmsScripts', Array) #4 
D:\ZendFramework\
library\SpaceCMS\ActionController.php(44): Zend_View->cmsScripts() 
#5 D:\ZendFr
in D:\ZendFramework\library\Zend\Loader\PluginLoader.php on line 404

So I'll just revert back to 10753 for now! :-)



Okay, so it's still an issue on Windows, then. I'll keep digging.




Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Wednesday, 08 October 2008, 11:17 AM +0200):


I updated the Loader dir to 10753 and it works again now. 
Revision 11629 is the
one that broke it.



That makes sense -- I made changes as of r11666 that should 
have fixed
it.




Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Monday, 06 October 2008, 09:10 PM +0200):


Hi all,

I had similar problems today with my custom view 
helpers. They are in
the location where ZF is looking for them, but it 
can't load them. I
thought I sent a mail to the list about it, but it 
probably got rejected.

The only thing I could think of is the directory 
separator... I can see
you are on windows too. In my case, everything 
worked before and now
nothing does, because the helpers aren't found by 
the plugin loader.



I'm pretty certain it's an OS-dependent bug, and will 
be working when I
can to fix this the next few days.




The loader works by adding to the include path the 
directories required...

Bart

Codiac schreef:


Matthew,

It's probably my setup but I'm still 
experiencing problems. I'm not using
the incubator and I'm trying to load the 
Zend_View_Helper_Translate. It
 

Re: [fw-general] Zend_Loader_PluginLoader problems - fix found?

2008-10-09 Thread Matthew Weier O'Phinney
-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Thursday, 09 October 2008, 02:58 PM +0200):
> and now with improved regex:
> //pluginloader.php line 374
> foreach ($paths as $key => $path) {
> if (preg_match('/^[a-z0-9_](?!(:\/))(?!:' . preg_quote('\\') .
> ')/i', $path)) {//works for windows paths too, like E:\myapp\etc

Awesome sleuthing! and I see exactly what failed in my original regex as
well. Applied and committed to svn; please test!

> foreach ($incPaths as $index => $incPath) {
> $incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
> }
> unset($paths[$key]);
> }
> }
> 
> Bart
> 
> Bart McLeod schreef:
> 
> Think I found it (at least a quick fix that works, but you will probably
> have to fix the regex and add an else statement:
> //line 374 in pluginloader.php
> foreach ($paths as $key => $path) {
> if (preg_match('/^[a-z0-9_](?!:' . preg_quote('\\') . ')/
> i', $path)) {
> foreach ($incPaths as $index => $incPath) {
> $incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
> }
> //unset($paths[$key]);//I commented this line to keep
> the paths that I have set for specific keys that go wrong, provides a 
> quick
> fix
> }
> }
> 
> Bart
> 
> Matthew Weier O'Phinney schreef:
> 
> -- Bart McLeod <[EMAIL PROTECTED]> wrote
> (on Wednesday, 08 October 2008, 12:10 PM +0200):
> 
> 
> This is what I get with 11666:
> Fatal error: Uncaught exception 
> 'Zend_Loader_PluginLoader_Exception' with
> message 'Plugin by name CmsScripts was not found in the registry; 
> paths
> searched: array ( 'Admin_View_Helper_' => array ( 0 => 
> 'D:/werkmap/
> www.houthandelwijers.nl zf/application/admin/views\\helpers/', ),
> 'Zend_View_Helper_' => array ( 0 => 'Zend/View/Helper/', ), ) 
> Original
> include_path: .;C:\Program 
> Files\PHP\pear;c:\php\includes;c:\php\PEAR\;c:\php;
> D:\ZendFramework\library' in D:\ZendFramework\library\Zend\Loader\
> PluginLoader.php:404 Stack trace: #0 
> D:\ZendFramework\library\Zend\View\
> Abstract.php(1114): Zend_Loader_PluginLoader->load('CmsScripts') 
> #1 D:\
> ZendFramework\library\Zend\View\Abstract.php(545): 
> Zend_View_Abstract->
> _getPlugin('helper', 'cmsScripts') #2 
> D:\ZendFramework\library\Zend\View\
> Abstract.php(312): Zend_View_Abstract->getHelper('cmsScripts') #3 
> [internal
> function]: Zend_View_Abstract->__call('cmsScripts', Array) #4 
> D:\ZendFramework\
> library\SpaceCMS\ActionController.php(44): 
> Zend_View->cmsScripts() #5 D:\ZendFr
> in D:\ZendFramework\library\Zend\Loader\PluginLoader.php on line 
> 404
> 
> So I'll just revert back to 10753 for now! :-)
> 
> 
> 
> Okay, so it's still an issue on Windows, then. I'll keep digging.
> 
> 
> 
> 
> Matthew Weier O'Phinney schreef:
> 
> -- Bart McLeod <[EMAIL PROTECTED]> wrote
> (on Wednesday, 08 October 2008, 11:17 AM +0200):
> 
> 
> I updated the Loader dir to 10753 and it works again now. 
> Revision 11629 is the
> one that broke it.
> 
> 
> 
> That makes sense -- I made changes as of r11666 that should 
> have fixed
> it.
> 
> 
> 
> 
> Matthew Weier O'Phinney schreef:
> 
> -- Bart McLeod <[EMAIL PROTECTED]> wrote
> (on Monday, 06 October 2008, 09:10 PM +0200):
> 
> 
> Hi all,
> 
> I had similar problems today with my custom view 
> helpers. They are in
> the location where ZF is looking for them, but it 
> can't load them. I
> thought I sent a mail to the list about it, but 
> it probably got rejected.
> 
> The only thing I could think of is the directory 
> separator... I can see
> you are on windows too. In my case, everything 
> worked before and now
> nothing does, because the helpers aren't found by 
> the plugin loader.
> 
> 
> 
> I'm pretty certain it's an OS-dependent bug, and will 
> be working when I
> can to fix this the next few days.
> 
> 
> 
> 
> The loader works by adding to the include path 
> the directories required...
> 
> Bart
> 
> Codiac schreef:
> 
> 
> Matthew,
> 
> It'

Re: [fw-general] Zend_Loader_PluginLoader problems - fix found?

2008-10-09 Thread Bart McLeod

and now with improved regex:
//pluginloader.php line 374
   foreach ($paths as $key => $path) {
   if (preg_match('/^[a-z0-9_](?!(:\/))(?!:' . 
preg_quote('\\') . ')/i', $path)) {//works for windows paths too, like 
E:\myapp\etc

   foreach ($incPaths as $index => $incPath) {
   $incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
   }
   unset($paths[$key]);
   }
   }

Bart

Bart McLeod schreef:
Think I found it (at least a quick fix that works, but you will 
probably have to fix the regex and add an else statement:

//line 374 in pluginloader.php
foreach ($paths as $key => $path) {
if (preg_match('/^[a-z0-9_](?!:' . preg_quote('\\') . 
')/i', $path)) {

foreach ($incPaths as $index => $incPath) {
$incPaths[$index] .= DIRECTORY_SEPARATOR . $path;
}
//unset($paths[$key]);//I commented this line to 
keep the paths that I have set for specific keys that go wrong, 
provides a quick fix

}
}

Bart

Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Wednesday, 08 October 2008, 12:10 PM +0200):
  

This is what I get with 11666:
Fatal error: Uncaught exception 'Zend_Loader_PluginLoader_Exception' with
message 'Plugin by name CmsScripts was not found in the registry; paths
searched: array ( 'Admin_View_Helper_' => array ( 0 => 'D:/werkmap/
www.houthandelwijers.nl zf/application/admin/views\\helpers/', ),
'Zend_View_Helper_' => array ( 0 => 'Zend/View/Helper/', ), ) Original
include_path: .;C:\Program Files\PHP\pear;c:\php\includes;c:\php\PEAR\;c:\php;
D:\ZendFramework\library' in D:\ZendFramework\library\Zend\Loader\
PluginLoader.php:404 Stack trace: #0 D:\ZendFramework\library\Zend\View\
Abstract.php(1114): Zend_Loader_PluginLoader->load('CmsScripts') #1 D:\
ZendFramework\library\Zend\View\Abstract.php(545): Zend_View_Abstract->
_getPlugin('helper', 'cmsScripts') #2 D:\ZendFramework\library\Zend\View\
Abstract.php(312): Zend_View_Abstract->getHelper('cmsScripts') #3 [internal
function]: Zend_View_Abstract->__call('cmsScripts', Array) #4 D:\ZendFramework\
library\SpaceCMS\ActionController.php(44): Zend_View->cmsScripts() #5 D:\ZendFr
in D:\ZendFramework\library\Zend\Loader\PluginLoader.php on line 404

So I'll just revert back to 10753 for now! :-)



Okay, so it's still an issue on Windows, then. I'll keep digging.


  

Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Wednesday, 08 October 2008, 11:17 AM +0200):


I updated the Loader dir to 10753 and it works again now. Revision 
11629 is the
one that broke it.



That makes sense -- I made changes as of r11666 that should have fixed
it.




Matthew Weier O'Phinney schreef:

-- Bart McLeod <[EMAIL PROTECTED]> wrote
(on Monday, 06 October 2008, 09:10 PM +0200):


Hi all,

I had similar problems today with my custom view helpers. They 
are in
the location where ZF is looking for them, but it can't load 
them. I
thought I sent a mail to the list about it, but it probably got 
rejected.

The only thing I could think of is the directory separator... I 
can see
you are on windows too. In my case, everything worked before 
and now
nothing does, because the helpers aren't found by the plugin 
loader.



I'm pretty certain it's an OS-dependent bug, and will be working 
when I
can to fix this the next few days.




The loader works by adding to the include path the directories 
required...

Bart

Codiac schreef:


Matthew,

It's probably my setup but I'm still experiencing problems. 
I'm not using
the incubator and I'm trying to load the 
Zend_View_Helper_Translate. It
works fine for the login page, but after that it somehow 
goes wrong. Here's
a little more info.

#0 C:\Documents and Settings\Mijn 
documenten\Projecten\Workspace\Zend
Framework (Core)\library\Zend\View\Abstract.php(1114):
Zend_Loader_PluginLoader->load('Translate')
#1 C:\Documents and Settings\Mijn 
documenten\Projecten\Workspace\Zend
Framework (Core)\library\Zend\View\Abstract.php(545):
Zend_View_Abstract->_getPlugin('helper', 'translate')
#2 C:\Documents and Settings\Mijn 
documenten\Projecten\Workspace\Zend
Framework (Core)\library\Zend\View\Abstract.php(312):
Zend_View_Abstract->getHelper('translate')
#3 [internal function]: 
Zend_View_Abstract->__call('transl