Skip to content

Migrate PHP Documentation schema to DocBook 5.2 #3326

@Girgias

Description

@Girgias

DocBook 5.2 has finally been released: https://www.oasis-open.org/2024/02/13/the-docbook-schema-version-5-2-oasis-standard-published/

The primary motivation to migrate to this new version is to be able to use the new <enumsynopsis> tag.

However, there a some issues with the current documentation which makes this migration challenging.

RelaxNG Schema

The new schema is only provided as a RelaxNG schema, whereas most of our tooling expects a DTD.
I have made progress in checking the documentation against it, but this required compiling jing-trang locally to check what is causing issues. It is likely we will need to have this on CI somehow to improve the debugging experience for new contributors.

Legacy custom markup

Classes, Interfaces, and Exceptions use a custom phpdoc: tag, and need to be converted to a structure that fits the DocBook schema, I have written a script that converts the relevant files to a new markup, but this does not validate the schema yet.

Turns out jumping directly to DocBook 5.2 simplifies some stuff as we just need to replace those tags with <reference>.

However, our "new" markup for extending classes/implementing interfaces doesn't comply :(
There seems to either be a bug in the DocBook 5.2 schema, or an undocumented BC break. Trying to contact the relevant people about this issue.

Minor schema violation issues

Various files do not follow the DocBook schema properly and need to be fixed some bigger issues are:

Migration Procedure

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions