Workers do not store items in containers

Title:
Bug: Workers stop storing items in containers.

Summary:
I was playing in peaceful mode and had created a large number of “Large Containers” for storage. After approximately 5 minutes of playing the workers stopped storing items in the crates despite them not being full. The game continues to progress (random events happen, workers eat and sleep, etc.) but when there are no active tasks for them like building or getting resources they just stand around despite many raw materials sitting on the ground.

Steps to reproduce:
1) Place many large containers on ground.
2) Instruct workers to gather resources and/or buy items from shop.
3) Wait while containers are loaded.

Expected Results: Workers continue to load containers until they are full.

Actual Results: Workers stop loading containers despite not being full.

Attachments: Image of workers standing still.

Versions and Mods: develop-2611 with debug tools installed

System Information: Windows 10 Pro 64 | Intel Core i5-3360M | 16 GB system memory | Nvidia NVS 5400m

Edit: Notes: This seems to only happen when all containers are set to filter. Placing a crate which allows all objects will be loaded without issue.

1 Like

Update: Received the following Engine Error when attempting to change filter on crate:

develop-2611 (x64)
std::logic_error: 'invalid reference in native get_id'
stack traceback:
	stonehearth/components/ai/execution_frame.luac:672: in function <stonehearth/components/ai/execution_frame.luac:665>
	[C]: in function 'get_id'
	stonehearth/services/server/inventory/inventory.luac:286: in function 'is_storage_for_filter_fn'
	stonehearth/ai/actions/restock_storage_action.luac:7: in function 'filter_fn'
	stonehearth/ai/actions/find_path_to_entity_type.luac:21: in function 'call_fn'
	stonehearth/components/ai/execution_unit_v2.luac:22: in function '_call_start'
	stonehearth/components/ai/execution_unit_v2.luac:226: in function '_do_start'
	stonehearth/components/ai/execution_unit_v2.luac:196: in function '_start_from_ready'
	stonehearth/components/ai/execution_unit_v2.luac:132: in function '_start'
	stonehearth/components/ai/execution_frame.luac:451: in function '_start_from_ready'
	stonehearth/components/ai/execution_frame.luac:124: in function '_start'
	...
	stonehearth/components/ai/execution_frame.luac:129: in function '_run'
	stonehearth/components/ai/execution_frame.luac:360: in function <stonehearth/components/ai/execution_frame.luac:352>
	[C]: in function 'xpcall'
	stonehearth/components/ai/execution_frame.luac:674: in function '_protected_call'
	stonehearth/components/ai/execution_frame.luac:362: in function 'run'
	stonehearth/components/ai/ai_component.luac:178: in function '_thread_main'
	stonehearth/services/server/threads/thread.luac:90: in function <stonehearth/services/server/threads/thread.luac:89>
	[C]: in function 'xpcall'
	stonehearth/services/server/threads/thread.luac:89: in function 'f'
	radiant/lib/env.luac:8: in function <radiant/lib/env.luac:8>
1 Like

I changed a Large Crate from None (my default) to All and received this error:

develop-2611 (x64)
stonehearth/components/ai/execution_unit_v2.luac:72: bad unit transition "set_think_output" from "starting" in action put restockable item into backpack
stack traceback:
	[C]: ?
	[C]: in function 'error'
	stonehearth/components/ai/execution_unit_v2.luac:72: in function '_unknown_transition'
	stonehearth/components/ai/execution_unit_v2.luac:105: in function '_set_think_output'
	stonehearth/components/ai/execution_unit_v2.luac:302: in function '?'
	stonehearth/components/ai/execution_unit_v2.luac:18: in function 'set_think_output'
	stonehearth/services/server/ai/compound_action.luac:95: in function '_set_think_output'
	stonehearth/services/server/ai/compound_action.luac:77: in function '_start_thinking_on_frame'
	stonehearth/services/server/ai/compound_action.luac:80: in function 'think_progress_cb'
	stonehearth/components/ai/execution_frame.luac:344: in function '_think_progress_cb'
	stonehearth/components/ai/execution_frame.luac:654: in function '_set_state'
	...
	stonehearth/components/ai/execution_frame.luac:654: in function '_set_state'
	stonehearth/components/ai/execution_frame.luac:410: in function '_unit_ready_from_thinking'
	stonehearth/components/ai/execution_frame.luac:137: in function '_unit_ready'
	stonehearth/components/ai/execution_unit_v2.luac:187: in function '_set_think_output_from_thinking'
	stonehearth/components/ai/execution_unit_v2.luac:102: in function '_set_think_output'
	stonehearth/components/ai/execution_unit_v2.luac:302: in function '?'
	stonehearth/components/ai/execution_unit_v2.luac:18: in function 'set_think_output'
	stonehearth/ai/actions/find_path_to_entity_type.luac:17: in function 'solved_cb'
	...th/components/pathfinder/shared_bfs_path_finder.luac:47: in function '_call_solved_cbs'
	...th/components/pathfinder/shared_bfs_path_finder.luac:39: in function <...th/components/pathfinder/shared_bfs_path_finder.luac:36>

indeed it should be, though i believe there was a different thread for this error… i’ll have a look around.