Skip to content

Idempotent build: configure.php - #202

Merged
alfsb merged 5 commits into
php:masterfrom
alfsb:idempotent3
Dec 10, 2024
Merged

Idempotent build: configure.php#202
alfsb merged 5 commits into
php:masterfrom
alfsb:idempotent3

Conversation

@alfsb

@alfsbalfsb commented Dec 8, 2024

Copy link
Copy Markdown
Member

This PR does a few clean ups, creates functions for consistent loading and reloading of manual XML saves all intermediary and final XML on temp/, and changes error reporting.

The reloading of XML is necessary to validation and file/line/column information works correctly, The error message causes build failures like this:

 Opening and ending tag mismatch: para line 19 and par

to be reported like this:

[FATAL 26:10] Opening and ending tag mismatch: para line 19 and par
[FATAL 27:1] chunk is not well balanced
[FATAL en/appendices/migration56/incompatible.xml 87:42] Entity 'migration56.openssl.peer-verification' failed to parse
[FATAL en/appendices/migration56/incompatible.xml 144:1] chunk is not well balanced
[FATAL en/appendices/migration56.xml 24:39] Entity 'appendices.migration56.incompatible' failed to parse
[FATAL en/appendices/migration56.xml 54:1] chunk is not well balanced
[FATAL zpr-doc-base/manual.xml 443:27] Entity 'appendices.migration56' failed to parse

That's right. We now have contextual, call stack-like error messages for errors inside of entities. How nice is this?

@alfsb
alfsb marked this pull request as ready for review December 9, 2024 13:14
@alfsb
alfsb requested a review from GirgiasDecember 9, 2024 13:14

@GirgiasGirgias left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is pretty cool!

Comment threadconfigure.php Outdated
Comment threadconfigure.php Outdated
@alfsbalfsb mentioned this pull request Dec 9, 2024
47 tasks
@alfsb
alfsb merged commit 4309883 into php:masterDec 10, 2024
@alfsb

Copy link
Copy Markdown
MemberAuthor

Merged. The CI errors are unrelated as far I can see.

git mv reference/spl/countable.xml to language/predefined/countable.xml and update the entity reference at end of XML.

@alfsb
alfsb deleted the idempotent3 branch December 10, 2024 21:33
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@alfsb@Girgias