VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: RJF001 on December 22, 2013, 21:48:54 PM

Title: White screen of death when user tries registering with existing details.
Post by: RJF001 on December 22, 2013, 21:48:54 PM
I'm not entirely sure if this is a bug, so apologies if this is in the wrong section.

Basically, I've got a new shop nearly ready to go live and I've been testing it to see if anything breaks. I've found an error where if a user tries registering with the same details of an existing user it generates the dreaded WSOD.

The error log is as follows:

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP Fatal error:  Maximum function nesting level of '100' reached, aborting! in C:\\wamp\\www\\********\\libraries\\loader.php on line 366, referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP Stack trace:, referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   1. {main}() C:\\wamp\\www\\********\\index.php:0,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   2. JSite->dispatch() C:\\wamp\\www\\********\\index.php:42,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   3. JComponentHelper::renderComponent() C:\\wamp\\www\\********\\includes\\application.php:197,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   4. JComponentHelper::executeComponent() C:\\wamp\\www\\********\\libraries\\joomla\\application\\component\helper.php:351,
referer:http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   5. require_once() C:\\wamp\\www\\********\\libraries\\joomla\\application\\component\\helper.php:383,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   6. JController->execute() C:\\wamp\\www\\********\\components\\com_virtuemart\\virtuemart.php:100,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   7. VirtueMartControllerUser->saveUser() C:\\wamp\\www\\********\\libraries\\joomla\\application\\component\\controller.php:761,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   8. VirtueMartControllerUser->saveData() C:\\wamp\\www\\********\\components\\com_virtuemart\\controllers\\user.php:166,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP   9. VirtueMartModelUser->store() C:\\wamp\\www\\********\\components\\com_virtuemart\\controllers\\user.php:218,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP  10. vmError() C:\\wamp\\www\\********\\administrator\\components\\com_virtuemart\\models\\user.php:651,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP  11. logInfo() C:\\wamp\\www\\********\\administrator\\components\\com_virtuemart\\helpers\\config.php:207,
referer: http://localhost/********/index.php/sign-in-register/component/users/

[Sun Dec 22 16:18:13 2013] [error] [client 127.0.0.1] PHP  12. vmError() C:\\wamp\\www\\********\\administrator\\components\\com_virtuemart\\helpers\\config.php:395,
referer:http://localhost/********/index.php/sign-in-register/component/users/


Lines 11 and 12 repeat until the trace runs out of reporting space.

I'm running VM 2.0.26a and J 2.5.17 on WAMP server, details: PHP 5.3.13; Apache 2.2.22; MySQL 5.5.24, although I've tried it on a live test site and the same thing occurs. Also, the site is going to run a custom template but I've gone back to Beez and again it still occurs.

I've searched through this forum and can't a solution. This is my first Virtuemart attempt and the only major issue I've encountered so if anyone can point me in the right direction or explain where I've gone wrong, I'll be truly grateful.

Thanks,

RJF.
Title: Re: White screen of death when user tries registering with existing details.
Post by: Milbo on December 23, 2013, 11:05:09 AM
Hello RJF001
welcome in our forum


C:\\wamp\\www\\********\\libraries\\joomla\\application\\component\\controller.php:761,


Looks like there is an error with your directory seperator. The file is also a joomla file. Please create a joomla registration page (not the one of vm) and try there. Maybe it is a joomla error.
Title: Re: White screen of death when user tries registering with existing details.
Post by: RJF001 on December 24, 2013, 12:53:19 PM
Thank you for the quick reply.

I've tried Joomla's own registration form and it appears to work correctly, i.e. it returns an error message stating the credentials are already n use by another user.

When I have time I will test both registration forms and see if I can work out why one works and the other doesn't. I haven't yet rigourously tested or dissected the VM registration form due to time constraints. My first thought is to unpublish the extra fields compared with the Joomla form and work from there.

If I find what the problem is and/or a solution, I will post it here in case anyone else runs into a similar problem.

Regarding the separator issue, that is just how Wamp server formats it's error logs (I c&p'd) rather than anything connected with Joolma.

Thank you,

RJF.

Title: Re: White screen of death when user tries registering with existing details.
Post by: mbarry on January 15, 2014, 15:23:04 PM
Hi RJF001,
I was just going to report a similar bug to this, i.e. the Maximum function nesting level of '100' reached, aborting!.

After a false migration start nearly two years ago, I have decided to give it another go now that there are many more plugins available.

I have just been through almost a month of effort to migrate my partners website from VM 1.1.9 to VM 2.0.26a and and J1.5.25 to J2.5.17 and have extensively documented all my bug fixes, code changes and the process to perform the migration. I plan to post all of this in the next few days.  However, this issue is fundamental and needs to be fixed to allow correct error reporting.

Scenario:
      Virtuemart reports errors via vmError() as part of the Migration process, vmError() also calls logInfo()
 
Issue:
      logInfo() checks if the log folder exists. If not, it will create the folder structure but never creates the log file. The follow on lines check for the existence of the log file and reports an error that the logfile does not exist by calling vmError().
      This results in an endless nested loop reporting the error vmError('Could not use path '.$file.' to store log') until PHP hits the nested limit.
     
      In this case the logfile to be created was com_virtuemart.log.php

Solution:
      Create the log file as part of the check for the existance of the logfile and log directory
     
      Insert after line 378
        // create log file then close it
          $fp = fopen ($file, 'a');
          fclose ($fp);
       
Affected files:
      administrator/components/com_virtuemart/helpers/config.php  Line 378
Title: Re: White screen of death when user tries registering with existing details.
Post by: RJF001 on January 15, 2014, 15:50:41 PM
Hi mbarry,

Thanks for posting that, it has saved me a lot of time and hassle. I had'nt even found the time to go back and look at it yet!

RJF.
Title: Re: White screen of death when user tries registering with existing details.
Post by: mbarry on January 15, 2014, 15:59:07 PM
No problem.

Keep a look out for my other posts under Installation, Migration and Upgrade VM 2.
Title: Re: White screen of death when user tries registering with existing details.
Post by: Milbo on January 15, 2014, 16:09:06 PM
The solution is in vm2.0.26c, just load the vm2.0.26D version.