-
Notifications
You must be signed in to change notification settings - Fork 7.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DOM extension reflection version is incorrect #8038
Comments
Oh, right, looks like that version hasn't been bumped for a long time. |
Well, on a closer look, it seems that using the |
My 2cents. Expecting it to return the PHP version does not make sense to me. The method is supposed to return version of the extension and various extensions might use it's own versioning, isn't it? But I agree that using a number that wasn't updated since 2003 is not good. @cmb69 why it should be the same as PHP_VERSION? what's the reason to have this method if it is expected to return PHP_VERSION? why it cannot happen in 8.2? |
@alecpl, few years ago most bundled extensions switched to using the PHP_VERSION, because it is hard to track their own versioning. Still it makes sense to have an own version for all extensions, just in case they will be unbundled (and moved to PECL) in the future, so they would need their own versioning. Maybe we could remove |
Hello, this bug is still not fixed in PHP 8.4.2, it is currently impossible to retrieve the version of an extension. |
XDebug has its own release cycle and thus its own versioning; bundled extensions (like ext/tidy) share the release cycle with PHP, and as such (most) have the same version as PHP – I can't see anything wrong with that. |
It doesn't appear to be reasonable to pretend that nothing in the DOM API would have changed in the last 21 years, and it's also not that reasonable to pretend that we would thoroughly bump that version in the future. Thus we go with the common convention to use the `PHP_VERSION` for bundled extensions.
Description
Getting the DOM extension version from the reflection API results in "20031129" no matter which PHP version is used: https://3v4l.org/VIJKY
I would expect it to behave like other bundled extensions and track the PHP version: https://3v4l.org/iNi1B
The following code:
Resulted in this output:
But I expected this output instead:
PHP Version
8.1.2
Operating System
No response
The text was updated successfully, but these errors were encountered: