Version: (using Devel) Compiler: gcc-4.2.4 OS: Linux Installed from: Compiled sources Since the new engine went in, the majority of games that I complete report that there are errors in the solution. The games are the X-sudoku variant. I fill all of the cells, and get a message that the solution contains errors, informing me to turn on error display to show the problem cells. When I turn on that setting, no cells are highlighted in red. If I click on the "SOLVE" button, it blanks one of the (correct) cells in the solution, and then claims that this is the correct solution, even though there is now one missing number on the board. You can often see this effect. Start a new game. Correctly fill in at least one cell. Click the "SOLVE" button, and notice that the claimed solution is missing one number.
Created attachment 39714 [details] The valid solution that I got that was marked with errors
I got the same problem with a 9x9, standard sudoku (see attachment).
It is a bug in the solver. I'm investigating it but haven't had enough time to find its root. This is currently the bug with highest priority on my TODO list.
Small note on the progress (in the case someone wants to help me): 4x4 Sudokus have this problem in about roughly 50% of cases. As they are really small it shouldn't be to difficulty to locate the bug with help of them.
To fix this bug is very important, as it is a really show-stopper.
In the "this is clearly wrong" department, an empty Tiny Samurai puzzle is consistently reported as having no solution.
Ok, I think, I found one of the potential roots of this evil. The solver accepts a solution when all cells have only one marker left. This can be before all cells have their value set. (It might even occur that a puzzle is invalid but the solver has not checked all rules. But this is only a theoretical problem, I haven't encountered it) I try to fix this tomorrow.
SVN commit 1080811 by joselb: - Fixed bug of wrong solutions - Correct solutions should now get identified as such - Added 2 small methods that could be used for debugging BUG:217926 M +6 -0 constraint.cpp M +1 -0 constraint.h M +4 -0 constrainthelperstorage.cpp M +1 -0 constrainthelperstorage.h M +1 -0 ruleset.h M +1 -1 solver.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1080811
Created attachment 40483 [details] wrong sudoku I'm using Version 0.5 under KDE 4.3.98 (KDE 4.4 RC3) and I also had a problem that has to do with the solver I think. look at the attached screenshot, this was the proposed solution, which actually is wrong, if you look in the bottom left square (no "1", two times "2"). I even think that this game was not valid (or solvable or how you would call it)
seams that the solver still has some corner cases where it will not work as expected.
Just ran into this bug on ksudoku 0.5/KDE 4.4 final. The specific puzzle (standard 9x9, hardest difficulty) was: __5 24_ __9 1__ 65_ 37_ 6__ 873 5_2 ___ ___ __3 3__ ___ ___ _6_ 437 9_5 ___ 7__ 4__ 487 __2 63_ 5__ ___ __7 Upon finishing, I obviously got the "solution contains errors" message, and after I glanced over the puzzle to see that wasn't the case, I went into the settings and turned on "show errors" which didn't reveal any red cells. Then I kept tapping "Hint" to have it fill in the puzzle, and eventually found something that might be of use: the hint got to R5C8, and overwrote my 8 with a locked _blank cell_. Deleting and reentering a number at that point solved the puzzle according to KSudoku, but of course now there was no way to get the 8 back. (On a side note, that seemed like a very easy puzzle for its difficulty setting, in case there turns out to be a bug in that component too.)
"solution contains errors" is the main problem but the very easy puzzles that are regularly offered under difficulty hard is a bug too.
I can also confirm hitting this error. Also the puzzle generated was very easy, even though I had selected very difficult. I will attach a copy of the saved game. Hope that helps
Created attachment 41302 [details] The saved game having the solved puzzle
The "hard" puzzles sometimes being very easy is a different bug, specifically bug 217925.
SVN commit 1100590 by joselb: - Fixed bug for the 4.4 branch (missed to backport the fix of trunk) BUG:217926 M +5 -6 solver.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1100590
I haven't seen this happen for at least several weeks now. I'm the original reporter, I'm marking this as verified fixed.