{"record":{"id":"5d51b53cdb393d7f","repo":"stride3d/stride","slug":"commandlists","errorCode":null,"errorMessage":"commandLists","messagePattern":"commandLists","errorType":"exception","errorClass":"ArgumentNullException","httpStatus":null,"severity":"error","filePath":"sources/engine/Stride.Graphics/Vulkan/GraphicsDevice.Vulkan.cs","lineNumber":305,"sourceCode":"        }\n\n        /// <summary>\n        /// Executes a deferred command list.\n        /// </summary>\n        /// <param name=\"commandList\">The deferred command list.</param>\n        public void ExecuteCommandList(CompiledCommandList commandList)\n        {\n            ExecuteCommandListInternal(commandList);\n        }\n\n        /// <summary>\n        /// Executes multiple deferred command lists.\n        /// </summary>\n        /// <param name=\"count\">Number of command lists to execute.</param>\n        /// <param name=\"commandLists\">The deferred command lists.</param>\n        public unsafe void ExecuteCommandLists(int count, CompiledCommandList[] commandLists)\n        {\n            if (commandLists == null) throw new ArgumentNullException(nameof(commandLists));\n            if (count > commandLists.Length) throw new ArgumentOutOfRangeException(nameof(count));\n\n            var commandBufferInfos = stackalloc VkCommandBufferSubmitInfo[count];\n            for (int i = 0; i < count; i++)\n                commandBufferInfos[i] = CommandBufferSubmit(commandLists[i].NativeCommandBuffer);\n\n            ulong nextCommandListFenceValue;\n            lock (QueueLock)\n            {\n                var commandListFenceValue = CommandListFence.NextFenceValue++;\n                nextCommandListFenceValue = commandListFenceValue + 1;\n                // Make sure all copies are done as well\n                var copyFenceValue = CopyFence.NextFenceValue;\n\n                var waitInfos = stackalloc VkSemaphoreSubmitInfo[]\n                {\n                    SemaphoreSubmit(CommandListFence.Semaphore, commandListFenceValue),\n                    SemaphoreSubmit(CopyFence.Semaphore, copyFenceValue),","sourceCodeStart":287,"sourceCodeEnd":323,"githubUrl":"https://github.com/stride3d/stride/blob/96fad776d210c221682aac1ccdf4c79dc046fc38/sources/engine/Stride.Graphics/Vulkan/GraphicsDevice.Vulkan.cs#L287-L323","documentation":"Standard ArgumentNullException guard in GraphicsDevice.ExecuteCommandLists: the commandLists array argument is null. Vulkan submission needs an array of CompiledCommandList to build VkCommandBufferSubmitInfo entries.","triggerScenarios":"Calling graphicsDevice.ExecuteCommandLists(count, null) directly or via a renderer path that failed to build the frame's command list array.","commonSituations":"Custom render pipelines that skip CommandList recording; miswired render-system code passing an uninitialized array; mocking/unit-test code calling the API directly.","solutions":["Pass a valid CompiledCommandList[] (may be empty but not null)","Ensure the frame's command lists are recorded before submission","Check that your render pipeline always allocates the array before calling ExecuteCommandLists"],"exampleFix":"// before\nGraphicsDevice.ExecuteCommandLists(2, null);\n// after\nvar lists = new CompiledCommandList[] { cmdListA, cmdListB };\nGraphicsDevice.ExecuteCommandLists(lists.Length, lists);","handlingStrategy":"validation","validationCode":"if (commandLists is null)\n    throw new InvalidOperationException(\"No command lists recorded for this frame.\");\nGraphicsDevice.ExecuteCommandLists(commandLists.Length, commandLists);","typeGuard":"if (commandLists is not CompiledCommandList[] lists || lists.Length == 0)\n    return;","tryCatchPattern":"try\n{\n    GraphicsDevice.ExecuteCommandLists(count, commandLists);\n}\ncatch (ArgumentNullException ex)\n{\n    Logger.Error(ex, \"Attempted to submit null command list array.\");\n}","preventionTips":["Never call ExecuteCommandLists directly; go through the CommandList/render system","Guard against null arrays at your render-loop boundary","Initialize the command list array at frame start"],"tags":["null-argument","vulkan","command-list"],"backgroundTag":"null-argument","analyzedSha":"96fad776d210c221682aac1ccdf4c79dc046fc38","analyzedAt":"2026-09-14T02:59:31.279Z","contentChangedAt":"2026-09-14T02:59:31.279Z","schemaVersion":2},"datasetVersion":"2026-09-15T23:17:13.987Z"}