?
avatar Ruud68
Ruud68
30 Jun 2020

Steps to reproduce the issue

In J3.9 I use \Joomla\CMS\Image\Image and get the message that it is

@deprecated 5.0 use the class \Joomla\Image\Image instead

So I use \joomla\Image\Image and then get the message that it is

@deprecated The joomla/image package is deprecated (no version no replacement stated)

In J4.0 \Joomla\Image\Image is not existing, so in J4 I can only use \Joomla\CMS\Image\Image
in J4.0 there is NO deprecation message (so NO 5.0 deprecated)

I am confused here:
What is the best image class to use for J3.9?
Will the \Joomla\CMS\Image\Image deprecate or not?

avatar Ruud68 Ruud68 - open - 30 Jun 2020
avatar joomla-cms-bot joomla-cms-bot - labeled - 30 Jun 2020
avatar ReLater
ReLater - comment - 30 Jun 2020

There is written a lot in linked issues/prs.
#23118

But TBH: I don't understand finally which use line we shall use now...

avatar mbabker
mbabker - comment - 30 Jun 2020

Joomla\CMS\Image\Image is the one to use, the Framework package was deprecated after pulling in that code in the CMS and the deprecations were never updated.

avatar Ruud68 Ruud68 - close - 30 Jun 2020
avatar Ruud68
Ruud68 - comment - 30 Jun 2020

Thanks @ReLater and @mbabker

avatar Ruud68 Ruud68 - change - 30 Jun 2020
Status New Closed
Closed_Date 0000-00-00 00:00:00 2020-06-30 12:16:48
Closed_By Ruud68
avatar zero-24
zero-24 - comment - 30 Jun 2020

@Ruud68 can you send a PR to update the deprecation message?

avatar Ruud68
Ruud68 - comment - 30 Jun 2020

I have no idea if and what the message should be. For me it is clear that I should use \Joomla\CMS\Image\Image if my extensions should work on both J3 and J4. if that will get deprecated in 5.0 or not: I do not know (according to J3 it does, according to J4 it doesn't)

avatar mbabker
mbabker - comment - 30 Jun 2020

Right now Joomla\CMS\Image\Image is not going anywhere. The deprecations in the Joomla\CMS\Image namespace that explicitly say to use the joomla/image Composer package and classes in the Joomla\Image namespace should go away. The Composer package will go EOL the same time that the 3.x CMS branch does.

What will go away in 5.0 is the class name aliases (all the non-namespaced class names). That's not changing unless someone suddenly decides "keep aliases forever".

Whether or not that API is deprecated in the lifetime of 4.x and removed in 5.0 is anyone's guess, unless you've got a crystal ball (in which case, I need to borrow it, for... reasons...).

avatar SharkyKZ
SharkyKZ - comment - 1 Jul 2020

Can un-deprecations be made in a patch release or do they have to go in a minor? Semver doesn't mention anything about such thing.

Add a Comment

Login with GitHub to post a comment