PDA

View Full Version : Nesting level too deep - recursive dependency? [SOLVED]


anno1986
01-26-2014, 09:32 AM
Hi,

I finally found a fix which seems to solve the issue with
"PHP Fatal error: Nesting level too deep - recursive dependency?".


--- linkedhashmap.php.ORG 2014-01-26 16:30:42.000000000 +0100
+++ linkedhashmap.php 2014-01-26 16:26:52.000000000 +0100
@@ -189,7 +189,7 @@
*/
public function transfer(Arrays $newEntries){
$newCapacity = $newEntries->length();
- for($entry = $this->header->getAfter(); $entry != $this->header; $entry = $entry->getAfter()){
+ for($entry = $this->header->getAfter(); $entry !== $this->header; $entry = $entry->getAfter()){
$index = $this->indexFor($entry->getHash(), $newCapacity);
$entry->setNext($newEntries[$index]);
$newEntries[$index] = $entry;

Hall of Famer
01-27-2014, 01:56 AM
Interesting... So you get it to work by appending an equal sign to the $entry != $this->header line? If so, this may explain why only a small number of people get this error. Changes are they have duplicate items at the dropdown list, but its kinda strange since supposedly every item in dropdown list is unique. I will double-check on that.

anno1986
01-27-2014, 02:46 AM
comparing with twe == will not go thru all its properties as far as i know...

more details I found here: http://www.richardlord.net/blog/php-nesting-level-too-deep-recursive-dependency

Vaporman87
04-07-2014, 01:36 PM
This solution seems to have worked for me as well. Thanks anno1986!

FurryPinups
04-15-2014, 10:54 AM
This worked for me as well. All was going fine until suddenly I couldn't add an Item or a new shop without this error occuring. I added the = sign to the appropriate file and it seems to be working fine now.

Also, I am using version 1.3.4

destrovel
09-05-2014, 04:25 PM
I'm still kinda confused on how to fix this.

I keep getting the following when trying to modify the menu through the admin CP:

Fatal error: Nesting level too deep - recursive dependency? in /home/u110012781/public_html/classes/resource/collection/linkedhashmap.php on line 192

However, I have no clue where I would add in the additional equal sign in the linkedhashmap.php. Anybody who could help me ahead?


Edit: Never mind; figured out what the + / - in front of the lines were supposed to convey :P
I feel stupid now :D

Abronsyth
09-28-2014, 03:29 PM
I am also having this issue, but I don't quite understand how to go about fixing it?

Any advice?

destrovel
09-30-2014, 01:12 PM
In the file that has the issue, find:

for($entry = $this->header->getAfter(); $entry != $this->header; $entry = $entry->getAfter()){

Replace it with:

for($entry = $this->header->getAfter(); $entry !== $this->header; $entry = $entry->getAfter()){

Abronsyth
09-30-2014, 03:09 PM
Awesome, thanks!