Skip to content
This repository has been archived by the owner on Nov 24, 2021. It is now read-only.

Building page error #138

Closed
Jbaukens opened this issue Feb 11, 2016 · 17 comments
Closed

Building page error #138

Jbaukens opened this issue Feb 11, 2016 · 17 comments

Comments

@Jbaukens
Copy link
Contributor

hello jan,

Daily we have errors like that and this doesnt matter how many years and how many version of 2moons i used ? can you help me to fix that or atleast say me whats going wrong ? The offset id can change in any id of building thats canceled

[11-Feb-2016 14:00:05] NOTICE: "Undefined offset: 3"
File: /home/admin/web/xterium.space/public_html/includes/pages/game/ShowBuildingsPage.class.php | Line: 103
URL: http://xterium.space/game.php?page=buildings | Version: 1.7.git
USERID: 10775
Stack trace:
#0 /includes/pages/game/ShowBuildingsPage.class.php(103): errorHandler(8, 'Undefined offse...', '/home/admin/web...', 103, Array)
#1 /includes/pages/game/ShowBuildingsPage.class.php(402): ShowBuildingsPage->RemoveBuildingFromQueue(5)
#2 /game.php(79): ShowBuildingsPage->show()
#3 {main}

@penguin1969
Copy link

either you do not have the building id of 3 in the vars.php or you do not have it in the database vars?

@Jbaukens
Copy link
Contributor Author

No i will not open an issue if the answer was that easy penguin
Its totaly not that

Regards

@jkroepke
Copy link
Owner

Try to add a

if (empty($ListIDArray)) continue;

maybe it helps.

@Jbaukens
Copy link
Contributor Author

Sorry my line 103 is not the same as yours as mine is edited
The code that cause the problem is
$Element = $CurrentQueue[$QueueID - 2][0];

@jkroepke
Copy link
Owner

$Element = $CurrentQueue[$QueueID - 2][0];
?

@Jbaukens
Copy link
Contributor Author

thats the line generating the error above yes

@jkroepke
Copy link
Owner

Its always "Undefined offset: 3"?

@Jbaukens
Copy link
Contributor Author

No sometims its 2, sometimes its 5, sometimes its 7, the id is various

Regards

@Jbaukens
Copy link
Contributor Author

Here some new errors that i have some times still the same line as announced (its not the same line as official pack but no modification has been made on this function)

[31-Mar-2016 01:19:47] NOTICE: "Undefined offset: 3"
File: /home/admin/web/xterium.space/public_html/includes/pages/game/ShowBuildingsPage.class.php | Line: 103
URL: http://xterium.space/game.php?page=buildings | Version: 1.7.git
USERID: silver2004
Stack trace:
#0 /includes/pages/game/ShowBuildingsPage.class.php(103): errorHandler(8, 'Undefined offse...', '/home/admin/web...', 103, Array)
#1 /includes/pages/game/ShowBuildingsPage.class.php(413): ShowBuildingsPage->RemoveBuildingFromQueue(5)
#2 /game.php(79): ShowBuildingsPage->show()
#3 {main}

[31-Mar-2016 04:43:50] NOTICE: "Undefined offset: 2"
File: /home/admin/web/xterium.space/public_html/includes/pages/game/ShowBuildingsPage.class.php | Line: 103
URL: http://xterium.space/game.php?page=buildings | Version: 1.7.git
USERID: Agapornis
Stack trace:
#0 /includes/pages/game/ShowBuildingsPage.class.php(103): errorHandler(8, 'Undefined offse...', '/home/admin/web...', 103, Array)
#1 /includes/pages/game/ShowBuildingsPage.class.php(413): ShowBuildingsPage->RemoveBuildingFromQueue(4)
#2 /game.php(79): ShowBuildingsPage->show()
#3 {main}

[31-Mar-2016 04:43:51] NOTICE: "Undefined offset: 3"
File: /home/admin/web/xterium.space/public_html/includes/pages/game/ShowBuildingsPage.class.php | Line: 103
URL: http://xterium.space/game.php?page=buildings | Version: 1.7.git
USERID: Agapornis
Stack trace:
#0 /includes/pages/game/ShowBuildingsPage.class.php(103): errorHandler(8, 'Undefined offse...', '/home/admin/web...', 103, Array)
#1 /includes/pages/game/ShowBuildingsPage.class.php(413): ShowBuildingsPage->RemoveBuildingFromQueue(5)
#2 /game.php(79): ShowBuildingsPage->show()
#3 {main}

@jkroepke
Copy link
Owner

Is this still valid?

@Jbaukens
Copy link
Contributor Author

For me it is yes i never really found the cause of this anyway it doesnt really affect the game but would allways be better to have a non bugged one :P

jkroepke added a commit that referenced this issue Apr 26, 2016
@jkroepke
Copy link
Owner

I added some extra debug (on a extra branch). See linked commit.

You should be integrate this and report it, if it happends again.

@Jbaukens
Copy link
Contributor Author

Hello thanks i will add it in the evening and will keep u updated
Regards

@Jbaukens
Copy link
Contributor Author

Hello not sure it will help as it does not provide more information

[19-May-2016 22:14:04] USER ERROR: "Issue #138 triggered:

"
File: /home/xterium/public_html/includes/pages/game/ShowBuildingsPage.class.php | Line: 104
URL: http://xterium.space/game.php?page=buildings | Version: 1.7.git
USERID: Oturanboga
Stack trace:
#0 /includes/pages/game/ShowBuildingsPage.class.php(417): ShowBuildingsPage->RemoveBuildingFromQueue(4)
#1 /game.php(79): ShowBuildingsPage->show()
#2 {main}

jkroepke added a commit that referenced this issue May 19, 2016
@jkroepke
Copy link
Owner

I added an updated version.

@Jbaukens
Copy link
Contributor Author

Jbaukens commented May 20, 2016

Here is my updated error log then
can you also review my moondestruction u closed yesterday, i dont think you read all of it as you did a mistake in your response

[20-May-2016 15:22:20] USER ERROR: "Issue #138 triggered:

int(2)
int(4)
string(143) "a:2:{i:0;a:5:{i:0;i:24;i:1;i:4;i:2;d:6;i:3;d:1463750546;i:4;s:5:"build";}i:1;a:5:{i:0;i:24;i:1;i:5;i:2;d:26;i:3;d:1463750582;i:4;s:5:"build";}}"
array(2) {
[0]=>
array(5) {
[0]=>
int(24)
[1]=>
int(4)
[2]=>
float(6)
[3]=>
float(1463750546)
[4]=>
string(5) "build"
}
[1]=>
array(5) {
[0]=>
int(24)
[1]=>
int(5)
[2]=>
float(26)
[3]=>
float(1463750582)
[4]=>
string(5) "build"
}
}
"
File: /home/xterium/public_html/includes/pages/game/ShowBuildingsPage.class.php | Line: 108
URL: http://xterium.space/game.php?page=buildings | Version: 1.7.git
USERID: dragon09
Stack trace:
#0 /includes/pages/game/ShowBuildingsPage.class.php(421): ShowBuildingsPage->RemoveBuildingFromQueue(4)
#1 /game.php(79): ShowBuildingsPage->show()
#2 {main}

@jkroepke
Copy link
Owner

Thanks. It looks like someone click multiple times. This error appears, if user wann to remove queue id 4, but there is just 1 and 2

jkroepke pushed a commit that referenced this issue Aug 18, 2019
Market: Custom ratio with JS
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants