fix(libSceCdlgPlayerReview): keep a terminated dialog terminated during Open #15420

Merged
XairRrR merged 2 commits from upstream-pr/15420 into main 2026-11-07 08:58:33 +00:00
XairRrR commented 2026-11-03 06:48:50 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by XairRrR on 2026-11-03T06:48:50Z.


What

scePlayerReviewDialogOpen (core/libs/prx/libSceCdlgPlayerReview/Export.cpp) loads the status, checks it, validates the parameter, reads the login user list through sceUserServiceGetLoginUserIdList, and then stores FINISHED with a plain assignment. If another thread calls scePlayerReviewDialogTerminate in that window, Terminate moves the status from INITIALIZED to NONE and returns 0, and Open then overwrites NONE with FINISHED and also returns 0. After that, scePlayerReviewDialogGetStatus reports FINISHED for a library that was terminated, and a following scePlayerReviewDialogInitialize fails with 0x80B80004 (ALREADY_INITIALIZED).

Open now moves the status to FINISHED with a compare-exchange loop that starts from the status it checked. If the status changed in the meantime, the loop checks it again and returns NOT_INITIALIZED for NONE or BUSY for RUNNING, as the first check does. A Terminate that wins therefore stays in effect. scePlayerReviewDialogClose is not changed, because it only stores FINISHED from RUNNING, and no path in this library enters RUNNING.

The same pattern is fixed for other dialog libraries in #12931 (HmdSetupDialog) and #12893 (NpSnsFacebookDialog). This PR does not depend on them.

Tested

Arch Linux 7.2.11-zen, GCC 16.2.1, Ninja, Release, Intel Core i9-14900KF, NVIDIA GeForce RTX 4070 Ti SUPER (driver 615.78.08).

  • New check in core/libs/tests/GuestPlayerReviewDialog.cpp: 200000 rounds of Initialize on the main thread, then Open on the main thread racing Terminate on a second thread. After each round the status must be NONE.
  • ctest --test-dir build -R '^guest_player_review_dialog$': 1/1 passed (0.06 s), 5 runs out of 5.
  • Negative control: with Export.cpp restored from origin/main and rebuilt, the test aborts on all 3 runs (1/1 Test #1893: guest_player_review_dialog .......Subprocess aborted***Exception: 0.08 sec). With a temporary print added at the new check, the failure was round 9 status 3, so the status was FINISHED after Terminate.
  • cmake --build build --target libs: built.
  • python3 tools/check_conventions.py --base origin/main: All conventions checks passed.
  • git diff --check origin/main: clean.
  • python3 tools/pr_overlap.py --branch auto/fix-libscecdlgplayerreview-terminate-race: No overlap with open pull requests. #12516 adds checks to the same test file in other places, and it merges cleanly with this branch.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5133093769 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/15420). Originally posted by [XairRrR](https://github.com/XairRrR) on 2026-11-03T06:48:50Z. --- ### What `scePlayerReviewDialogOpen` (`core/libs/prx/libSceCdlgPlayerReview/Export.cpp`) loads the status, checks it, validates the parameter, reads the login user list through `sceUserServiceGetLoginUserIdList`, and then stores `FINISHED` with a plain assignment. If another thread calls `scePlayerReviewDialogTerminate` in that window, Terminate moves the status from `INITIALIZED` to `NONE` and returns 0, and Open then overwrites `NONE` with `FINISHED` and also returns 0. After that, `scePlayerReviewDialogGetStatus` reports `FINISHED` for a library that was terminated, and a following `scePlayerReviewDialogInitialize` fails with `0x80B80004` (`ALREADY_INITIALIZED`). Open now moves the status to `FINISHED` with a compare-exchange loop that starts from the status it checked. If the status changed in the meantime, the loop checks it again and returns `NOT_INITIALIZED` for `NONE` or `BUSY` for `RUNNING`, as the first check does. A Terminate that wins therefore stays in effect. `scePlayerReviewDialogClose` is not changed, because it only stores `FINISHED` from `RUNNING`, and no path in this library enters `RUNNING`. The same pattern is fixed for other dialog libraries in #12931 (HmdSetupDialog) and #12893 (NpSnsFacebookDialog). This PR does not depend on them. ### Tested Arch Linux 7.2.11-zen, GCC 16.2.1, Ninja, Release, Intel Core i9-14900KF, NVIDIA GeForce RTX 4070 Ti SUPER (driver 615.78.08). - New check in `core/libs/tests/GuestPlayerReviewDialog.cpp`: 200000 rounds of Initialize on the main thread, then Open on the main thread racing Terminate on a second thread. After each round the status must be `NONE`. - `ctest --test-dir build -R '^guest_player_review_dialog$'`: 1/1 passed (0.06 s), 5 runs out of 5. - Negative control: with `Export.cpp` restored from `origin/main` and rebuilt, the test aborts on all 3 runs (`1/1 Test #1893: guest_player_review_dialog .......Subprocess aborted***Exception: 0.08 sec`). With a temporary print added at the new check, the failure was `round 9 status 3`, so the status was `FINISHED` after Terminate. - `cmake --build build --target libs`: built. - `python3 tools/check_conventions.py --base origin/main`: `All conventions checks passed.` - `git diff --check origin/main`: clean. - `python3 tools/pr_overlap.py --branch auto/fix-libscecdlgplayerreview-terminate-race`: `No overlap with open pull requests.` #12516 adds checks to the same test file in other places, and it merges cleanly with this branch. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: n/a - [x] AI-assisted: yes
MarcZX10 commented 2026-11-03 06:54:19 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-03T06:54:19Z.

Review: APPROVED


Reviewed — looks good

The compare-exchange loop prevents Open from restoring FINISHED after Terminate has already set the dialog to NONE, and the relevant Windows test passed on this head.

What I ran

Reviewed head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 against base d1ae628bc2f62459cce1e9872ba5632c938c71f2; the stack checker reports a clean preview against that base. Local inspection environment: Debian Linux x86_64, GCC 12.2.0 and Python 3.11.2. The hosted Windows workflow built and ran the changed test.

python3 tools/pr_precheck.py --repo boykopovar/AnyPS5 --pr 15420
python3 tools/pr_abi_audit.py --repo /marc/AnyPS5 --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 --head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 --json
python3 tools/pr_test_quality.py --root /marc/AnyPS5 --json core/libs/tests/GuestPlayerReviewDialog.cpp
git grep -n -E 'guest_player_review_dialog|GuestPlayerReviewDialog' refs/review/session-20261103/15420 -- core/libs
python3 tools/pr_overlap.py --branch refs/review/session-20261103/15420 --repo boykopovar/AnyPS5 --jobs 12
git merge-tree --write-tree refs/review/session-20261103/12516 refs/review/session-20261103/15420
gh api repos/boykopovar/AnyPS5/commits/eb3f9794b6856ec6571c20f9c11e8e89f94e74c7/check-runs --jq '[.check_runs[] | {name,status,conclusion}]'
gh run view 41592261381 --repo boykopovar/AnyPS5 --job 125771480572 --log | grep -E 'guest_player_review_dialog|100% tests passed| tests failed|Test #[0-9]+' | tail -30

Results

Check Result Note
Diff and conventions Passed No patch-format or template issue.
Export ABI audit Passed Seven exports matched declarations and definitions; lexical audit only.
Test registration Passed CMake registers the changed test.
Test-quality heuristic Failed It flagged registration; exact-head CMake inspection confirms this is a false positive.
Stack preview Passed Clean against current base.
Overlap scan Failed Helper could not parse the GitHub response; pairwise preview with #12516 was clean.
Hosted policy checks Passed Labels, conventions, intake, eligibility, library portability and report.
Hosted Windows test Passed Exact-head CTest target passed 1/1.
Build and CTest here Not run No local build was performed.
Precheck table and raw helper output
| Check | Status | Command / reason |
|---|---|---|
| build_and_compile | not_applicable | `The precheck deliberately does not configure, build, or compile AnyPS5.` |
| diff_check | passed | `git diff --check d1ae628bc2f62459cce1e9872ba5632c938c71f2...eb3f9794b6856ec6571c20f9c11e8e89f94e74c7` |
| conventions_and_pr_template | passed | `/usr/bin/python3 tools/check_conventions.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 --head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 --title fix(libSceCdlgPlayerReview): keep a terminated dialog terminated during Open --body /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/pr-body.md` |
| changed_export_abi_audit | failed | `/usr/bin/python3 tools/pr_abi_audit.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 --head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 --json` |
| python_syntax | not_applicable | `No changed Python implementation files.` |
| related_python_unit_tests | not_applicable | `No changed tools/ module has an existing sibling tools/tests/test_<module>.py suite.` |
| python_test_registration | not_applicable | `No changed test_*.py files.` |
| live_dependency_and_mergeability_check | passed | `/usr/bin/python3 /marc/AnyPS5/tools/pr_stack_check.py 15420 --repo boykopovar/AnyPS5 --output-dir /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/stack` |
| build_dependent_cpp_tests | not_applicable | `Not run: C++ tests need exact-head binaries, which require a build; the precheck does not build.` |
| test_quality_heuristics | failed | `/usr/bin/python3 /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f/tools/pr_test_quality.py --root /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f --json core/libs/prx/libSceCdlgPlayerReview/Export.cpp core/libs/tests/GuestPlayerReviewDialog.cpp` |
| negative_controls | not_applicable | `No changed Python test module in tools/ can be run as a no-build base-source control.` |

The precheck's ABI-helper error was:

/usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f/tools/pr_abi_audit.py': [Errno 2] No such file or directory

The precheck's test-quality-helper error was:

/usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f/tools/pr_test_quality.py': [Errno 2] No such file or directory

The manual test-quality heuristic output was:

{"findings":[{"path":"core/libs/tests/GuestPlayerReviewDialog.cpp","line":1,"kind":"possible-unregistered-cpp-test","message":"Changed C++ test source path was not found literally in CMake files; inspect registration, generated source lists, and workflow coverage."}],"negative_control_candidates":[],"limits":["Heuristics can miss weak assertions and can flag valid tests; inspect every finding.","A test that passes against base is not by itself proof that the PR test is inadequate.","Negative controls are only candidates until the test actually runs against base and fails by assertion rather than import/setup error."]}

Manual ABI audit output summary:

{
  "status": "passed",
  "symbols": [
    {
      "name": "scePlayerReviewDialogClose",
      "computed_nid": "HDMHJ9zsCFg",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    },
    {
      "name": "scePlayerReviewDialogGetResult",
      "computed_nid": "VuKbx6zlEG4",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    },
    {
      "name": "scePlayerReviewDialogGetStatus",
      "computed_nid": "UYw6RlK7bcQ",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    },
    {
      "name": "scePlayerReviewDialogInitialize",
      "computed_nid": "UtXl-tmi7iw",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    },
    {
      "name": "scePlayerReviewDialogOpen",
      "computed_nid": "CtygVRCL+bA",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    },
    {
      "name": "scePlayerReviewDialogTerminate",
      "computed_nid": "RmJKkzZFNFA",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    },
    {
      "name": "scePlayerReviewDialogUpdateStatus",
      "computed_nid": "4J5F23VgTjY",
      "declarations": [
        "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp"
      ],
      "definitions": [
        "core/libs/prx/libSceCdlgPlayerReview/Export.cpp"
      ],
      "explicit_aliases": [],
      "version": "not encoded by these source declarations; not verified"
    }
  ],
  "findings": [],
  "limitations": [
    "This lexical audit does not parse C++ fully, prove calling-convention or binary ABI correctness, verify runtime version tables, or replace compilation.",
    "An absent source declaration or explicit alias can be intentional for assembly exports, conditional platform code, or generated interfaces; inspect findings before treating them as defects."
  ]
}

Exact-head CMake registration output:

refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:13:    add_test_executable(guest_player_review_dialog_tests ${LIBS_INCLUDE_DIR}/tests/GuestPlayerReviewDialog.cpp)
refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:14:    target_include_directories(guest_player_review_dialog_tests PRIVATE ${LIBS_INCLUDE_DIR})
refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:15:    target_link_libraries(guest_player_review_dialog_tests PRIVATE libSceCdlgPlayerReview libSceUserService)
refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:16:    add_test(NAME guest_player_review_dialog COMMAND guest_player_review_dialog_tests)
refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:18:        set_tests_properties(guest_player_review_dialog PROPERTIES ENVIRONMENT_MODIFICATION

Pairwise merge preview output for #12516 and this head:

35dd0626d02bbb397cda2d9ebbb6a5b311d458f2

Hosted check status output on the reviewed head:

[{"conclusion":"skipped","name":"write-watch","status":"completed"},{"conclusion":"skipped","name":"relinker","status":"completed"},{"conclusion":"skipped","name":"register-context","status":"completed"},{"conclusion":"skipped","name":"linux","status":"completed"},{"conclusion":"skipped","name":"relinker-asan","status":"completed"},{"conclusion":"skipped","name":"edge-watch","status":"completed"},{"conclusion":"success","name":"windows","status":"completed"},{"conclusion":"success","name":"labels","status":"completed"},{"conclusion":"success","name":"conventions","status":"completed"},{"conclusion":"success","name":"intake","status":"completed"},{"conclusion":"success","name":"eligibility","status":"completed"},{"conclusion":"success","name":"library-portability","status":"completed"},{"conclusion":"success","name":"report","status":"completed"}]

Windows workflow log, exact-head test output:

windows	Build and run changed guest core/libs tests	2026-11-03T06:52:32.6891858Z [3/5] Building CXX object core/libs/prx/libSceCdlgPlayerReview/CMakeFiles/guest_player_review_dialog_tests.dir/__/__/tests/GuestPlayerReviewDialog.cpp.obj
windows	Build and run changed guest core/libs tests	2026-11-03T06:52:32.7660076Z [4/5] Linking CXX executable tests\guest_player_review_dialog_tests.exe
windows	Build and run changed guest core/libs tests	2026-11-03T06:52:33.5817856Z     Start 2411: guest_player_review_dialog
windows	Build and run changed guest core/libs tests	2026-11-03T06:52:33.6458095Z 1/1 Test #2411: guest_player_review_dialog .......   Passed    0.06 sec
windows	Build and run changed guest core/libs tests	2026-11-03T06:52:33.6468018Z 100% tests passed, 0 tests failed out of 1
windows	Build and run changed guest core/libs tests	2026-11-03T06:52:33.6708796Z guest_player_review_dialog_tests

The overlap helper failed with:

pr_overlap: Invalid \\uXXXX escape: line 1 column 1929631 (char 1929630)

Negative control

The PR description reports that restoring the old implementation makes the test fail on three runs, including one observed FINISHED status after termination. I did not independently run this build-based control. The no-build review cannot exercise the assertion against a binary.

Findings

Blocking

None found in the inspected implementation and test.

Non-blocking

The race test checks the final status but discards scePlayerReviewDialogOpen's return value. As an additional assertion, require the result to be either success or COMMON_DIALOG_ERROR_NOT_INITIALIZED, the two outcomes consistent with the competing operations. The existing 200,000-round final-state assertion does cover the reported resurrection defect.

Sources

Not verified

I did not run a local C++ build or CTest, or independently reproduce the base negative control. The hosted Windows workflow built the changed test and CTest passed 1/1 on this head; Linux and specialized jobs were skipped. The PR author separately reports five successful runs and three failing base-control runs.

To get this to a good state

No blocking change is required from this review. No change is required for approval. If a new head is pushed, I will inspect the new diff and rerun the applicable checks.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5748231013 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/15420#pullrequestreview-5748231013). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-03T06:54:19Z. **Review:** APPROVED --- # Reviewed — looks good The compare-exchange loop prevents `Open` from restoring `FINISHED` after `Terminate` has already set the dialog to `NONE`, and the relevant Windows test passed on this head. ## What I ran Reviewed head `eb3f9794b6856ec6571c20f9c11e8e89f94e74c7` against base `d1ae628bc2f62459cce1e9872ba5632c938c71f2`; the stack checker reports a clean preview against that base. Local inspection environment: Debian Linux x86_64, GCC 12.2.0 and Python 3.11.2. The hosted Windows workflow built and ran the changed test. ```sh python3 tools/pr_precheck.py --repo boykopovar/AnyPS5 --pr 15420 python3 tools/pr_abi_audit.py --repo /marc/AnyPS5 --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 --head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 --json python3 tools/pr_test_quality.py --root /marc/AnyPS5 --json core/libs/tests/GuestPlayerReviewDialog.cpp git grep -n -E 'guest_player_review_dialog|GuestPlayerReviewDialog' refs/review/session-20261103/15420 -- core/libs python3 tools/pr_overlap.py --branch refs/review/session-20261103/15420 --repo boykopovar/AnyPS5 --jobs 12 git merge-tree --write-tree refs/review/session-20261103/12516 refs/review/session-20261103/15420 gh api repos/boykopovar/AnyPS5/commits/eb3f9794b6856ec6571c20f9c11e8e89f94e74c7/check-runs --jq '[.check_runs[] | {name,status,conclusion}]' gh run view 41592261381 --repo boykopovar/AnyPS5 --job 125771480572 --log | grep -E 'guest_player_review_dialog|100% tests passed| tests failed|Test #[0-9]+' | tail -30 ``` ## Results | Check | Result | Note | |---|---|---| | Diff and conventions | Passed | No patch-format or template issue. | | Export ABI audit | Passed | Seven exports matched declarations and definitions; lexical audit only. | | Test registration | Passed | CMake registers the changed test. | | Test-quality heuristic | Failed | It flagged registration; exact-head CMake inspection confirms this is a false positive. | | Stack preview | Passed | Clean against current base. | | Overlap scan | Failed | Helper could not parse the GitHub response; pairwise preview with #12516 was clean. | | Hosted policy checks | Passed | Labels, conventions, intake, eligibility, library portability and report. | | Hosted Windows test | Passed | Exact-head CTest target passed 1/1. | | Build and CTest here | Not run | No local build was performed. | <details><summary>Precheck table and raw helper output</summary> ```text | Check | Status | Command / reason | |---|---|---| | build_and_compile | not_applicable | `The precheck deliberately does not configure, build, or compile AnyPS5.` | | diff_check | passed | `git diff --check d1ae628bc2f62459cce1e9872ba5632c938c71f2...eb3f9794b6856ec6571c20f9c11e8e89f94e74c7` | | conventions_and_pr_template | passed | `/usr/bin/python3 tools/check_conventions.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 --head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 --title fix(libSceCdlgPlayerReview): keep a terminated dialog terminated during Open --body /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/pr-body.md` | | changed_export_abi_audit | failed | `/usr/bin/python3 tools/pr_abi_audit.py --base d1ae628bc2f62459cce1e9872ba5632c938c71f2 --head eb3f9794b6856ec6571c20f9c11e8e89f94e74c7 --json` | | python_syntax | not_applicable | `No changed Python implementation files.` | | related_python_unit_tests | not_applicable | `No changed tools/ module has an existing sibling tools/tests/test_<module>.py suite.` | | python_test_registration | not_applicable | `No changed test_*.py files.` | | live_dependency_and_mergeability_check | passed | `/usr/bin/python3 /marc/AnyPS5/tools/pr_stack_check.py 15420 --repo boykopovar/AnyPS5 --output-dir /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/stack` | | build_dependent_cpp_tests | not_applicable | `Not run: C++ tests need exact-head binaries, which require a build; the precheck does not build.` | | test_quality_heuristics | failed | `/usr/bin/python3 /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f/tools/pr_test_quality.py --root /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f --json core/libs/prx/libSceCdlgPlayerReview/Export.cpp core/libs/tests/GuestPlayerReviewDialog.cpp` | | negative_controls | not_applicable | `No changed Python test module in tools/ can be run as a no-build base-source control.` | ``` The precheck's ABI-helper error was: ```text /usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f/tools/pr_abi_audit.py': [Errno 2] No such file or directory ``` The precheck's test-quality-helper error was: ```text /usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15420-eb3f9794b685/head-eb3f9794b685-79a21e5f/tools/pr_test_quality.py': [Errno 2] No such file or directory ``` The manual test-quality heuristic output was: ```text {"findings":[{"path":"core/libs/tests/GuestPlayerReviewDialog.cpp","line":1,"kind":"possible-unregistered-cpp-test","message":"Changed C++ test source path was not found literally in CMake files; inspect registration, generated source lists, and workflow coverage."}],"negative_control_candidates":[],"limits":["Heuristics can miss weak assertions and can flag valid tests; inspect every finding.","A test that passes against base is not by itself proof that the PR test is inadequate.","Negative controls are only candidates until the test actually runs against base and fails by assertion rather than import/setup error."]} ``` Manual ABI audit output summary: ```text { "status": "passed", "symbols": [ { "name": "scePlayerReviewDialogClose", "computed_nid": "HDMHJ9zsCFg", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" }, { "name": "scePlayerReviewDialogGetResult", "computed_nid": "VuKbx6zlEG4", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" }, { "name": "scePlayerReviewDialogGetStatus", "computed_nid": "UYw6RlK7bcQ", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" }, { "name": "scePlayerReviewDialogInitialize", "computed_nid": "UtXl-tmi7iw", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" }, { "name": "scePlayerReviewDialogOpen", "computed_nid": "CtygVRCL+bA", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" }, { "name": "scePlayerReviewDialogTerminate", "computed_nid": "RmJKkzZFNFA", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" }, { "name": "scePlayerReviewDialogUpdateStatus", "computed_nid": "4J5F23VgTjY", "declarations": [ "core/libs/prx/libSceCdlgPlayerReview/include/Api.hpp" ], "definitions": [ "core/libs/prx/libSceCdlgPlayerReview/Export.cpp" ], "explicit_aliases": [], "version": "not encoded by these source declarations; not verified" } ], "findings": [], "limitations": [ "This lexical audit does not parse C++ fully, prove calling-convention or binary ABI correctness, verify runtime version tables, or replace compilation.", "An absent source declaration or explicit alias can be intentional for assembly exports, conditional platform code, or generated interfaces; inspect findings before treating them as defects." ] } ``` Exact-head CMake registration output: ```text refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:13: add_test_executable(guest_player_review_dialog_tests ${LIBS_INCLUDE_DIR}/tests/GuestPlayerReviewDialog.cpp) refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:14: target_include_directories(guest_player_review_dialog_tests PRIVATE ${LIBS_INCLUDE_DIR}) refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:15: target_link_libraries(guest_player_review_dialog_tests PRIVATE libSceCdlgPlayerReview libSceUserService) refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:16: add_test(NAME guest_player_review_dialog COMMAND guest_player_review_dialog_tests) refs/review/session-20261103/15420:core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt:18: set_tests_properties(guest_player_review_dialog PROPERTIES ENVIRONMENT_MODIFICATION ``` Pairwise merge preview output for #12516 and this head: ```text 35dd0626d02bbb397cda2d9ebbb6a5b311d458f2 ``` Hosted check status output on the reviewed head: ```text [{"conclusion":"skipped","name":"write-watch","status":"completed"},{"conclusion":"skipped","name":"relinker","status":"completed"},{"conclusion":"skipped","name":"register-context","status":"completed"},{"conclusion":"skipped","name":"linux","status":"completed"},{"conclusion":"skipped","name":"relinker-asan","status":"completed"},{"conclusion":"skipped","name":"edge-watch","status":"completed"},{"conclusion":"success","name":"windows","status":"completed"},{"conclusion":"success","name":"labels","status":"completed"},{"conclusion":"success","name":"conventions","status":"completed"},{"conclusion":"success","name":"intake","status":"completed"},{"conclusion":"success","name":"eligibility","status":"completed"},{"conclusion":"success","name":"library-portability","status":"completed"},{"conclusion":"success","name":"report","status":"completed"}] ``` Windows workflow log, exact-head test output: ```text windows Build and run changed guest core/libs tests 2026-11-03T06:52:32.6891858Z [3/5] Building CXX object core/libs/prx/libSceCdlgPlayerReview/CMakeFiles/guest_player_review_dialog_tests.dir/__/__/tests/GuestPlayerReviewDialog.cpp.obj windows Build and run changed guest core/libs tests 2026-11-03T06:52:32.7660076Z [4/5] Linking CXX executable tests\guest_player_review_dialog_tests.exe windows Build and run changed guest core/libs tests 2026-11-03T06:52:33.5817856Z Start 2411: guest_player_review_dialog windows Build and run changed guest core/libs tests 2026-11-03T06:52:33.6458095Z 1/1 Test #2411: guest_player_review_dialog ....... Passed 0.06 sec windows Build and run changed guest core/libs tests 2026-11-03T06:52:33.6468018Z 100% tests passed, 0 tests failed out of 1 windows Build and run changed guest core/libs tests 2026-11-03T06:52:33.6708796Z guest_player_review_dialog_tests ``` The overlap helper failed with: ```text pr_overlap: Invalid \\uXXXX escape: line 1 column 1929631 (char 1929630) ``` </details> ## Negative control The PR description reports that restoring the old implementation makes the test fail on three runs, including one observed `FINISHED` status after termination. I did not independently run this build-based control. The no-build review cannot exercise the assertion against a binary. ## Findings ### Blocking None found in the inspected implementation and test. ### Non-blocking The race test checks the final status but discards `scePlayerReviewDialogOpen`'s return value. As an additional assertion, require the result to be either success or `COMMON_DIALOG_ERROR_NOT_INITIALIZED`, the two outcomes consistent with the competing operations. The existing 200,000-round final-state assertion does cover the reported resurrection defect. ## Sources - [CAS transition in `scePlayerReviewDialogOpen`](https://github.com/boykopovar/AnyPS5/blob/eb3f9794b6856ec6571c20f9c11e8e89f94e74c7/core/libs/prx/libSceCdlgPlayerReview/Export.cpp#L42-L50) - [Race regression test](https://github.com/boykopovar/AnyPS5/blob/eb3f9794b6856ec6571c20f9c11e8e89f94e74c7/core/libs/tests/GuestPlayerReviewDialog.cpp#L22-L42) - [CTest registration](https://github.com/boykopovar/AnyPS5/blob/eb3f9794b6856ec6571c20f9c11e8e89f94e74c7/core/libs/prx/libSceCdlgPlayerReview/CMakeLists.txt#L10-L20) ## Not verified I did not run a local C++ build or CTest, or independently reproduce the base negative control. The hosted Windows workflow built the changed test and CTest passed 1/1 on this head; Linux and specialized jobs were skipped. The PR author separately reports five successful runs and three failing base-control runs. ## To get this to a good state No blocking change is required from this review. No change is required for approval. If a new head is pushed, I will inspect the new diff and rerun the applicable checks.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!15420
No description provided.