Skip to content

Read the phino 0.0.145 protocol under its new <protocol> root - #9078

Merged
yegor256 merged 2 commits into
masterfrom
9077
Oct 1, 2026
Merged

yegor256 merged 2 commits into
masterfrom
9077

Conversation

@yegor256

@yegor256 yegor256 commented Oct 1, 2026

Copy link
Copy Markdown
Member

Closes #9077.

phino 0.0.145 changed the root of its XML protocol. The judgment now sits one level down, inside <protocol>, and the totals <msec>, <firings> and <fps> sit beside it. rendering.xsl was still reading from the old root, so once the pin moved, every entry would have come out as a taint that "came to no root". The fix is one path, repeated in three places:

<xsl:variable name="root" select="$eo:doc/protocol/morph/evaluate[@λ = 'L_root']/dataize[starts-with(@meta, '𝛿1.')][last()]"/>

phino-version.txt moves to 0.0.145. Every render pack, and every stub protocol in MorphingTest, PhinoTest and MjLowerTest, now has the new shape. Before the stylesheet changed, nine render packs failed with "came to no root", which is exactly the symptom from the issue. After it, all of them pass.

I also ran the stylesheet on two protocols that phino 0.0.145 wrote from the real eo-runtime world. Φ.buffer still renders into its atom, and Φ.true gets the expected reason: it always gives the constant FF-. The timeout checks needed no change, because Phino searches for <timeout as text and rendering.xsl uses //timeout. Nothing reads the new totals yet.

…> root

phino 0.0.145 wraps the judgment in a <protocol> root, with <msec>,
<firings> and <fps> beside it. The stylesheet now reads
$eo:doc/protocol/morph, the pin moves to 0.0.145, and every test protocol
takes the new shape.
Copilot AI balanced review requested due to automatic review settings October 1, 2026 14:16

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Four timeout stubs omit the mandatory firings and fps totals from the new protocol format.

Review effort: Balanced
Findings: 3 Medium severity

Open (3)
What changed in this PR

Updates lowering to consume phino 0.0.145’s <protocol> XML envelope.

Changes:

  • Reads judgments from /protocol/morph.
  • Updates render packs and timeout fixtures.
  • Pins phino 0.0.145.
File Description
eo-maven-plugin/​src/​test/​java/​org/​eolang/​maven/​MjLowerTest.java Updates protocol stubs.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​bytes-a-plus-takes-are-read-as-a-number.yaml Wraps protocol and adds totals.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-with-no-root-is-a-taint.yaml Updates no-root fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-whose-body-is-bottom-is-a-taint.yaml Updates bottom-body fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-that-is-always-a-constant-is-a-taint.yaml Updates constant fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-stopped-at-bottom-is-a-taint.yaml Updates stopped fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-out-of-time-is-a-taint.yaml Updates timeout fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-left-unfinished-is-a-taint.yaml Updates unfinished fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​an-entry-inside-an-application-is-a-taint.yaml Updates nested-entry fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​a-void-root-is-returned-as-the-object.yaml Updates void-root fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​a-symbol-nothing-defines-is-a-taint.yaml Updates undefined-symbol fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​a-lambda-the-table-lacks-is-a-taint.yaml Updates missing-lambda fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​a-joined-symbol-is-assigned-in-an-if.yaml Updates joined-symbol fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​a-firing-one-branch-needs-stays-in-that-branch.yaml Updates branch fixture.
eo-lowering/​src/​test/​resources/​org/​eolang/​lowering/​render-packs/​a-firing-is-one-statement.yaml Updates firing fixture.
eo-lowering/​src/​test/​java/​org/​eolang/​lowering/​PhinoTest.java Updates timeout output stub.
eo-lowering/​src/​test/​java/​org/​eolang/​lowering/​MorphingTest.java Updates timeout protocol stubs.
eo-lowering/​src/​main/​resources/​org/​eolang/​lowering/​rendering.xsl Reads morph data beneath <protocol>.
eo-lowering/​src/​main/​resources/​org/​eolang/​lowering/​phino-version.txt Pins phino 0.0.145.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@@ -106,7 +106,7 @@ void keepsTheProtocolOfARunOutOfItsBudget(@Mktmp final Path temp)
String.join(
" ",
"for a; do case $a in --protocol=*) p=${a#--protocol=};; esac; done;",
"echo '<morph><timeout limit=\"1\"/></morph>' > \"$p\"; exit 1"
"echo '<protocol><morph><timeout limit=\"1\"/></morph><msec>1000</msec></protocol>' > \"$p\"; exit 1"
@@ -107,7 +107,7 @@ void reportsAMorphingThatRanOutOfItsBudget(@Mktmp final Path temp) throws IOExce
PhinoTest.binary(
temp,
"for a; do case $a in --protocol=*) p=${a#--protocol=};; esac; done;",
"echo '<morph><timeout limit=\"2\"/></morph>' > \"$p\"; exit 1"
"echo '<protocol><morph><timeout limit=\"2\"/></morph><msec>2000</msec></protocol>' > \"$p\"; exit 1"
@@ -186,7 +186,7 @@ void keepsTheProtocolOfARunOutOfTheBudgetItWasGiven(@Mktmp final Path temp)
.execute(MjParse.class)
.with("lowering", true)
.with("budget", 1)
.with("binary", MjLowerTest.binary(temp, 1, "<morph><timeout limit=\"1\"/></morph>"))
.with("binary", MjLowerTest.binary(temp, 1, "<protocol><morph><timeout limit=\"1\"/></morph><msec>1000</msec></protocol>"))
@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

These counts changed in this branch,
while the lower each one of them, the better:

Metric master branch change
statics 759 760 +1

They are defined in .github/workflows/counts.yml

@github-actions github-actions Bot added the counts Some counts changed in this PR label Oct 1, 2026
@sonarqubecloud

sonarqubecloud Bot commented Oct 1, 2026

Copy link
Copy Markdown

@yegor256
yegor256 merged commit aea49ac into master Oct 1, 2026
22 of 24 checks passed
@yegor256
yegor256 deleted the 9077 branch October 1, 2026 15:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

counts Some counts changed in this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

rendering.xsl reads /morph as the protocol root, which phino 0.0.145 moved under <protocol>

2 participants