View Issue Details

IDProjectCategoryView StatusLast Update
0003772Spring engineGeneralpublic2013-05-05 13:05
ReporterGoogle_Frog Assigned ToKloot  
PrioritynormalSeveritymajorReproducibilityhave not tried
Status closedResolutionno change required 
Product Version94.1.1+git 
Summary0003772: (94.1.1-404-g363d135) Hang with CAI
DescriptionI had a hang with ZK. No replay or infolog exists (thanks buffering!). On Comet Catcher Redux with 2 CAIs.
TagsNo tags attached.
Attached Files
infolog_405_1_hang.txt (Attachment missing)
Checked infolog.txt for Errors

Activities

Google_Frog

2013-05-04 10:51

reporter   ~0010612

Hanging in this situation is now 2 for 2. This time with 94.1.1-405-g9fd3de8. An infolog exists for this one! infolog_405_1_hang

abma

2013-05-04 20:18

administrator   ~0010616

translated: http://paste.springfiles.com/view/577342d0

abma

2013-05-04 20:19

administrator   ~0010617

Last edited: 2013-05-04 20:21

LuaSyncedRead.cpp:4881 ->

int LuaSyncedRead::TestBuildOrder(lua_State* L)

https://github.com/spring/spring/blob/94.1.1-404-g363d135/rts/Lua/LuaSyncedRead.cpp#L4881

Kloot

2013-05-04 21:00

developer   ~0010619

CGameHelper::TestUnitBuildSquare cannot loop forever unless the input was bad.

abma

2013-05-04 21:03

administrator   ~0010620

Last edited: 2013-05-04 21:06

got a hang, too: (hangs at game start!)

(gdb) bt
#0 0x0000000000572956 in CGameHelper::GetBuildHeight (pos=..., unitdef=0xc261600, synced=true)
    at rts/Game/GameHelper.cpp:1034
#1 0x0000000000572c72 in CGameHelper::TestUnitBuildSquare (buildInfo=..., feature=
    @0x7fffffffc1e0: 0x0, allyteam=-2, synced=true, canbuildpos=0x0, featurepos=0x0,
    nobuildpos=0x0, commands=0x0) at rts/Game/GameHelper.cpp:1085
#2 0x0000000000767624 in LuaSyncedRead::TestBuildOrder (L=0xdf882c0)
    at rts/Lua/LuaSyncedRead.cpp:4879
0000003 0x0000000000d80768 in luaD_precall (L=0xdf882c0, func=0x13b40670, nresults=1)
    at rts/lib/lua/src/ldo.cpp:320
0000004 0x0000000000d96378 in luaV_execute (L=0xdf882c0, nexeccalls=4) at rts/lib/lua/src/lvm.cpp:613
0000005 0x0000000000d80a3a in luaD_call (L=0xdf882c0, func=0x13b40360, nResults=0)
    at rts/lib/lua/src/ldo.cpp:378
#6 0x0000000000d78140 in f_call (L=0xdf882c0, ud=0x7fffffffc760) at rts/lib/lua/src/lapi.cpp:812
#7 0x0000000000d7fa7e in luaD_rawrunprotected (L=0xdf882c0,
    f=0xd7810b <f_call(lua_State*, void*)>, ud=0x7fffffffc760) at rts/lib/lua/src/ldo.cpp:116
#8 0x0000000000d80e4e in luaD_pcall (L=0xdf882c0, func=0xd7810b <f_call(lua_State*, void*)>,
    u=0x7fffffffc760, old_top=864, ef=848) at rts/lib/lua/src/ldo.cpp:464
#9 0x0000000000d781ea in lua_pcall (L=0xdf882c0, nargs=4, nresults=0, errfunc=5)
    at rts/lib/lua/src/lapi.cpp:833
0000010 0x00000000006d9c7e in CLuaHandle::RunCallInTraceback (this=0x13300000,
    hs=0x18b9b90 <CLuaHandle::UnitCreated(CUnit const*, CUnit const*)::cmdStr>, inArgs=4,
    outArgs=0, errfuncIndex=5, traceback=...) at rts/Lua/LuaHandle.cpp:428
#11 0x00000000006da02c in CLuaHandle::RunCallInTraceback (this=0x13300000, hs=..., inArgs=4,
    outArgs=0, errfuncIndex=5) at rts/Lua/LuaHandle.cpp:472
---Type <return> to continue, or q <return> to quit---
0000012 0x00000000006dbc74 in CLuaHandle::UnitCreated (this=0x13300000, unit=0x1d35ea00,
    builder=0x19119100) at rts/Lua/LuaHandle.cpp:821
0000013 0x0000000000b8aec5 in CEventHandler::UnitCreated (this=0x1907700 <eventHandler>,
    unit=0x1d35ea00, builder=0x19119100) at rts/System/EventHandler.h:391
0000014 0x0000000000b82b23 in CUnit::PostInit (this=0x1d35ea00, builder=0x19119100)
    at rts/Sim/Units/Unit.cpp:527
#15 0x0000000000bb904d in CBuilding::PostInit (this=0x1d35ea00, builder=0x19119100)
    at rts/Sim/Units/UnitTypes/Building.cpp:43
#16 0x0000000000bb17b7 in CUnitLoader::LoadUnit (
    this=0x19050bc <CUnitLoader::GetInstance()::instance>, cparams=...)
    at rts/Sim/Units/UnitLoader.cpp:124

#17 0x0000000000bb6d09 in CBuilder::StartBuild (this=0x19119100, buildInfo=...,
    feature=@0x7fffffffcc28: 0x0, waitStance=@0x7fffffffcbd3: false)
    at rts/Sim/Units/UnitTypes/Builder.cpp:670
#18 0x0000000000b2fe0d in CBuilderCAI::ExecuteBuildCmd (this=0x1a731400, c=...)
    at rts/Sim/Units/CommandAI/BuilderCAI.cpp:630
#19 0x0000000000b2f42a in CBuilderCAI::SlowUpdate (this=0x1a731400)
    at rts/Sim/Units/CommandAI/BuilderCAI.cpp:497
0000020 0x0000000000b3c972 in CCommandAI::GiveAllowedCommand (this=0x1a731400, c=..., fromSynced=true)
    at rts/Sim/Units/CommandAI/CommandAI.cpp:836
#21 0x0000000000b4e492 in CMobileCAI::GiveCommandReal (this=0x1a731400, c=..., fromSynced=true)
    at rts/Sim/Units/CommandAI/MobileCAI.cpp:279
#22 0x0000000000b2f127 in CBuilderCAI::GiveCommandReal (this=0x1a731400, c=..., fromSynced=true)
    at rts/Sim/Units/CommandAI/BuilderCAI.cpp:460
---Type <return> to continue, or q <return> to quit---
#23 0x0000000000b3b98d in CCommandAI::GiveCommand (this=0x1a731400, c=..., fromSynced=true)
    at rts/Sim/Units/CommandAI/CommandAI.cpp:594
0000024 0x0000000000742cbd in LuaSyncedCtrl::GiveOrderToUnit (L=0xdf882c0)
    at rts/Lua/LuaSyncedCtrl.cpp:2940
#25 0x0000000000d80768 in luaD_precall (L=0xdf882c0, func=0x13b40300, nresults=0)
    at rts/lib/lua/src/ldo.cpp:320
0000026 0x0000000000d96378 in luaV_execute (L=0xdf882c0, nexeccalls=4) at rts/lib/lua/src/lvm.cpp:613
0000027 0x0000000000d80a3a in luaD_call (L=0xdf882c0, func=0x13b40020, nResults=0)
    at rts/lib/lua/src/ldo.cpp:378
#28 0x0000000000d78140 in f_call (L=0xdf882c0, ud=0x7fffffffd660) at rts/lib/lua/src/lapi.cpp:812
0000029 0x0000000000d7fa7e in luaD_rawrunprotected (L=0xdf882c0,
    f=0xd7810b <f_call(lua_State*, void*)>, ud=0x7fffffffd660) at rts/lib/lua/src/ldo.cpp:116
#30 0x0000000000d80e4e in luaD_pcall (L=0xdf882c0, func=0xd7810b <f_call(lua_State*, void*)>,
    u=0x7fffffffd660, old_top=32, ef=16) at rts/lib/lua/src/ldo.cpp:464
#31 0x0000000000d781ea in lua_pcall (L=0xdf882c0, nargs=1, nresults=0, errfunc=1)
    at rts/lib/lua/src/lapi.cpp:833
#32 0x00000000006d9c7e in CLuaHandle::RunCallInTraceback (this=0x13300000,
    hs=0x18b9bf0 <CLuaHandle::GameFrame(int)::cmdStr>, inArgs=1, outArgs=0, errfuncIndex=1,
    traceback=...) at rts/Lua/LuaHandle.cpp:428
#33 0x00000000006da02c in CLuaHandle::RunCallInTraceback (this=0x13300000, hs=..., inArgs=1,
    outArgs=0, errfuncIndex=1) at rts/Lua/LuaHandle.cpp:472
0000034 0x00000000006daf48 in CLuaHandle::GameFrame (this=0x13300000, frameNum=1)
    at rts/Lua/LuaHandle.cpp:643
0000035 0x0000000000c1d098 in CEventHandler::GameFrame (this=0x1907700 <eventHandler>, gameFrame=1)
---Type <return> to continue, or q <return> to quit---
    at rts/System/EventHandler.cpp:378
#36 0x0000000000555658 in CGame::SimFrame (this=0x2895200) at rts/Game/Game.cpp:1514
#37 0x00000000005e21f3 in CGame::ClientReadNet (this=0x2895200) at rts/Game/NetCommands.cpp:390
#38 0x00000000005522b0 in CGame::Update (this=0x2895200) at rts/Game/Game.cpp:904
0000039 0x0000000000c52911 in Threading::UpdateGameController (ac=0x2895200)
    at rts/System/Platform/Threading.cpp:364
#40 0x0000000000c5b8dc in SpringApp::Update (this=0x7fffffffe380) at rts/System/SpringApp.cpp:970
#41 0x0000000000c5bbc5 in SpringApp::Run (this=0x7fffffffe380, argc=2, argv=0x7fffffffe548)
    at rts/System/SpringApp.cpp:1058
0000042 0x0000000000c34fd8 in Run (argc=2, argv=0x7fffffffe548) at rts/System/Main.cpp:65
0000043 0x0000000000c35765 in main (argc=2, argv=0x7fffffffe548) at rts/System/Main.cpp:150

cleanrock

2013-05-04 22:30

reporter   ~0010621

I also get a hang, check ZK usage of TestBuildOrder:
$ grep -r -l Spring.TestBuildOrder .
./LuaRules/Gadgets/ai_CAI.lua
./LuaRules/Gadgets/unit_terraform.lua
./LuaRules/Gadgets/unit_float_toggle.lua
./LuaRules/Gadgets/mex_spot_finder.lua
./LuaRules/Gadgets/unit_spawner.lua
./LuaRules/Gadgets/unit_impulsefloat_toggle.lua
./LuaRules/Gadgets/unit_impulsejumpjets.lua
./LuaRules/Gadgets/unit_planetwars.lua
./LuaRules/Gadgets/unit_teleporter.lua
./LuaRules/Gadgets/unit_jumpjet_pilot.lua
./LuaRules/Gadgets/unit_jumpjets.lua
./LuaRules/Deploy/main.lua
./LuaUI/Widgets/cmd_mex_placement.lua
./LuaUI/Widgets/unit_central_build_AI.lua
./LuaUI/Widgets/unit_waypoint_dragger_2.lua

abma

2013-05-04 22:44

administrator   ~0010622

Last edited: 2013-05-04 22:44

also its in the callin CLuaHandle::UnitCreated... should be easy to locate now.

i guess ai_CAI.lua ...

cleanrock

2013-05-05 12:22

reporter   ~0010629

getPositionTowardsMiddle seem to have broken in last ai_CAI.lua commit, looks like line endings is messed up (especially inside the while).

Kloot

2013-05-05 13:05

developer   ~0010631

and the "number of days since closing a ZK report that is not our problem" counter once again gets reset to 0

Issue History

Date Modified Username Field Change
2013-05-04 10:41 Google_Frog New Issue
2013-05-04 10:51 Google_Frog Note Added: 0010612
2013-05-04 10:54 Google_Frog File Added: infolog_405_1_hang.txt
2013-05-04 20:18 abma Note Added: 0010616
2013-05-04 20:19 abma Note Added: 0010617
2013-05-04 20:21 abma Note Edited: 0010617
2013-05-04 21:00 Kloot Note Added: 0010619
2013-05-04 21:03 abma Note Added: 0010620
2013-05-04 21:06 abma Note Edited: 0010620
2013-05-04 22:30 cleanrock Note Added: 0010621
2013-05-04 22:44 abma Note Added: 0010622
2013-05-04 22:44 abma Note Edited: 0010622
2013-05-05 12:22 cleanrock Note Added: 0010629
2013-05-05 13:05 Kloot Note Added: 0010631
2013-05-05 13:05 Kloot Status new => closed
2013-05-05 13:05 Kloot Assigned To => Kloot
2013-05-05 13:05 Kloot Resolution open => no change required