Open obsergiu opened 3 weeks ago
Hi @obsergiu. Thank you for your report. To speed up processing of this issue, make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce.
@magento I am working on this
Join Magento Community Engineering Slack and ask your questions in #github channel. :warning: According to the Magento Contribution requirements, all issues must go through the Community Contributions Triage process. Community Contributions Triage is a public meeting. :clock10: You can find the schedule on the Magento Community Calendar page. :telephone_receiver: The triage of issues happens in the queue order. If you want to speed up the delivery of your contribution, join the Community Contributions Triage session to discuss the appropriate ticket.
Hi @engcom-Bravo. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:
Area: XXXXX
label to the ticket, indicating the functional areas it may be related to.2.4-develop
branch2.4-develop
branch, please, add the label Reproduced on 2.4.x
.Issue: Confirmed
once verification is complete. Hi @obsergiu,
Thanks for your reporting and collaboration.
We are Considering this as a improvement to proceed further marking this as a feature request.
Thanks.
Currently, the setValueAfterValidation method in Magento\Config\Model\Config\Backend\File.php throws a generic error message, Invalid file name, when a file name doesn't pass validation(like: default/logo.png). I think it would be better for improving this by including the actual invalid file name in the message to make it more informative.
This validation and function were introduced in Magento 2.4.6-p5, but I don't see it in the current beta version. As such it should be treated more like a reference for others who might encounter similar issues.
The code is located at: https://github.com/magento/magento2/blob/1819fe7377ab3010fc41e80f5634e9053707de65/app/code/Magento/Config/Model/Config/Backend/File.php#L283
The existing code:
Suggested change:
Including the actual file name in the error message will make it easier to understand what went wrong and help debug the issue faster.
Steps to Reproduce:
Expected Result: The error message should show the exact file name, like:
Invalid file name: "default/logo.png"
.Actual Result: Currently, it just says:
Invalid file name
.