Repository navigation
Conversation
kvnloo
force-pushed
the
nc/pe26-solar-exported-regression
branch
from
November 6, 2026 19:54
12d6020 to
31b4257
Compare
kvnloo
force-pushed
the
nc/pe26-solar-exported-regression
branch
from
November 6, 2026 19:56
31b4257 to
1e4474b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Draft #43 already adds exported solar-direction coverage and mounted site reactivity. PE32 found host-local calendar getters; PE33 removed that drift. PE35's exact-head review found the remaining contract ambiguity: callers may mistake an ISO date-only value for a selected site day, although a
Datealways carries an instant. Mean-solar day west of Greenwich can differ from UTC date, and legal UTC+14 civil dates can differ even more near the date line. The subprocess regression also compared outputs without proving the children observed distinct host time zones.Design
@pascal-app/viewerexports in the existing colocated Bun test; no source-grep, cross-package source imports, mocks or sleeps in the new cases.day: Dateis an instant that selects the mean-solar calendar day at the supplied longitude. It is not a date-only/civil-day argument. Longitude gives mean-solar time (4 minutes per degree), not the legally observed time zone or an IANA civil calendar.new Date('2026-06-21')parses as UTC midnight, not an instruction to select June 21 at a western site. A civil-date scheduling API would need a separately chosen legal time zone and an explicit product requirement; this patch does not invent that conversion.Change (file:line at exact head
c59dc97765f43123c7175137dce483855df7f5ff)PE36 — one commit on existing fork-only Draft branch, parent
334cb37, new headc59dc97:packages/viewer/src/lib/daylight/solar.ts:124-132,150-174: explicitly document instant-versus-date-only and longitude mean-solar-versus-legal-civil semantics. Calculation is unchanged.packages/viewer/src/lib/daylight/daylight.test.ts:18-55: existing UTC / Etc/GMT+5 subprocess regression now asserts offsets 0 / +300 minutes and host calendar dates 21 / 20 before comparing solar results.daylight.test.ts:57-70: new west-longitude/date-only instant regression.daylight.test.ts:72-80: new ±180° physical-noon continuity regression.daylight.test.ts:82-96: new UTC+14 civil-day versus mean-solar-day regression at −157.5°.Retained earlier commits: PE26 exported
solarLight/persisted site north rotation; PE27 mounted root-site key/CPU-sky reactivity; PE33 mean-solar day-from-instant calculation and initial host-timezone subprocess regression. These are not new PE36 changes.Tests
3 new Bun cases; 1 earlier subprocess case strengthened. ALL UNRUN. No executed Bun, Biome, types, build, Chromium/GPU, or PMREM evidence is claimed. No Actions run was returned for this exact head when inspected.
Hand-derived expected values (not execution):
getTimezoneOffset()===0, whereas Etc/GMT+5 must observe===300and the prior local calendar day. Both must return identical public solar outputs.Exact verification commands — ALL UNRUN:
The two bare
bun testcommands are focused-file invocations only, not the documented package/full-suite script.bun run buildmust precede them because public viewer imports resolve todist. The whole package test usesbun --cwd packages/viewer run test, and the full suite usesbun run ci.Upstream readiness
HOLD — fork-only Draft; do not promote. The chosen contract matches the existing instant-based implementation but has no independent civil-date product requirement or timezone selection API. Earlier mounted private-import T-001 exposure is not resolved in PE36. The CPU-sky probe is not visible GPU sky/PMREM/shadow proof. Exact-head native checks and PE34 browser/GPU evidence remain prerequisites. No upstream write, new branch/PR, default-branch push, or merge.
Follow-ups
Implemented by ChatGPT (mobile app, GitHub connector) for Kevin's OSS factory.