-
November 17th, 2022, 18:01 #1
- Join Date
- Jun 2020
- Posts
- 547
Error When Setting Category [attempt to index global 'category' (a nil value)]
I am seeing an error in one of my development campaigns when I am trying to set records to a new category I created. This is in the latest version of FG (4.3.1). I have been unable to recreate the issue in other campaigns, so I am wondering what could cause this. Is this due to some sort of data corruption? The error pops up below when clicking and dragging certain records (like NPCs) to a new Category. The weird thing is that the category does seem to get set, it just pops this in the console:
Code:[11/17/2022 12:51:11 PM] [ERROR] Handler error: [string "CoreRPG:..cripts/masterindexitem_window.lua"]:132: attempt to index global 'category' (a nil value) stack traceback: [string "CoreRPG:..cripts/masterindexitem_window.lua"]:132: in function <[string "CoreRPG:..cripts/masterindexitem_window.lua"]:127> [C]: in function 'setCategory' [string "CoreRPG:..ts/masterindexcategory_window.lua"]:15: in function 'handleDrop' [string "CoreRPG:..pts/masterindexcategory_label.lua"]:33: in function <[string "CoreRPG:..pts/masterindexcategory_label.lua"]:32>
-
November 17th, 2022, 19:52 #2
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 22,024
From the error message, it looks like it is unable to find the category control.
Just some random questions/thoughts to explore further:
* Have you modified the masterindexitem windowclass at all? Or any of the window classes or scripts used in the master index implementation?
* Do you have a filter named "category" for that list?
Regards,
JPG
-
November 17th, 2022, 21:03 #3
- Join Date
- Jun 2020
- Posts
- 547
-
November 17th, 2022, 21:07 #4
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 22,024
No idea, without having the ruleset and the example campaign to set up debug statements. Or you can do that using unpacked CoreRPG on your end too.
The error message is just stating that the "category" variable is currently nil; which shouldn't happen because the "masterindexitem" window class specifically defines a "category" control.
Regards,
JPG
-
November 17th, 2022, 21:38 #5
- Join Date
- Jun 2020
- Posts
- 547
-
November 17th, 2022, 22:03 #6
- Join Date
- Jun 2020
- Posts
- 547
Okay I found the bug. It's in fact happening in all rulesets.
Here's the steps to recreate:
1. In any campaign (say 5e) load a module that is readonly like the Monster manual
2. Open the NPCs window
3. Create a new category
4. Select the category that contains the NPCs in the monster manual
5. Click and drag to copy an NPC
6. With this current category STILL selected, click and drag the (Copy) NPC to the new category
7. Error pops upLast edited by seansps; November 18th, 2022 at 03:10.
-
November 18th, 2022, 22:10 #7
Hi, I'm also seeing the same error and I've reproduced it as follows:
1) Create new 5e campaign without loading any extensions
2) Don't load any modules
3) Go to items, create a new group (use the default "Group 1")
4) Create a new item (call is "1") and move it from "Uncategorized" to "Group 1" or vice versa - the error message appears.
5) Quit and restart, moving the previously saved item no longer displays the error message, however, creating a new item and moving it to a different group reproduces the error.
Please fix?
-
November 22nd, 2022, 18:46 #8
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 22,024
Thanks guys. I was able to recreate with @seansps steps, but not others. I'll be working on a fix.
Regards,
JPG
-
January 1st, 2023, 03:53 #9
-
January 1st, 2023, 07:35 #10
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 22,024
It's in the pipeline with other changes. I'll be having a beta soon with a bunch of updates.
Regards,
JPG
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks