Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Room objects not showing #16

Open
Robalian opened this issue Jun 20, 2019 · 5 comments
Open

Room objects not showing #16

Robalian opened this issue Jun 20, 2019 · 5 comments
Assignees
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@Robalian
Copy link
Collaborator

The room subscription has been (mostly) fixed. However after some time of client running there still appears an issue of room objects not showing up. This time it look like it's correlated to having lots of "Exception: type data was not found for new roomObject, there may be a caching problem" and "received null data from server" in a log

@thmsndk thmsndk added the bug Something isn't working label Jun 20, 2019
@thmsndk thmsndk pinned this issue Jun 22, 2019
@thmsndk thmsndk added this to the First Alpha Release of client milestone Jun 23, 2019
@thmsndk
Copy link
Owner

thmsndk commented Jun 23, 2019

Currently, i've stayed put in a room, and everything kinda "freezes" after a while the log contains the following, sometimes it picks up again but then freezes. it has to run for around ~16 minutes

 
(Filename: C:\buildslave\unity\build\Runtime/Export/Debug.bindings.h Line: 45)

recieved null data from server
 
(Filename: C:\buildslave\unity\build\Runtime/Export/Debug.bindings.h Line: 45)

Exception: type data was not found for new roomObject, there may be a caching problem
  at Screeps3D.RoomObjects.ObjectManager.GetInstance (System.String id, .JSONObject data) [0x00000] in <filename unknown>:0 
  at Screeps3D.Rooms.RoomUnpacker.UnpackObjects (.JSONObject roomData) [0x00000] in <filename unknown>:0 
  at Screeps3D.Rooms.RoomUnpacker.Unpack (.JSONObject roomData) [0x00000] in <filename unknown>:0 
  at Screeps3D.Rooms.RoomObjectStream.ReceiveData (.JSONObject Data) [0x00000] in <filename unknown>:0 
  at Screeps_API.ScreepsSocket.FindSubscription (.JSONObject json) [0x00000] in <filename unknown>:0 
  at Screeps_API.ScreepsSocket.ProcessMessage (WebSocketSharp.MessageEventArgs e) [0x00000] in <filename unknown>:0 
  at Screeps_API.ScreepsSocket.Update () [0x00000] in <filename unknown>:0 
 
(Filename:  Line: -1)

recieved null data from server
 
(Filename: C:\buildslave\unity\build\Runtime/Export/Debug.bindings.h Line: 45)

@thmsndk
Copy link
Owner

thmsndk commented Jun 23, 2019

Looking at the private server launcer I noticed something that correlates to not receiving any data, might it be because the server is "crashing" and then restarting that we recieve null data?
image

@Robalian Robalian assigned Robalian and unassigned Robalian Jun 24, 2019
@thmsndk thmsndk added the help wanted Extra attention is needed label Jun 6, 2020
@thmsndk
Copy link
Owner

thmsndk commented Jun 15, 2020

After recieving a ton of recieved null data from server then we recieve game objects without the type property, we should perhaps add the id to this message, so we can figure out if it is a specific game object type causing this? my best bet is that we miss the initial tick, on for example a new creep due to a stale connection or something like that 🤔

@thmsndk
Copy link
Owner

thmsndk commented Jun 15, 2020

Seems like we are hitting a subscription limit


subscribing room:W8N4
recieved null flag data
["err@room:W7N4","subscribe limit reached"]
["err@room:W7N4","subscribe limit reached"]
Lost ticks count: 2 
(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

subscribing roomMap2:W10N6
["err@room:W7N4","subscribe limit reached"]
Lost ticks count: 2 
(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

["err@room:W8N4","subscribe limit reached"]
Lost ticks count: 2 
(Filename: C:\buildslave\unity\build\Runtime/Export/Debug/Debug.bindings.h Line: 35)

["err@room:W7N4","subscribe limit reached"]

I guess we do not unsubscribe properly? might also be because i'm running the steam client at the same time at the moment.

after a ton of limit reached we end up with recieved null data from server and then not long after we get

Exception: type data was not found for new roomObject, there may be a caching problem
 at Screeps3D.RoomObjects.ObjectManager.GetInstance (System.String id, JSONObject data) [0x0006b] in C:\Projects\Screeps3D\Assets\Scripts\Screeps3D\RoomObjects\ObjectManager.cs:38 
 at Screeps3D.Rooms.RoomUnpacker.UnpackObjects (JSONObject roomData) [0x00056] in C:\Projects\Screeps3D\Assets\Scripts\Screeps3D\Rooms\RoomUnpacker.cs:47 
 at Screeps3D.Rooms.RoomUnpacker.Unpack (JSONObject roomData) [0x0003d] in C:\Projects\Screeps3D\Assets\Scripts\Screeps3D\Rooms\RoomUnpacker.cs:29 
 at Screeps3D.Rooms.RoomObjectStream.ReceiveData (JSONObject Data) [0x0000e] in C:\Projects\Screeps3D\Assets\Scripts\Screeps3D\Rooms\RoomObjectStream.cs:54 
 at Screeps_API.ScreepsSocket.FindSubscription (JSONObject json) [0x00073] in C:\Projects\Screeps3D\Assets\Scripts\Screeps_API\ScreepsSocket.cs:142 
 at Screeps_API.ScreepsSocket.ProcessMessage (WebSocketSharp.MessageEventArgs e) [0x000d0] in C:\Projects\Screeps3D\Assets\Scripts\Screeps_API\ScreepsSocket.cs:127 
 at Screeps_API.ScreepsSocket.Update () [0x00004] in C:\Projects\Screeps3D\Assets\Scripts\Screeps_API\ScreepsSocket.cs:102 

@Harkole
Copy link

Harkole commented Jun 20, 2020

I'll take a look at this as time allows over the next few days

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants