feat(libSceNKWebKit): implement WTF::GregorianDateTime constructors #14478
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/14478"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by SHOnnay on 2026-11-01T15:04:43Z.
What
WTF::GregorianDateTime's C1/C2 constructors were unimplemented and threw. They now initialize calendar fields from milliseconds, copy the DST flag, and convert the supplied offset to minutes, following pinned public WebKit source. The PS5 module's actual WebKit revision is unverified. Non-finite milliseconds and values outside ±8.64e15 still throw and are listed in the debt file.Context-only overlap with #14164 in
Export.cppandInventoryExports.hpp; I will rebase if it merges first.Tested
WtfTime.cppand the new test compiled standalone. Before: failed on the throwing stub. After: passed with the implementation. Public-header audit passed;python3 tools/check_conventions.py --base upstream/mainpassed. The fullnkwebkit_wtftest was not run on macOS.BUILD_TESTING=ON, Ninja:ctest -R '^nkwebkit_wtf$'passed at head9105dff522.Behaviour follows pinned public WebKit revision
c55364d53f971f63a709976f168d932d558b8909; the PS5 module's actual WebKit revision is unverified.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Summary by CodeRabbit
Imported from boykopovar/AnyPS5. Originally posted by CnRJay on 2026-11-01T19:47:04Z.
Review: COMMENTED
Withdrawn. This review applied a title-ID/log requirement that is not in CONTRIBUTING (
Unblocks: noneis allowed), and it contained no code review.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-02T05:38:31Z.
Review: COMMENTED
Reviewed — no blocking findings
The two
GregorianDateTimeconstructors (C1 and C2) now fill the fields frommsthe way upstream WebKit does, and the twoNotImplementedstubs are gone. The hosted Windows CTest run passed 2594 of 2594 cases, includingnkwebkit_wtf, which is the test this PR adds. Non-finite input and values outside ±8.64e15 still throw, as the debt entry says.What I ran
9105dff52253cff13fd3acc8dbe1fc40d9364962; PR basee4501451406e4d3516c5b0eaa854d6ec1a28082d; current main52e9ae6d(merge preview clean). 6 files, +129/-10:src/WtfTime.cpp(+49),tests/Wtf.cpp(+76),Export.cpp(two stubs removed),include/WtfExports.hpp(two declarations added),include/InventoryExports.hpp(two removed) anddocs/dev/debt/libSceNKWebKit.md(+2).GregorianDateTimeandLocalTimeOffsetstructs insrc/WtfTimeTypes.hpp, the helpersisLeapYear,dayInYearanddaysFrom1970ToYear, and the new test.Source/WTF/wtf/GregorianDateTime.cpp(commitc55364d5, lines 30-90), which the debt entry cites.Results
GregorianDateTimeinWtfTimeTypes.hpp; offset / 60000, as upstreammsNotImplemented; a deliberate difference from upstream, which computes a result, and the debt entry says sotests/*.cppglob atCMakeLists.txtlines 49-57 registersnkwebkit_wtf; the test-quality helper's "possible-unregistered" warning is a false positivenkwebkit_wtf(hosted)Read-only check output
Precheck was not run: no PR-head code is run here. Diff check: passed. Conventions: passed. ABI audit: passed (10333 symbols). Stack check: clean merge preview, no declared dependencies. Hosted:
gh api repos/boykopovar/AnyPS5/commits/9105dff52253cff13fd3acc8dbe1fc40d9364962/check-runs.Negative control
Not run here. A negative control needs a build, and code from this head is not run here.
Findings
Blocking
None.
Non-blocking
NotImplemented_nid_no_patch. The pinned upstream slow path has no range check and computes a result for these values. The difference is stated in the debt entry, so this is not a silent stub, but it does differ from the source the entry cites.Sources
github.com/boykopovar/AnyPS5@9105dff522/core/libs/prx/libSceNKWebKit/src/WtfTime.cppgithub.com/boykopovar/AnyPS5@9105dff522/core/libs/prx/libSceNKWebKit/src/WtfTimeTypes.hppgithub.com/boykopovar/AnyPS5@9105dff522/core/libs/prx/libSceNKWebKit/tests/Wtf.cppgithub.com/boykopovar/AnyPS5@9105dff522/core/libs/prx/libSceNKWebKit/CMakeLists.txtgithub.com/WebKit/WebKit@c55364d53f/Source/WTF/wtf/GregorianDateTime.cppNot verified
DateMath.hhelpers cited in the debt entry were not re-read.nkwebkit_wtfresult come from the Windows check-run log summary; the full per-case log was not read.To get this to a good state
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-14T04:45:04Z.
Review: COMMENTED
Reviewed — no blocking findings
Nothing blocks this change; the points below are optional.
What I ran
Reviewed head
39d45a6b767689578bb9f1ff0f2375ccff53dcacusing the prepared diff andrepo_read.pyfor targeted source ranges. No commands or tests were run by me; reported platform test results are author-supplied.Results
Findings
Blocking
None.
Non-blocking
WtfTime.cpp:78casts the day count tointbefore computing the weekday. The accepted millisecond range permits day counts far outsideint; converting an out-of-range floating value tointhas undefined behavior. Consider computing the weekday using floating-point modulo or a wider integer type. The added boundary tests check the extreme dates, but their expected weekday values do not distinguish this cast from a safe calculation.Not verified
Export.cppandInventoryExports.hppwere read only around the removed declarations; the full texts were excluded from the review bundle.docs/dev/debt/libSceNKWebKit.mdwas read only around the changed debt entries; its full text was excluded. The included full texts forWtfTime.cpp,WtfExports.hpp, andtests/Wtf.cppwere reviewed only in relevant ranges. I did not run tests or verify console behavior; the WebKit revision on the PS5 module is unverified.To get this to a good state
Nothing is required. The weekday conversion note above is optional.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-14T05:48:46Z.
Review: APPROVED
Reviewed — looks good
The implementation at head
7e8a0e174129295218de2aca602b80e8f5d85d40follows the described date conversion and its added tests cover negative timestamps, leap years, range boundaries, and local offsets; the author reports Windows and standalone macOS checks, which I did not run.What I ran
No commands or tests were run. I reviewed the prepared diff and targeted source at the pinned head.
Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
Export.cpp,InventoryExports.hpp, anddocs/dev/debt/libSceNKWebKit.mdwere excluded from the prepared full-text bundle; their changed hunks were read indiff.patch, but surrounding file context was not reviewed. The PS5 module’s actual WebKit revision and console behavior are unverified. No tests were run by me; the macOS and Windows test results in the description are author-reported.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-18T21:45:22Z.
Review: APPROVED
Reviewed — looks good
The changed implementation and tests are readable and internally consistent; I found no verified defect, but the PS5 module’s WebKit revision and invalid-input behavior remain unverified.
What I ran
Reviewed head
d861d1b620f01d7c458c174067069a6c324ce7a1againstmain. No commands or tests were run. Readdescription.md,commits.md,manifest.json,diff.patch,README.md,WtfExports.hpp,WtfTime.cpp,WtfTimeTypes.hpp, the added test range intests/Wtf.cpp, and the new debt fragment.Export.cppandInventoryExports.hppwere excluded from the review folder; their removal hunks were read indiff.patch.Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
The PS5 module’s exact WebKit revision and console behavior were not verified. Invalid and out-of-range milliseconds take the existing
NotImplemented_nid_no_patchpath; that behavior was not exercised here. The author reports separate macOS compilation and Windows test results; those were not run as part of this review.Export.cppandInventoryExports.hppfull contents were not read.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by coderabbitai[bot] on 2026-11-30T04:09:06Z.
Review: COMMENTED
Architecture findings (1)
Advisory architecture findings (1)
8518ee27-8207-4592-8f7d-7b79eff6dc98Reviewing files that changed from the base of the PR and between
1841c37422and5014694e1e.core/libs/prx/libSceNKWebKit/Export.cppcore/libs/prx/libSceNKWebKit/include/InventoryExports.hppcore/libs/prx/libSceNKWebKit/include/WtfExports.hppcore/libs/prx/libSceNKWebKit/src/WtfTime.cppcore/libs/prx/libSceNKWebKit/tests/Wtf.cppdocs/dev/debt/changes/codex-feat-nkwebkit-gregorian-date-time.mdIncluded review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-30T04:19:28Z.
Review: APPROVED
Reviewed — looks good
The constructor implementation and its focused tests support merging at head
5014694e1ed88739ba3d0b942c00ee5257956609; I did not run commands or tests.What I ran
Read the prepared diff and targeted source ranges through
repo_read.py. No commands or tests were run. The PR description reports Windows and standalone macOS results; those were not independently verified.Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
The PS5 module's WebKit revision and console behavior remain unverified, as stated by the PR. I read
WtfTime.cpp,WtfTimeTypes.hpp,WtfExports.hpp,InventoryExports.hpp,Export.cpp,Wtf.cpp, and the added debt fragment.Export.cppwas read through the pinned reader because its full text was excluded from the review bundle. No changed files were excluded from this review;manifest.jsonmarks every changed file as reviewed.To get this to a good state
Nothing is required.
Imported from boykopovar/AnyPS5. Originally posted by ligmaSec on 2026-12-03T13:16:44Z.
Review: COMMENTED
Checked the branch sources and built the focused tests against the existing Linux runtime.
Wtfpassed, including the Gregorian date-time constructor cases.AI-assisted: yes.
Imported from boykopovar/AnyPS5. Originally posted by Plyxen on 2026-12-03T16:19:41Z.
Review: APPROVED
I read the diff at
5014694e1e. Windows 11 with GCC 15.2 and Linux (Ubuntu 24.04 in WSL2, GCC 13.3), applied ontomainatc1593e4e1ddtogether with other open PRs (so not an isolated build).nkwebkit_wtf: pass on both.mainthe two constructors take no arguments and throw.Not checked: a title.
AI-assisted: yes (Claude Code)
Pull request closed