WorkingRobot / Craftimizer

The best FFXIV crafting solver via hardware accelerated Genetic MCTS.
MIT License
16 stars 5 forks source link

Using too few steps causes crafting log to throw an exception #16

Closed robzombie91 closed 3 months ago

robzombie91 commented 3 months ago

System.AggregateException: One or more errors occurred. (Specified argument was out of the range of valid values.) (Specified argument was out of the range of valid values.) ---> System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. at Craftimizer.Solver.MCTS.ExpandAndRollout(Random random, Simulator simulator, ArenaNode1 initialNode, Span1 actionBuffer) in /work/repo/Solver/MCTS.cs:line 181 at Craftimizer.Solver.MCTS.Search(Int32 iterations, Int32& progress, CancellationToken token) in /work/repo/Solver/MCTS.cs:line 263 at Craftimizer.Solver.Solver.<>cDisplayClass58_2.<b3>d.MoveNext() in /work/repo/Solver/Solver.cs:line 165 --- End of stack trace from previous location --- at Craftimizer.Solver.Solver.SearchStepwiseGenetic() in /work/repo/Solver/Solver.cs:line 183 at Craftimizer.Solver.Solver.RunTask() in /work/repo/Solver/Solver.cs:line 83 at Craftimizer.Solver.Solver.GetTask() in /work/repo/Solver/Solver.cs:line 91 at Craftimizer.Windows.RecipeNote.b118_0(CancellationToken token) in /work/repo/Craftimizer/Windows/RecipeNote.cs:line 1181 at Craftimizer.Windows.RecipeNote.BackgroundTask`1.<>cDisplayClass19_0.b0() in /work/repo/Craftimizer/Windows/RecipeNote.cs:line 77 at System.Threading.Tasks.Task1.InnerInvoke() at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state) --- End of stack trace from previous location --- at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread) --- End of inner exception stack trace --- at System.AggregateException.Handle(Func2 predicate) at Craftimizer.Windows.RecipeNote.BackgroundTask`1.<>cDisplayClass19_0.b__2(Task`1 t) in /work/repo/Craftimizer/Windows/RecipeNote.cs:line 81

WorkingRobot commented 3 months ago

Hmm, I'll look into that

WorkingRobot commented 3 months ago

Fixed in 7363b81ce584aa072854c494bf6304d2980b7f6f. Expect an update with this fix soon-ish.