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

Computer won game with a tile on the board #174

Open
Sothatsit opened this issue Dec 1, 2021 · 2 comments
Open

Computer won game with a tile on the board #174

Sothatsit opened this issue Dec 1, 2021 · 2 comments
Labels
bug Something isn't working

Comments

@Sothatsit
Copy link
Collaborator

I received a bug report through email where the computer won (with a score of 7) while the computer still had one tile left on the board.

I've not received any other reports of this (yet, at least), so I'm not sure whether this is a random bug or unique to the reporter's computer.

Some possible ideas of things to investigate:

  • Is it possible that a tile was not subtracted when a computer played a move
  • Is it possible that a score was double-counted for the computer?
  • Is it possible that the computer moved from a tile where a piece didn't exist, but the game acted like a piece did exist there?
  • Is it possible that the computer moved a piece, but the old piece remained where it was?
  • Could this be a graphical bug where a piece was displayed when it shouldn't have been?

I have followed up with the reporter to ask what level of AI they were playing against.

@Sothatsit Sothatsit added the bug Something isn't working label Dec 1, 2021
@Potherca
Copy link

Potherca commented Jan 2, 2022

If I might chime in... I the computer can play itself (if this is not already possible, I don't think that would be too hard to implement out-of-repo), a test-case could be created to check for a valid end-state and just let the machine run until it hits that scenario.

If this this could be done without invoking the UI, the amount of times the tests could run would significantly increase.
That would also give an indication whether the UI is involved, i.e. if the scenario never occurs, the error is bount to be in UI related code.

@Sothatsit
Copy link
Collaborator Author

If I might chime in... I the computer can play itself (if this is not already possible, I don't think that would be too hard to implement out-of-repo), a test-case could be created to check for a valid end-state and just let the machine run until it hits that scenario.

If this this could be done without invoking the UI, the amount of times the tests could run would significantly increase. That would also give an indication whether the UI is involved, i.e. if the scenario never occurs, the error is bount to be in UI related code.

The Extreme AI, which I believe was used in this case, is actually implemented in Java in our RoyalUrAnalysis repo. Therefore, it has been tested extensively in a similar simulation of playing it against itself (e.g. to determine whether the first player gets a big advantage).

Therefore, I think it would probably be a bug in the interface between the client and the AI. That would require us to write the tests to run in JavaScript, unfortunately. However, I think something like this getting me to write some JavaScript tests would definitely be an improvement!

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

No branches or pull requests

2 participants