Language Change PR-4.3-dev Pending

User tests: Successful: Unsuccessful:

avatar brianteeman
brianteeman
2 Feb 2023

Pull Request for Issue #39711 .

Summary of Changes

When the php fileinfo module is not installed then media manager will give the following error

Error Property 'mime_type' of argument 'item' of event onFetchMediaItems has a wrong item. Valid: string

This PR adds a check for the php fileinfo module and displays a more helpful error message

The Fileinfo PHP module is not installed. You should contact the server administrator to install it.

Testing Instructions

To display the error message
Either disable the fileinfo module in your php.ini and open the media manager
or edit the check to reverse it so it shows when the module is present by removing the ! in (!\extension_loaded('fileinfo')) {

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

There may be changes required in the docblock - no idea

avatar joomla-cms-bot joomla-cms-bot - change - 2 Feb 2023
Category Administration com_media Language & Strings
avatar brianteeman brianteeman - open - 2 Feb 2023
avatar brianteeman brianteeman - change - 2 Feb 2023
Status New Pending
avatar brianteeman brianteeman - change - 2 Feb 2023
The description was changed
avatar brianteeman brianteeman - edited - 2 Feb 2023
avatar brianteeman brianteeman - change - 2 Feb 2023
Labels Added: Language Change PR-4.3-dev
avatar sandewt sandewt - test_item - 3 Feb 2023 - Tested successfully
avatar sandewt
sandewt - comment - 3 Feb 2023

I have tested this item successfully on 069e062


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/39777.

avatar Quy Quy - test_item - 3 Feb 2023 - Tested successfully
avatar Quy
Quy - comment - 3 Feb 2023

I have tested this item successfully on 069e062


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/39777.

avatar Quy Quy - change - 3 Feb 2023
Status Pending Ready to Commit
avatar Quy
Quy - comment - 3 Feb 2023

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/39777.

avatar Quy Quy - change - 3 Feb 2023
Labels Added: ?
avatar SharkyKZ
SharkyKZ - comment - 3 Feb 2023

This makes no sense.

avatar brianteeman
brianteeman - comment - 3 Feb 2023

This makes no sense.

maybe not but would you care to explain why, please

avatar bembelimen
bembelimen - comment - 3 Feb 2023

There are several "problems" with this check.

  1. This added check does not validate the file (what the event is about) but it validates the system it's running on.
  2. You assume, that the file is generated via the LocalAdapter, which is not always the case
  3. There are more mime checker than "fileinfo", so although this could be disabled, others could work
  4. The error is not in this event but you have to fix it here
avatar bembelimen bembelimen - change - 3 Feb 2023
Status Ready to Commit Pending
avatar bembelimen
bembelimen - comment - 3 Feb 2023

Remove RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/39777.

avatar brianteeman
brianteeman - comment - 3 Feb 2023

Such an unfriendly reply. Not worth my time explaining where you are mistaken

avatar brianteeman brianteeman - change - 3 Feb 2023
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2023-02-03 16:08:09
Closed_By brianteeman
Labels Removed: ?
avatar brianteeman brianteeman - close - 3 Feb 2023
avatar HLeithner
HLeithner - comment - 3 Feb 2023

Such an unfriendly reply. Not worth my time explaining where you are mistaken

Tbh but this was unfriendly and not that Benjamin explained you why this pr is wrong in a normal language.

avatar brianteeman
brianteeman - comment - 3 Feb 2023

wouldnt expect anything less

avatar C-Lodder
C-Lodder - comment - 19 Apr 2023

Incase anyone decides to work on this, might also be worth adding it to the recommended settings on the pre-update check page:

image

avatar brianteeman
brianteeman - comment - 19 Apr 2023

According to @bembelimen there are better ways to do this and do not need the fileinfo module

avatar jfeedback
jfeedback - comment - 19 Apr 2023

Making sure I've got this right. The code now relies on a PHP extension which isn't documented as required with a message proposed to at least inform users about things not working if that extension isn't installed 76 days before release. It was shot down as "not right", with a senior developer saying there are better solutions, and in those 76 days, nobody could come up with any of those better solutions. And, everyone is OK with this?

avatar obuisard
obuisard - comment - 6 May 2023

@jfeedback Granted that we need to find a suitable answer to this problem as soon as possible. However, shaming the team of developers is surely not going to help. You are welcome to contribute to a solution, even if you are not a developer (as a user, what would you consider a helpful solution here?).

Add a Comment

Login with GitHub to post a comment