feat(libSceNKWebKit): implement WebCore::ResourceRequestBase scalar, URL and method accessors #15214

Merged
simnJS merged 7 commits from upstream-pr/15214 into main 2026-11-07 06:53:52 +00:00
simnJS commented 2026-11-02 20:55:46 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by simnJS on 2026-11-02T20:55:46Z.


What

Implements 19 WebCore::ResourceRequestBase exports in libSceNKWebKit: url, setURL, isNull, isEmpty, firstPartyForCookies, setFirstPartyForCookies, httpMethod, setHTTPMethod, timeoutInterval, cachePolicy, setCachePolicy, priority, setPriority, isSameSite, setIsSameSite, isTopSite, setIsTopSite, defaultTimeoutInterval and setDefaultTimeoutInterval.

They follow Source/WebCore/platform/network/ResourceRequestBase.h and .cpp and HTTPHeaderMap.h of the PS5 11.x WebKit snapshot neonmodder123/PS5-WebKit-11.x at 80f77e9, the snapshot #13992 uses. The object layout comes from those sources and is not verified against the console module. When m_resourceRequestUpdated is false they throw, since the PS5 backend of doUpdateResourceRequest is unknown. The 33 exports that need HTTPHeaderMap, Vector<String>, FormData or a copy of the request stay stubs. The debt file records all of this.

Tested

Windows 11 Pro 26200, WinLibs GCC 15.2.0 r7, Release: nkwebkit_resourcerequest passes (reference counts, URL and String copies, flag and enum round trips). Only this test was run, not the full suite. Not run on Linux or on a title.

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:5127281290 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/15214). Originally posted by [simnJS](https://github.com/simnJS) on 2026-11-02T20:55:46Z. --- ### What Implements 19 `WebCore::ResourceRequestBase` exports in `libSceNKWebKit`: `url`, `setURL`, `isNull`, `isEmpty`, `firstPartyForCookies`, `setFirstPartyForCookies`, `httpMethod`, `setHTTPMethod`, `timeoutInterval`, `cachePolicy`, `setCachePolicy`, `priority`, `setPriority`, `isSameSite`, `setIsSameSite`, `isTopSite`, `setIsTopSite`, `defaultTimeoutInterval` and `setDefaultTimeoutInterval`. They follow `Source/WebCore/platform/network/ResourceRequestBase.h` and `.cpp` and `HTTPHeaderMap.h` of the PS5 11.x WebKit snapshot neonmodder123/PS5-WebKit-11.x at 80f77e9, the snapshot #13992 uses. The object layout comes from those sources and is not verified against the console module. When `m_resourceRequestUpdated` is false they throw, since the PS5 backend of `doUpdateResourceRequest` is unknown. The 33 exports that need `HTTPHeaderMap`, `Vector<String>`, `FormData` or a copy of the request stay stubs. The debt file records all of this. ### Tested Windows 11 Pro 26200, WinLibs GCC 15.2.0 r7, Release: `nkwebkit_resourcerequest` passes (reference counts, URL and String copies, flag and enum round trips). Only this test was run, not the full suite. Not run on Linux or on a title. ### 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-02 21:01:55 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-02T21:01:55Z.

Review: COMMENTED


Reviewed — no blocking findings

The 19 accessors match the pinned WebKit implementation at source level, but the guest object layout is unverified against the PS5 module and the hosted checks are still queued, so I am withholding approval.

What I ran

Reviewed exact head f5fb0f4dc2d4349d43093006e60acc7f50a420a3 against base 9090972b7e91fd266819cbd77a8b058e177b5682; the repository precheck reports that head and base stayed unchanged and the merge preview against current main was clean. Environment: Debian 12 x86_64, Linux 6.1.0-54-amd64, Python 3.11.2, Git 2.39.5, GCC 12.2.0. No local C++ build or CTest was run.

git diff --check 9090972b7e91fd266819cbd77a8b058e177b5682...f5fb0f4dc2d4349d43093006e60acc7f50a420a3
python3 tools/pr_precheck.py --repo boykopovar/AnyPS5 --pr 15214
python3 tools/pr_abi_audit.py --repo /marc/AnyPS5 --base 9090972b7e91fd266819cbd77a8b058e177b5682 --head f5fb0f4dc2d4349d43093006e60acc7f50a420a3 --json
python3 tools/pr_test_quality.py --root /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15214-f5fb0f4dc2d4/head-f5fb0f4dc2d4-8b893de6 --json core/libs/prx/libSceNKWebKit/tests/ResourceRequest.cpp
git show refs/review/15214/20261102-f5fb0f:core/libs/prx/libSceNKWebKit/CMakeLists.txt | sed -n '1,140p'

Results

Check Result Note
Diff and conventions passed No diff errors; conventions had one debt-length warning.
Export declaration audit passed 10,102 symbols scanned; zero findings. This is lexical, not binary ABI validation.
Test registration passed CMake glob includes tests/*.cpp and registers each test.
Test-quality heuristic passed Heuristic warning disproved by the CMake glob.
Repository precheck failed Two workspace-only helper scripts are missing from its isolated checkout.
Hosted checks not run Six checks were queued at final refresh.
Local build and CTest not run Initial review does not build or compile.
Command output and precheck details

git diff --check produced no output and exited 0.

Conventions output (unedited):

docs/dev/debt/libSceNKWebKit.md:21: warning: [debt-length] Technical debt entry over 1000 characters: state the gap first (what differs from the console, what is unverified, what throws) and keep only the behaviour it needs: 1767 characters
1 findings, 0 errors; GitHub shows at most 10 error annotations, the job summary lists all

Precheck helper errors (unedited):

/usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15214-f5fb0f4dc2d4/head-f5fb0f4dc2d4-8b893de6/tools/pr_abi_audit.py': [Errno 2] No such file or directory
/usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15214-f5fb0f4dc2d4/head-f5fb0f4dc2d4-8b893de6/tools/pr_test_quality.py': [Errno 2] No such file or directory

ABI audit result excerpt (unedited JSON fields):

{
  "status": "passed",
  "findings": []
}

Test-quality output (unedited):

core/libs/prx/libSceNKWebKit/tests/ResourceRequest.cpp:1: possible-unregistered-cpp-test: Changed C++ test source path was not found literally in CMake files; inspect registration, generated source lists, and workflow coverage.
Heuristic findings require manual interpretation.

Hosted CI snapshot at final refresh (all checks matched the reviewed head):

conventions  queued
eligibility  queued
intake  queued
labels  queued
library-portability  queued
report  queued

Negative control

Assertion Code change Test failed?
New accessors fail when their assertion is broken None; no exact-head C++ binary was available without building. Could not exercise.

Findings

Blocking

None found in the source files reviewed.

Non-blocking

  • The declared layout is derived from the pinned PS5 WebKit snapshot and is explicitly not verified against the console module. The source-level review and lexical export audit do not prove that the guest object offsets match the PS5 binary; the debt entry records this limitation.
  • The PR description reports a Windows test run but does not identify its tested SHA, so I could not confirm that report applies to this exact head.

Sources

Not verified

No local build, CTest, negative control, Linux hosted build, title run, console behavior or PS5-module layout comparison was performed. The six current hosted checks had not started at final refresh.

To get this to a good state

No source change is requested. I will recheck the six hosted results and rerun the same no-build commands if the head changes.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5743289045 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/15214#pullrequestreview-5743289045). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-02T21:01:55Z. **Review:** COMMENTED --- # Reviewed — no blocking findings The 19 accessors match the pinned WebKit implementation at source level, but the guest object layout is unverified against the PS5 module and the hosted checks are still queued, so I am withholding approval. ## What I ran Reviewed exact head `f5fb0f4dc2d4349d43093006e60acc7f50a420a3` against base `9090972b7e91fd266819cbd77a8b058e177b5682`; the repository precheck reports that head and base stayed unchanged and the merge preview against current `main` was clean. Environment: Debian 12 x86_64, Linux 6.1.0-54-amd64, Python 3.11.2, Git 2.39.5, GCC 12.2.0. No local C++ build or CTest was run. ```sh git diff --check 9090972b7e91fd266819cbd77a8b058e177b5682...f5fb0f4dc2d4349d43093006e60acc7f50a420a3 python3 tools/pr_precheck.py --repo boykopovar/AnyPS5 --pr 15214 python3 tools/pr_abi_audit.py --repo /marc/AnyPS5 --base 9090972b7e91fd266819cbd77a8b058e177b5682 --head f5fb0f4dc2d4349d43093006e60acc7f50a420a3 --json python3 tools/pr_test_quality.py --root /tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15214-f5fb0f4dc2d4/head-f5fb0f4dc2d4-8b893de6 --json core/libs/prx/libSceNKWebKit/tests/ResourceRequest.cpp git show refs/review/15214/20261102-f5fb0f:core/libs/prx/libSceNKWebKit/CMakeLists.txt | sed -n '1,140p' ``` ## Results | Check | Result | Note | |---|---|---| | Diff and conventions | passed | No diff errors; conventions had one debt-length warning. | | Export declaration audit | passed | 10,102 symbols scanned; zero findings. This is lexical, not binary ABI validation. | | Test registration | passed | CMake glob includes `tests/*.cpp` and registers each test. | | Test-quality heuristic | passed | Heuristic warning disproved by the CMake glob. | | Repository precheck | failed | Two workspace-only helper scripts are missing from its isolated checkout. | | Hosted checks | not run | Six checks were queued at final refresh. | | Local build and CTest | not run | Initial review does not build or compile. | <details><summary>Command output and precheck details</summary> `git diff --check` produced no output and exited 0. Conventions output (unedited): ```text docs/dev/debt/libSceNKWebKit.md:21: warning: [debt-length] Technical debt entry over 1000 characters: state the gap first (what differs from the console, what is unverified, what throws) and keep only the behaviour it needs: 1767 characters 1 findings, 0 errors; GitHub shows at most 10 error annotations, the job summary lists all ``` Precheck helper errors (unedited): ```text /usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15214-f5fb0f4dc2d4/head-f5fb0f4dc2d4-8b893de6/tools/pr_abi_audit.py': [Errno 2] No such file or directory /usr/bin/python3: can't open file '/tmp/anyps5-pr-precheck/boykopovar-AnyPS5-pr-15214-f5fb0f4dc2d4/head-f5fb0f4dc2d4-8b893de6/tools/pr_test_quality.py': [Errno 2] No such file or directory ``` ABI audit result excerpt (unedited JSON fields): ```json { "status": "passed", "findings": [] } ``` Test-quality output (unedited): ```text core/libs/prx/libSceNKWebKit/tests/ResourceRequest.cpp:1: possible-unregistered-cpp-test: Changed C++ test source path was not found literally in CMake files; inspect registration, generated source lists, and workflow coverage. Heuristic findings require manual interpretation. ``` Hosted CI snapshot at final refresh (all checks matched the reviewed head): ```text conventions queued eligibility queued intake queued labels queued library-portability queued report queued ``` </details> ## Negative control | Assertion | Code change | Test failed? | |---|---|---| | New accessors fail when their assertion is broken | None; no exact-head C++ binary was available without building. | Could not exercise. | ## Findings ### Blocking None found in the source files reviewed. ### Non-blocking - The declared layout is derived from the pinned PS5 WebKit snapshot and is explicitly not verified against the console module. The source-level review and lexical export audit do not prove that the guest object offsets match the PS5 binary; the debt entry records this limitation. - The PR description reports a Windows test run but does not identify its tested SHA, so I could not confirm that report applies to this exact head. ## Sources - [ResourceRequestBase data layout](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/network/ResourceRequestBase.h#L66-L108) - [URL, cache, timeout and first-party accessors](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/network/ResourceRequestBase.cpp#L104-L250) - [Same-site, top-site and HTTP method behavior](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/network/ResourceRequestBase.cpp#L254-L307) - [Priority and default-timeout behavior](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/network/ResourceRequestBase.cpp#L551-L565) - [PS5 WebKit default-timeout initialization](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/network/ResourceRequestBase.cpp#L35-L42) ## Not verified No local build, CTest, negative control, Linux hosted build, title run, console behavior or PS5-module layout comparison was performed. The six current hosted checks had not started at final refresh. ## To get this to a good state No source change is requested. I will recheck the six hosted results and rerun the same no-build commands if the head changes.
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!15214
No description provided.