Hi Johan,
Thanks for your findings. I'm looking into these issues to see whether they are regressions.
I could reproduce problem 1 (a level change while the engine is thinking swaps sides) on master. A level change from the web client is sent as two events, EVT_LEVEL followed by EVT_NEW_ENGINE. The NEW_ENGINE handler calls get_rid_of_engine_move(), which forces the engine to move and then deliberately discards that move (ignored engine move - takeback or state change forced move). It then reloads the engine and calls set_wait_state(msg, ...) without preserve_play_mode. That re-derives the play mode from the side to move, so after 1.a4 the user suddenly plays Black (new play mode: PlayMode.USER_BLACK), and no new search is started.
I'll keep investigating...
Thanks, Johan. Please go ahead and rebase 492-508-integration onto the latest master and resolve the small conflict. That makes sense, as it will ensure that further testing of the integration branch also includes the fixes for #522 and #523.
Please let me know when the rebased branch is ready, and I will update and test it again.
Greetings,PR #532 is now merged into 492-508-integration. I resolved the clock display conflict and combined the test_web_analysis_clock.py tests from both branches. The relevant tests pass. In addition issue #505 was also fixed in master, and the integration branch includes that fix after the rebase. The integration branch is pushed and ready for testing.
This means that more or less all bugs in the issue list are now in the integration branch for testing. The issue #529 with PR #531 I still keep as a separate branch and PR as it needs testing on a DGT clock. Its not yet included in either master nor the integration branch. All others should be.
Happy testing :-)
This is a good hardening sprint. Lets try to avoid adding new features while we are hardening. Refactoring is ok of course, but lets try to keep a feature stop for a while? It would be good to get this integration branch and all the bugs fixed stabilized before continuing.
// Johan
Conclusion: tests 1, 2, 3 and 5 passed. Test 4 exposed a pre-existing DGT3000 issue, but I found no regression or remaining blocker for PR #531.
Greetings,
DJ
--
You received this message because you are subscribed to the Google Groups "PicoChess" group.
To unsubscribe from this group and stop receiving emails from it, send an email to picochess+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/picochess/604f45dc-971d-4dc4-a805-6014e55a3940n%40googlegroups.com.
Hi Johan, I have now completed an additional hardware test round of 492-508-integration at commit 5e79c677.
1. General integration results
2. Fast mode switching — issue #537
Normal mode changes work when sufficient time is allowed. Rapid web mode changes still expose the known timing problem:
“Wait for OK Mode” is only a useful workaround on a physical DGT clock. The web client provides no equivalent completion indication. Web users currently need to wait about three seconds between mode changes.
3. Analysis → Play display race — issue #540
This is reproducible on the integration branch after all, although not on every attempt.
After clicking Return to Play:
The log shows:
Further DGT_DISPLAY_TEXT commands continue every second while PicoChess is already in Play. The web client therefore shows an analysis line where the clock should remain visible. The DGT3000 also receives the corresponding score-only text. modeswitch5.log contains the reproduction.
4. DGT3000 score display — issue #539
When the unwanted analysis display reaches the DGT3000, it can show bare numerical scores rather than the normal clock. This may share its underlying analysis-routing cause with #540.
5. Dutch menu translations — issue #538
More untranslated menu content was found. The Mode submenu is dynamically generated and most buttons remain in English, although Dutch translations already exist. “Terug naar Spelen” is translated because that button uses the translation catalog, while the other generated tiles use their English labels directly.
6. DGT3000 extra-second behaviour — issue #536
The extra displayed second was reproduced both with PR #531 and on its predecessor/current master. It therefore does not appear to be a regression caused by #531. Issue #536 remains the correct place for further investigation.
Overall
Normal play on both the RPi5 and RPi2 looks good, and ordinary mode changes generally work. However, #540 is not obsolete: the integration branch still has an intermittent Analysis → Play display race. I would like your opinion on whether #540 should be fixed before merging the integration branch. The other findings are either already tracked separately or are non-blocking UX/localization issues.
Greetings,
DJ
Hi Johan, I also ran an additional mode-switch test on the RPi5 with Touch Display 2, without a DGT3000 connected.
I repeatedly switched between Play and Analysis, including fairly quick consecutive switches. I found no visible problems:
I checked two RPi5 logs. One contained three engine analyser stop timed out after 1.0s - cancelling task warnings, but these caused no visible malfunction and PicoChess continued normally. The second test log contained no engine, protocol or mode-switch errors at all; only unrelated force_leds_off: (rev) leds still on warnings.
This is useful as a comparison with issue #540: I have not reproduced that display problem on the RPi5. So far, it has only occurred during the RPi2 test with a physical DGT board and DGT3000 attached. I cannot yet distinguish whether that difference is caused by timing, load, or the physical DGT clock path.
Greetings,
DJ
My latest RPi2 test (without DGT3000, using only the web client) on commit 9365b43c confirms that the #540 MultiPV fix works: Analysis shows three PVs, Play returns to one PV, and the stale extra lines do not reappear. I also did not reproduce the earlier frozen Arasan analysis or illegal uci error.
One related issue remains: after Analysis → Play, the web clock is not restored immediately; it appears after the next move. I documented the timestamps in #540. I do not currently consider this a blocker for merging the integration branch, but it should remain as a separate follow-up.
Before giving the final hardware sign-off, I would like to run one short test on the same commit with the DGT3000 connected. The latest #539 readable-score fix and the physical-clock side of #540 have not yet been tested by me on 9365b43c.
If that focused DGT3000 test is clean, I support merging the integration branch into master and continuing regression testing there.
Greetings,Hi Johan, I reproduced one remaining part of #540 on the RPi2 with the DGT3000, using integration commit 9365b43c.
The backend switches correctly from Ponder/Analysis to Normal, but the physical clock display is not restored immediately. During the slow analyser shutdown, the once-per-second DGT callback can still emit analysis text using the old display mode. After the mode change completes, no DGT_DISPLAY_TIME is sent. The DGT3000 therefore keeps showing depth/score until the next move triggers MSG_EXIT_MENU.
I propose a small follow-up to PR #543:
This stays within the existing async and display architecture: no delay, no direct DGT command from mainloop.py, and no suppression of legitimate analysis output in Play.
If you agree, I suggest adding this to PR #543 because it completes its #540 fix. If you prefer to keep #543 as-is, I can make it a separate focused PR against the integration branch.
Greetings,
DJ
A quick update on #540. Since #543 has already been merged, I did not add to it. The remaining DGT display problem is now a separate follow-up: #544 Restore DGT display after leaving analysis mode, targeting 492-508-integration.
What I found on the RPi2 with the DGT3000 (integration commit 9365b43c): the backend switched correctly from Ponder/Analysis to Normal, but the clock kept showing depth/score until the next move. During the slow analyser shutdown, the once-per-second DGT callback still ran with the old Ponder display policy, and no DGT_DISPLAY_TIME was sent when the switch completed.
The fix is small:
The tests include a deterministic case with a deliberately suspended analyser stop. pylama and unittest are green; mypy is red on the existing baseline, with the count unchanged at 256 errors.
What's still open on the integration branch:
- #540, the three web PVs after Analysis → Play: fixed by #543 and tested here on the PC, but not yet confirmed by DJ on the RPi2.
- #539, the DGT3000 score format: the fix is on the integration branch; DJ still needs to check how " 4 0.42" reads on the real DGT3000.
- The late bestmove from a cancelled search (the Arasan "illegal uci" in Analysis mode): waiting for DJ's retest with a debug log, if it shows up again.
Hi Johan,
I checked the expected behaviour on both setups:
Here, “Analysis” refers to the user-facing Analysis mode, implemented internally as Mode.PONDER. The separate internal Mode.ANALYSIS is shown as “Move Hint” in the UI.
I have restored the same intended Analysis behaviour for the standalone DGT3000: alternating PV and depth/score according to the ponder interval. Kibitz remains depth/score only, and the web analysis display is unaffected.
The fix is based on the integration head that already contains #544, so the display mode is synchronized before a potentially slow analyser stop. I also confirmed on the standalone DGT3000 that returning from Analysis to Normal restores the normal clock display without a late analysis rotation.
The fix has been successfully tested on the RPi2 with the standalone DGT3000 and is ready in PR #546, targeting 492-508-integration.
With the readable score formatting already on the integration branch and the restored PV rotation in #546, I consider #539 fully resolved once this PR is merged.
Greetings,Hi Johan,
Wow, we really made some nice progress here. Thanks for all your patient work!
I'll have a look into #547 this week.
In the meantime I have started cleaning up the current mypy baseline on branch codex/typing/mypy-cleanup. Just want to get rid of all those mypy error messages.
So far, the number of errors has dropped from 256 in 18 files to 234 in 9 files. All changes are split into small commits and tested. Mypy also uncovered two real issues: an unawaited update notification and an outdated pyserial inWaiting() call.
The work is still in progress. You can follow it here:
https://github.com/djdekker/picochess/tree/codex/typing/mypy-cleanup
Best (and enjoy the good wine),
DJ
I’ve opened pull requests for four open issues:
PR #553 addresses #502. After switching from a depth/node time control to a clock-based time control, the old depth or node value remained in picochess.ini. Because these values take priority during startup, PicoChess returned to the old depth setting after a restart. Selecting a clock-based time control now clears them.
PR #552 addresses #538. The Dutch web interface displayed English options under 'Weergave'. These dynamic menu labels are now localized. The Coach blunder alert also displays the complete Dutch word 'hint' instead of 'hnt'.
PR #549 addresses #547. After checkmate in Analysis mode, the clock rotation returned to the previous position’s evaluation, such as mate in 1. The final result now remains visible.
PR #551 addresses #548. PicoTutor blunder, threat, and hint messages disappeared after approximately one second. They now remain visible for their intended duration.
If you agree with the proposed changes and consider them suitable for inclusion, perhaps the next release could be PicoChess 4.4.0 rather than another 4.3.x patch release. PicoChess is currently at version 4.3.6, and the changes made over the past few weeks appear substantial enough to justify a minor-version update.
I have also prepared updated AArch64 engine packages, available for download at https://drive.google.com/drive/folders/17t_rzkG85BOZogdqPPQSfmUH75oDUSOI?usp=sharing. The Google Drive folder contains:
These packages contain Stockfish 19NN, the current NNUE version of Arasan, the updated fairy.uci, and the required Rodent III/IV files. The included README describes the changes related to #468, while SHA256SUMS can be used to verify the downloaded archives.
If the packages are accepted and published, they should resolve issues #337 and #468.
I have only updated the three aarch64 packages listed above. I have not updated any other engine packs that may exist, such as other packs attached to the 4.2.0 and 4.2.2 releases.
For a possible 4.4.0 release, perhaps the cleanest approach would be to republish all engine and resource assets under v4.4.0, including any assets that are unchanged from v4.2.0 or v4.2.2. Unchanged archives could remain byte-for-byte identical to their earlier versions.
This would make the 4.4.0 release self-contained and would allow install-engines.sh to use one central release variable:
ENGINE_RELEASE="v4.4.0"Existing installations do not automatically replace their installed engine packs when PicoChess itself is updated. Users who want the updated lite packages would therefore need to install them explicitly after updating:
cd /opt/picochess
sudo ./install-picochess.sh pico lite
The installer backs up the existing engines before installing the explicitly selected lite pack.
What do you think of this approach?
DJ