| Summary: | Picmi wrongly calls a single black cell correct when there should be two | ||
|---|---|---|---|
| Product: | [Applications] picmi | Reporter: | phma |
| Component: | general | Assignee: | Jakob Linke <jakob> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | walch.martin |
| Priority: | NOR | ||
| Version First Reported In: | 2.0.0 | ||
| Target Milestone: | --- | ||
| Platform: | Ubuntu | ||
| OS: | Linux | ||
| Latest Commit: | https://invent.kde.org/games/picmi/commit/f8a03f1f98f9288e6d6b6cd705a3f430511550cf | Version Fixed/Implemented In: | |
| Sentry Crash Report: | |||
|
Description
phma
2021-04-01 09:11:11 UTC
I can repro, this is a bug. (Not sure when I'll get around to fixing it, patches welcome.) This happens when two conditions are met: 1. all fields of a line or row are filled with either boxes or crosses, i.e. there is no hole left 2. the pattern is a concatenation of two identical sub-patterns For example ☒☒☒☒☒☒☒▣☒▣▣☒▣ would satisfy 1 2 1 1 2 1 What is the desired behavior in that case? (In reply to Martin Walch from comment #2) > This happens when two conditions are met: > > 1. all fields of a line or row are filled with either boxes or crosses, i.e. > there is no hole left > 2. the pattern is a concatenation of two identical sub-patterns > > For example > ☒☒☒☒☒☒☒▣☒▣▣☒▣ > would satisfy > 1 2 1 1 2 1 > > What is the desired behavior in that case? Hi Martin, thanks for your recent work on Picmi. Since the pattern is obviously not satisfied, the desired behavior is for the numbers to show 'all black'. When a cross is again removed, leaving an empty box, e.g.: ☒☐☒☒☒☒☒▣☒▣▣☒▣ The right side of `1 2 1 1 2 1` would again be satisfied. A possibly relevant merge request was started @ https://invent.kde.org/games/picmi/-/merge_requests/4 (In reply to Jakob Gruber from comment #3) > Hi Martin, thanks for your recent work on Picmi. Since the pattern is > obviously not satisfied, the desired behavior is for the numbers to show > 'all black'. When a cross is again removed, leaving an empty box, e.g.: > > ☒☐☒☒☒☒☒▣☒▣▣☒▣ > > The right side of `1 2 1 1 2 1` would again be satisfied. Hi Jakob, this looks like an easy solution (https://invent.kde.org/games/picmi/-/merge_requests/4). Maybe you can take a look if it is adequate and fits with the game. Git commit f8a03f1f98f9288e6d6b6cd705a3f430511550cf by Albert Astals Cid, on behalf of Martin Walch. Committed on 09/02/2022 at 21:38. Pushed by aacid into branch 'master'. Always mark full lines with wrong streak sizes as completely unsatisfied Streak checks happen in normal and in reverse order. On full lines this means that all streaks are matched twice against the solution, yielding markers that may feel counter-intuitive. In particular, a solution that consists of two identical sub-patterns is marked as completely satisfied on a full line that contains the sub-pattern only once. A board may even seem completely solved, while it is not. To prevent this, extend the preliminary checks to completely reject full lines with the wrong number of streaks. M +8 -2 src/logic/streaks.cpp https://invent.kde.org/games/picmi/commit/f8a03f1f98f9288e6d6b6cd705a3f430511550cf |