fmasa / wfrp-master

Unofficial Android companion app for 4th edition of Warhammer Fantasy Roleplay
GNU General Public License v3.0
13 stars 3 forks source link

App crashes and exits on npc tab #362

Closed happydoggoo closed 1 day ago

happydoggoo commented 2 days ago

When going into the npc tab the app crashes and fully closes

To Reproduce Steps to reproduce the behavior: .5 duplicate an npc (something causes a crash here seemingly at random)

  1. Go to load the npc tab
  2. Will crash upon attempted load in

Smartphone (please complete the following information): Samsung s20+

Additional context Starting a new party temporarily fixes the problem but I've had this glitch two times now.

Occurred when duplicating a npc

Probably 60+ npcs some with images for the profile pictures

Had duplicated many npcs all of kinds with images etc no idea what causes the crashes to happen. Both times happened with many npcs stored and duplicating (potentially long named npcs) but can't be sure if npc count or name is the factor since duplicates work fine a lot of the time

fmasa commented 2 days ago

Hi @happydoggoo, can you first try clearing the app cache?

I will investigate as I got similar bug report and I want to fix this for good. 🙂

happydoggoo commented 2 days ago

Still crashes on the selection of the npc tab

fmasa commented 2 days ago

I see some new error reports for NPC with name longer than 50 characters for a user with Samsung S20+ and I suspect that this might be you.

I think I found the issue and will prepare a fix in the evening (in ~5 hours). @happydoggoo Can you provide the name of the party, so I can fix the data as well?

Notes for fix:

happydoggoo commented 2 days ago

Parties name is Party

fmasa commented 1 day ago

@happydoggoo I fixed the data in your Party (you may need to clear the cache now) and added checks that will prevent this in the future (#364)