Harden template render pipeline with precise syntax diagnostics and SAPI-safe linting#1
Draft
Copilot wants to merge 10 commits into
Draft
Harden template render pipeline with precise syntax diagnostics and SAPI-safe linting#1Copilot wants to merge 10 commits into
Copilot wants to merge 10 commits into
Conversation
Copilot created this pull request from a session on behalf of
beobles
May 27, 2026 02:06
View session
Copilot
AI
changed the title
Stabilize template engine pipeline (lexer/parser/compiler) and harden runtime path/cache handling
refactor: self-compiling nodes, NodeVisitor pattern, thin Compiler orchestrator
May 27, 2026
Copilot
AI
changed the title
refactor: self-compiling nodes, NodeVisitor pattern, thin Compiler orchestrator
Remove May 27, 2026
Beobles namespace prefix and standardize on Core\View
Copilot
AI
changed the title
Remove
Handle May 27, 2026
Beobles namespace prefix and standardize on Core\Viewextends/import directives as full statements during lexing
Copilot
AI
changed the title
Handle
Implement real May 27, 2026
extends/import directives as full statements during lexingextends inheritance and correct <Block> rendering semantics
Copilot
AI
changed the title
Implement real
Fix template inheritance caching: invalidate child cache on parent layout changes
May 27, 2026
extends inheritance and correct <Block> rendering semantics
Copilot
AI
changed the title
Fix template inheritance caching: invalidate child cache on parent layout changes
Fortalecer herança/caching de templates e endurecer parser/lexer para sintaxe confiável
May 27, 2026
Copilot
AI
changed the title
Fortalecer herança/caching de templates e endurecer parser/lexer para sintaxe confiável
Replace eval-based template rendering with compiled-file execution
May 27, 2026
Copilot
AI
changed the title
Replace eval-based template rendering with compiled-file execution
Harden template rendering with pre-include syntax validation and precise SyntaxException reporting
May 27, 2026
Copilot
AI
changed the title
Harden template rendering with pre-include syntax validation and precise SyntaxException reporting
Harden template render pipeline with precise syntax diagnostics and SAPI-safe linting
May 27, 2026
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.
Rendering failures were surfacing as low-signal PHP fatals, and the new pre-render lint step could misclassify Apache/mod_php process output as template syntax errors on Windows. This update makes template execution safer and ensures syntax errors are reported with actionable location details only when they are real PHP parse failures.
Execution model hardening
evalexecution with compiled-file materialization (tpl_<sha256>.php) + isolatedincludescope.Pre-render syntax diagnostics
SyntaxExceptionnow includes: compiled file path, line, column (best-effort), source snippet, and parser output.SAPI-safe lint command resolution
PHP_BINARYonly if it is actually a PHP executable, thenPHP_BINDIR/php(.exe), then PATH fallback).AH02965) to avoid false-positiveSyntaxExceptionin web SAPIs.Error boundary consistency
\Throwableduring render path wrapping, so parse/runtime errors are normalized intoViewExceptionwith original cause chaining.