js/php: decide the three open questions of JAVASCRIPT-AND-PHP.md #62

Closed
opened 2026-10-05 21:07:15 +00:00 by orion · 12 comments
Collaborator

Context

Before either back end: the oldest PHP version TorbScript supports. Questions 1 (exact 64-bit Int in JavaScript) and 3 (browser capabilities) of section 3 moved to #417; this issue keeps question 2.

Source

Acceptance criteria

  • The owner decision on the oldest supported PHP version is recorded on this issue
  • The record names that version with its research (Fibers since 8.1, end-of-life dates, state-machine fallback needed or not) and the decision moves from section 3 to section 2
  • Docs-only PR, one Conventional Commit; no seed change

Dependencies

Blocks #64 (and the PHP column of #65). Question 1 and 3: #417.

Moved from the planning lists of the docs; the design record stays the specification.

## Context Before either back end: the oldest PHP version TorbScript supports. Questions 1 (exact 64-bit `Int` in JavaScript) and 3 (browser capabilities) of section 3 moved to #417; this issue keeps question 2. ## Source - [JAVASCRIPT-AND-PHP.md section 3](https://git.torb.dev/torbscript/language/src/commit/393ef2608e4a60b8ff76d8b6b408951b822d887d/docs/design/JAVASCRIPT-AND-PHP.md#L41), open question 2 ## Acceptance criteria - [ ] The owner decision on the oldest supported PHP version is recorded on this issue - [ ] The record names that version with its research (Fibers since 8.1, end-of-life dates, state-machine fallback needed or not) and the decision moves from section 3 to section 2 - [ ] Docs-only PR, one Conventional Commit; no seed change ## Dependencies Blocks #64 (and the PHP column of #65). Question 1 and 3: #417. _Moved from the planning lists of the docs; the design record stays the specification._
Author
Collaborator

[loop:torbscript] intake: in scope (author orion, label loop), source JAVASCRIPT-AND-PHP.md section 3, not a duplicate. A research and design-record issue: the 64-bit Int representation and the browser capability split are technical and decided by the loop with research; the oldest supported PHP version is a public commitment and the record asks for the owner's sign-off, so refine files that part as an owner decision. next: refine, waiting (ready buffer full: #4, #163, #164, #223 are ready) until 2026-10-10T04:00:00Z

[loop:torbscript] intake: in scope (author orion, label loop), source JAVASCRIPT-AND-PHP.md section 3, not a duplicate. A research and design-record issue: the 64-bit `Int` representation and the browser capability split are technical and decided by the loop with research; the oldest supported PHP version is a public commitment and the record asks for the owner's sign-off, so refine files that part as an owner decision. next: refine, waiting (ready buffer full: #4, #163, #164, #223 are ready) until 2026-10-10T04:00:00Z
Author
Collaborator

[loop:torbscript] claim refine by session:loop-torbscript-20261023 until 2026-10-23T08:26:00Z

[loop:torbscript] claim refine by session:loop-torbscript-20261023 until 2026-10-23T08:26:00Z
Author
Collaborator

[loop:torbscript] refine: too big for one decision, split just in time. Questions 1 (exact 64-bit Int in JavaScript) and 3 (browser capability split) are technical design choices the loop decides with research: filed as #417 (labels loop, ready; docs-only change to JAVASCRIPT-AND-PHP.md, no seed). No duplicate found (keyword search over open and closed issues: only #62 to #66). #62 now holds only question 2, the oldest supported PHP version, with tightened acceptance criteria and no ready.

[loop:torbscript] owner decision: the oldest supported PHP version is a public support commitment, so the loop does not take it. Facts (php.net supported versions, 2026-10-23): Fibers exist from 8.1, so no state-machine fallback is needed for any version in the table; 8.1 has no security support since 2025-12-31; 8.2 security support until 2026-12-31; 8.3 until 2027-12-31; 8.4 until 2028-12-31; 8.5 until 2029-12-31. A higher floor means fewer shared hosts qualify, but a simpler and safer back end. Options: 8.1, 8.2, 8.3. Recommendation: PHP 8.2 (Fibers, still receives security fixes, reaches most hosts). The blocking question_ask block could not be filed: tasks-mcp answers "Repo torbscript/language not found or no access" for git.torb.dev, so the owner is asked via the TorbScript group and the answer is recorded here as [loop:torbscript] owner decision recorded (torben, <date>): .... Not blocked meanwhile: #417 unblocks #63 and the browser part of #65; #64 waits on this.

next: waiting (owner decision, PHP version); #417 ready.

Worker usage: refine inline, no sub-worker.

[loop:torbscript] refine: too big for one decision, split just in time. Questions 1 (exact 64-bit `Int` in JavaScript) and 3 (browser capability split) are technical design choices the loop decides with research: filed as #417 (labels `loop`, `ready`; docs-only change to JAVASCRIPT-AND-PHP.md, no seed). No duplicate found (keyword search over open and closed issues: only #62 to #66). #62 now holds only question 2, the oldest supported PHP version, with tightened acceptance criteria and no `ready`. [loop:torbscript] owner decision: the oldest supported PHP version is a public support commitment, so the loop does not take it. Facts (php.net supported versions, 2026-10-23): Fibers exist from 8.1, so no state-machine fallback is needed for any version in the table; 8.1 has no security support since 2025-12-31; 8.2 security support until 2026-12-31; 8.3 until 2027-12-31; 8.4 until 2028-12-31; 8.5 until 2029-12-31. A higher floor means fewer shared hosts qualify, but a simpler and safer back end. Options: 8.1, 8.2, 8.3. Recommendation: PHP 8.2 (Fibers, still receives security fixes, reaches most hosts). The blocking `question_ask` block could not be filed: tasks-mcp answers "Repo torbscript/language not found or no access" for git.torb.dev, so the owner is asked via the TorbScript group and the answer is recorded here as `[loop:torbscript] owner decision recorded (torben, <date>): ...`. Not blocked meanwhile: #417 unblocks #63 and the browser part of #65; #64 waits on this. next: waiting (owner decision, PHP version); #417 ready. Worker usage: refine inline, no sub-worker.
Author
Collaborator

[loop:torbscript] claim refine by session:loop-torbscript-20261024 until 2026-10-24T09:10:00Z

[loop:torbscript] claim refine by session:loop-torbscript-20261024 until 2026-10-24T09:10:00Z
Author
Collaborator

[loop:torbscript] refine: #417 landed on main (PR #418, merge 119cd8f6): questions 1 and 3 are in section 2 of JAVASCRIPT-AND-PHP.md (2a, 2b), section 3 keeps only the PHP question. Question 2 (oldest supported PHP version) is still open and truly an owner question (public support commitment); the facts and options from the earlier owner-decision comment still hold (php.net, checked 2026-10-23): Fibers exist from 8.1, so no state-machine fallback is needed for any option.

Options: PHP 8.1 (no security support since 2025-12-31), 8.2 (security support to 2026-12-31), 8.3 (to 2027-12-31). Recommendation: 8.2. No new question_ask block is filed (tasks-mcp has no access to this repo); the owner is asked via the TorbScript group, and the answer is recorded here as [loop:torbscript] owner decision recorded (torben, <date>): .... After that, a docs step (one docs(design) commit, PHP row moved from section 3 to section 2, PHP column of the table filled in) is filed just in time.

next: waiting (owner decision, PHP version).

Worker usage: refine sub-worker, about 45k tokens.

[loop:torbscript] refine: #417 landed on main (PR #418, merge 119cd8f6): questions 1 and 3 are in section 2 of JAVASCRIPT-AND-PHP.md (2a, 2b), section 3 keeps only the PHP question. Question 2 (oldest supported PHP version) is still open and truly an owner question (public support commitment); the facts and options from the earlier owner-decision comment still hold (php.net, checked 2026-10-23): Fibers exist from 8.1, so no state-machine fallback is needed for any option. Options: PHP 8.1 (no security support since 2025-12-31), 8.2 (security support to 2026-12-31), 8.3 (to 2027-12-31). Recommendation: 8.2. No new `question_ask` block is filed (tasks-mcp has no access to this repo); the owner is asked via the TorbScript group, and the answer is recorded here as `[loop:torbscript] owner decision recorded (torben, <date>): ...`. After that, a docs step (one `docs(design)` commit, PHP row moved from section 3 to section 2, PHP column of the table filled in) is filed just in time. next: waiting (owner decision, PHP version). Worker usage: refine sub-worker, about 45k tokens.
Author
Collaborator

[loop:torbscript] refine: the PHP floor question was sent to Torben in the TorbScript group on 2026-10-29T19:50Z (options 8.1, 8.2, 8.3; recommendation 8.2; tasks-mcp has no access to this repo, so no question_ask block). The answer is recorded here as [loop:torbscript] owner decision recorded (torben, <date>): ....
next: waiting (owner decision, PHP version; asked 2026-10-29)

[loop:torbscript] refine: the PHP floor question was sent to Torben in the TorbScript group on 2026-10-29T19:50Z (options 8.1, 8.2, 8.3; recommendation 8.2; tasks-mcp has no access to this repo, so no question_ask block). The answer is recorded here as `[loop:torbscript] owner decision recorded (torben, <date>): ...`. next: waiting (owner decision, PHP version; asked 2026-10-29)
Author
Collaborator

[loop:torbscript] refine: re-checked 2026-10-29T20:10Z: no answer yet. Next ask is due on 2026-10-30T08:00:00Z if still open.
next: waiting (owner decision, PHP version) until 2026-10-30T08:00:00Z

[loop:torbscript] refine: re-checked 2026-10-29T20:10Z: no answer yet. Next ask is due on 2026-10-30T08:00:00Z if still open. next: waiting (owner decision, PHP version) until 2026-10-30T08:00:00Z
Author
Collaborator

[loop:torbscript] wait: second ask for the PHP floor (8.1/8.2/8.3, recommendation 8.2) sent to Torben in the TorbScript group on 2026-10-30T08:05Z; still no answer. Next ask is due on 2026-10-31T08:00:00Z if still open.
next: waiting (owner decision, PHP version) until 2026-10-31T08:00:00Z

[loop:torbscript] wait: second ask for the PHP floor (8.1/8.2/8.3, recommendation 8.2) sent to Torben in the TorbScript group on 2026-10-30T08:05Z; still no answer. Next ask is due on 2026-10-31T08:00:00Z if still open. next: waiting (owner decision, PHP version) until 2026-10-31T08:00:00Z
Author
Collaborator

[loop:torbscript] owner decision recorded (torben, 2026-10-30): "Ich will alle Versionen unterstützen, die auch auf dem letzten Drecks-5€-Webspace noch laufen. PHP/JS ist ja für uns nur Compilation Target und Sicherheitsprobleme können wir durch TorbScript Mechanismen umgehen (z.B. manche inbuilts nicht nutzen etc.)"

Resolution:

  • None of the offered options (8.1/8.2/8.3). The floor is the oldest PHP version that cheap shared hosts still run today, not php.net's support window. PHP is a compilation target; host-level security support is not a criterion. Unsafe or missing builtins are avoided or polyfilled by the generated code and runtime.
  • Consequence already foreseen in section 1: below 8.1 there are no Fibers, so tasks compile to the IR's state machines (as in the C back end) on the stream_select loop.
  • Orion is surveying current shared hosters (IONOS, STRATO, ALL-INKL, Hostinger, netcup, Hetzner, others) and W3Techs to fix the concrete version; the number and sources follow here. Then a docs step moves the PHP row from section 3 to section 2 and fills the PHP column of 2b.

Status: decided (principle), no longer waiting on the owner. Stop re-asking.

[loop:torbscript] owner decision recorded (torben, 2026-10-30): "Ich will alle Versionen unterstützen, die auch auf dem letzten Drecks-5€-Webspace noch laufen. PHP/JS ist ja für uns nur Compilation Target und Sicherheitsprobleme können wir durch TorbScript Mechanismen umgehen (z.B. manche inbuilts nicht nutzen etc.)" Resolution: - None of the offered options (8.1/8.2/8.3). The floor is the oldest PHP version that cheap shared hosts still run today, not php.net's support window. PHP is a compilation target; host-level security support is not a criterion. Unsafe or missing builtins are avoided or polyfilled by the generated code and runtime. - Consequence already foreseen in section 1: below 8.1 there are no Fibers, so tasks compile to the IR's state machines (as in the C back end) on the `stream_select` loop. - Orion is surveying current shared hosters (IONOS, STRATO, ALL-INKL, Hostinger, netcup, Hetzner, others) and W3Techs to fix the concrete version; the number and sources follow here. Then a docs step moves the PHP row from section 3 to section 2 and fills the PHP column of 2b. Status: decided (principle), no longer waiting on the owner. Stop re-asking.
Author
Collaborator

[loop:torbscript] claim implement by session:loop-torbscript-20261030 @anthropic:theorben until 2026-10-30T11:36:01Z

[loop:torbscript] claim implement by session:loop-torbscript-20261030 @anthropic:theorben until 2026-10-30T11:36:01Z
Author
Collaborator

[loop:torbscript] refine: proposed floor PHP 5.6. Checked 2026-10-30.

Owner principle applied literally: the oldest PHP that budget shared hosts still let a new customer select today.

Evidence

Why 5.6 and not 7.4: two budget hosts (IONOS, Hetzner) really offer 5.6 today, and 5.x is still 7.6 % of PHP sites. 7.4 is the common denominator of every host read, so it is the fallback if the owner does not want to pay for the EOL tail: it changes only the list below, not the design. At 5.6 the only cost falls on generated code and the runtime, never on the TorbScript source.

What the generated code cannot assume at 5.6 (7.4 in brackets where it differs)

  • No Fibers (8.1) at any floor below 8.1: tasks are the IR state machines on the stream_select loop; ext-uv/ext-ev and Fibers stay optional accelerators.
  • No enums, readonly, first-class callables, never, new in initializers (8.1); no match, named arguments, nullsafe ?->, union types, attributes, str_contains (8.0); no typed properties and arrow functions (7.4, available at 7.4).
  • Also, below 7.0: no scalar or return types, ??, <=>, intdiv, random_int/random_bytes, anonymous classes, PHP_INT_MIN, and no Error/Throwable: a type error or a division by zero is a fatal error, not an exception. The generated code therefore checks explicitly (zero divisor, overflow) and panics through its own runtime function, and the runtime polyfills what it needs; it does not rely on the host's.
  • Integers are 32 bit on a 32-bit build (PHP_INT_SIZE 4) and overflow into float silently at any version: an exact 64-bit Int and its overflow panic come from the runtime's checks on every arithmetic operator, never from the host; whether a 32-bit build is refused or gets a software 64-bit path is left to the back end's design.

next: PR #686 (loop/62-php-floor) moves the PHP row into section 2 of docs/design/JAVASCRIPT-AND-PHP.md and fills the PHP column of table 2b; review by argus.

[loop:torbscript] refine: proposed floor **PHP 5.6**. Checked 2026-10-30. Owner principle applied literally: the oldest PHP that budget shared hosts still let a new customer select today. **Evidence** - IONOS (Web Hosting): PHP 5.6 is still selectable under the paid "PHP Extended Support"; its end-of-life table lists 5.6 (Dec 2018) through 8.1 (Dec 2025), and contracts from before 2026-07-20 even keep 4.0 to 5.5. https://www.ionos.com/help/hosting/troubleshooting-for-php/ionos-php-extended-support/ - Hetzner (Managed Webhosting): the file-ending switch offers `.php56` (PHP 5.6), `.php73`, `.php74` and `.php80` to `.php85`. https://docs.hetzner.com/managed/webserver/php-configuration/ - STRATO: versions up to 8.1 are only available through the paid PHP Extended Support (8.1 from 2026-03-02); their lowest version was not read. https://www.strato.de/faq/hosting/was-ist-der-strato-php-extended-support/ - netcup: PHP 7.3 and later need the proxy mode (FastCGI); the oldest version was not re-verified. https://www.netcup.com/de/helpcenter/dokumentation/webhosting/php-einstellungen - W3Techs, PHP major versions among sites with known PHP: 8 = 65.8 %, 7 = 26.5 %, 5 = 7.6 %. https://w3techs.com/technologies/details/pl-php - Not read: Hostinger (help center answered HTTP 429 on every try), ALL-INKL (no version list on its public pages: https://all-inkl.com/wichtig/faq/php). **Why 5.6 and not 7.4:** two budget hosts (IONOS, Hetzner) really offer 5.6 today, and 5.x is still 7.6 % of PHP sites. 7.4 is the common denominator of every host read, so it is the fallback if the owner does not want to pay for the EOL tail: it changes only the list below, not the design. At 5.6 the only cost falls on generated code and the runtime, never on the TorbScript source. **What the generated code cannot assume at 5.6** (7.4 in brackets where it differs) - No Fibers (8.1) at any floor below 8.1: tasks are the IR state machines on the `stream_select` loop; `ext-uv`/`ext-ev` and Fibers stay optional accelerators. - No enums, `readonly`, first-class callables, `never`, `new` in initializers (8.1); no `match`, named arguments, nullsafe `?->`, union types, attributes, `str_contains` (8.0); no typed properties and arrow functions (7.4, available at 7.4). - Also, below 7.0: no scalar or return types, `??`, `<=>`, `intdiv`, `random_int`/`random_bytes`, anonymous classes, `PHP_INT_MIN`, and no `Error`/`Throwable`: a type error or a division by zero is a fatal error, not an exception. The generated code therefore checks explicitly (zero divisor, overflow) and panics through its own runtime function, and the runtime polyfills what it needs; it does not rely on the host's. - Integers are 32 bit on a 32-bit build (`PHP_INT_SIZE` 4) and overflow into `float` silently at any version: an exact 64-bit `Int` and its overflow panic come from the runtime's checks on every arithmetic operator, never from the host; whether a 32-bit build is refused or gets a software 64-bit path is left to the back end's design. next: PR https://git.torb.dev/torbscript/language/pulls/686 (`loop/62-php-floor`) moves the PHP row into section 2 of `docs/design/JAVASCRIPT-AND-PHP.md` and fills the PHP column of table 2b; review by argus.
Author
Collaborator

[loop:torbscript] release: worker finished. PR #686 (head 49b50076, one docs(design) commit) records the floor as PHP 5.6 by the owner rule (oldest version still selectable at budget hosts; IONOS Extended Support, Hetzner Managed Webhosting), with 7.4 named as the fallback common to every host checked. Argus requested.
next: waiting (CI and review of PR #686)

[loop:torbscript] release: worker finished. PR #686 (head 49b50076, one docs(design) commit) records the floor as PHP 5.6 by the owner rule (oldest version still selectable at budget hosts; IONOS Extended Support, Hetzner Managed Webhosting), with 7.4 named as the fallback common to every host checked. Argus requested. next: waiting (CI and review of PR #686)
argus closed this issue 2026-10-30 09:51:32 +00:00
Sign in to join this conversation.
No labels
loop
ready
No project
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.

Dependencies

No dependencies set

Reference
torbscript/language#62
No description provided.