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

"Hide next move" in studies gets lost #17030

Open
mliebelt opened this issue Feb 22, 2025 · 5 comments
Open

"Hide next move" in studies gets lost #17030

mliebelt opened this issue Feb 22, 2025 · 5 comments
Labels

Comments

@mliebelt
Copy link

Exact URL of where the bug happened

https://lichess.org/study/G8Q49yXj/qXhduLhP

Steps to reproduce the bug

  1. Select chapter 1.
  2. Go one by one through the moves of the game.
  3. Check after each move the mode of the chapter (should be "Hide next move").
  4. The moment you have played the last move, the former mode "Hide next move" is automatically switched to "Normal analysis".
  5. Even if you play the moves back (to hide them again), and are then at the beginning of the moves list, the mode remains "Normal analysis".

What did you expect to happen?

The expectation of the study creator and user is:

  • A chapter set to "Hide next move" remains in that mode all the time.
  • Only when the study creator switches that mode to any other mode, only then the mode changes.

What happened instead?

The mode of the chapter switched to "Normal analysis", and the UI (when taking back moves) looked like the mode was "Hide next move". The next time you then go to that chapter, it behaves like "Normal analysis", so that all moves are visible then to everyone.

Operating system

Ubuntu 22.04

Browser and version (or alternate access method)

Chrome last (Version 133.0.6943.126 (Official Build) (64-bit)), or Chromium last (Version 133.0.6943.126 (Official Build) (64-bit))

Additional information

This is a bug that I have seen now at least 2-3 years, and today I took the time to hunt it. Reason is, that this one bug leads all the time to situations, where I show to the students (of an online training, where I share a study) the moves without intention, so that they see e.g. the solution, and the whole chapter does not work any more.

@mliebelt mliebelt added the bug label Feb 22, 2025
@Piti06
Copy link

Piti06 commented Mar 7, 2025

Hi, I would like to work on this issue. Can you please assign me? Thank you!

@Piti06
Copy link

Piti06 commented Mar 25, 2025

Hello, I have been trying to solve this issue. I think it might be in the lila/modules/study/src/main/Chapter or ChapterMaker . I am doing this for a college project. Can you please give me some insight?

@mliebelt
Copy link
Author

@Piti06 I don't understand your question. I am just an experienced user of Lichess, and I have described the circumstances when the bug is seen in a complete way. What do you mean by "give me some insight"?

@Piti06
Copy link

Piti06 commented Mar 27, 2025

I have solved the issue
@mliebelt @ornicar

@Piti06
Copy link

Piti06 commented Mar 27, 2025

Can you please assign me back?

Piti06 added a commit to Piti06/lila that referenced this issue Mar 27, 2025
Creating a chapter in study if we choosed "Hide next moves"
as soon as we played the first move,
it would go back to "Normal Analysis", this happened because
the logic for updating the "Hide next moves" wasn't
working correctly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants