Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Bizzarre Satify Number behavior #555

Closed
Bram28 opened this issue Jun 8, 2023 · 2 comments · Fixed by #755
Closed

[BUG] Bizzarre Satify Number behavior #555

Bram28 opened this issue Jun 8, 2023 · 2 comments · Fixed by #755
Assignees
Labels
bug Something isn't working light up

Comments

@Bram28
Copy link
Member

Bram28 commented Jun 8, 2023

Description

OK, really bizarre one ... I have a case rule that checks out when it should clearly not

Steps to Reproduce

First I do some initial moves. So far so good:

image

Now I put a lightbulb to the right of the 2 ... and select the Case Rule 'Satify Number':

image

Oops! This should not check out. And strangely, it does not check out when the very top right square is not lit up. For example:

image

I really have no idea what could lead to this behavior ... someone will have to trace this

Expected Behavior

As explained above, the rule should not check out

Screenshots

No response

Puzzle Files

No response

Additional Context

No response

@Bram28 Bram28 added bug Something isn't working nurikabe labels Jun 8, 2023
@Bram28 Bram28 added light up and removed nurikabe labels Jun 22, 2023
@charlestian23 charlestian23 changed the title [BUG] <description> [BUG] Bizzarre Satify Number behavior Jan 30, 2024
@charlestian23 charlestian23 self-assigned this Mar 12, 2024
@charlestian23
Copy link
Collaborator

Ok, after a multitude of testing this week, I have come to the conclusion that this is a general bug with case rules. I believe once a transition is present like this:
image
even if there are no actual changes present on the board, the case rule checker starts to act strangely. This is because many of the case rules rely on parent.getChildren() for error checking. By making a modification to the board, we set the number of children to 1. However, in the case of Satisfy Number, you are allowed to have 1 child, and so this results in the rule missing the error check.

I have also verified this is an engine-wide bug with testing on Nurikabe:

  1. Open any LEGUP Nurikabe puzzle
  2. Make any modification to the board
  3. Click on the cells you modified and change them back to unknown. At this point, there should be no difference between the starting board and the board currently on your screen, but there should exist a transition on the tree in the TreeView.
  4. Attempt to use the Black or White case rule, which should be allowed to be used at this point.
  5. Note that LEGUP creates a new node with a red transition.

A possible solution I will explore is deleting this arrow on any call of a case rule. I'm not sure how this is possible right now and will need to do more testing to figure out how to implement this.

@Chase-Grajeda
Copy link
Collaborator

Fixed by #755

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working light up
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants