- Issue created by @pooja_sharma
- ๐ฎ๐ณIndia prashant.c Dharamshala
Yes, there is an issue with this because the entity type that is being used for this file is
logo
which does not exist hence the error.
- ๐ฎ๐ณIndia prashant.c Dharamshala
In the
core/modules/navigation/src/Form/SettingsForm.php
the code to add/delete records uses the "logo" as the entity name
$this->fileUsage->add($new_logo_managed, 'navigation', 'logo', 1);
$this->fileUsage->delete($previous_logo_managed, 'navigation', 'logo', 1);
The file usage is a view that requires it to be an entity type
/admin/structure/views/view/files/edit/page_2
which is throwing an error.Now I am not sure whether this is a bug in the Navigation module or core itself that allows an entity name in File usage that does not even exist.
- Status changed to Needs review
2 months ago 4:27am 10 September 2024 - ๐ฎ๐ณIndia KumudB Ahmedabad
I wanted to update regarding the issue we discussed. I pulled the latest code from the 11.x branch, and I was unable to reproduce the issue locally. This behavior was consistent with the problem we encountered previously, so it seems to be resolved with the recent changes.
For reference, Iโve attached recording that demonstrate the current state of the application.
Please let me know if you need any further information or if thereโs anything else I should look into.
- Assigned to pooja_sharma
- Status changed to Needs work
2 months ago 8:15am 10 September 2024 I have taken the latest pull , however still replicable this issue, attaching the screenshots.
I tried to upload the navigation custom logo image
Then click on file menu on the left sidebar this page open, you 'll redirect to this page: admin/content/files
Click on the Usage link for this file , page break with above mentioned error.Tried to debug while calling file usage API(), correct entity type missing that causing error, working on it.
- Merge request !9459issue/3471768: Added the entity type name in file API SettingsForm โ (Open) created by pooja_sharma
- Issue was unassigned.
- Status changed to Needs review
2 months ago 1:48pm 10 September 2024 Tried to address issue & added test coverage with minimal changes in relevant existing test.
Please review, moving NR.
- Status changed to Closed: cannot reproduce
2 months ago 3:06am 11 September 2024 - ๐ฎ๐ณIndia KumudB Ahmedabad
I have closed this issue as I was unable to reproduce it with the latest pull from the 11.x branch. It appears that the issue has been resolved with recent fixes.
If anyone encounters a similar issue in the future, please feel free to open a new issue.
Thank you!
- Status changed to Needs review
2 months ago 4:13am 11 September 2024 - Status changed to Needs work
2 months ago 5:42pm 11 September 2024 - ๐จ๐ฆCanada SKAUGHT
have reviewed patch. yes oversight in original name spacing for file usage.
will also probably need an update hook to check if any update any existing entries to be updated to 'file' (as $new_logo_managed->getEntityTypeId() will equal 'file').
- Assigned to pooja_sharma
- Issue was unassigned.
- Status changed to Needs review
2 months ago 7:12am 12 September 2024 - ๐ช๐ธSpain plopesc Valladolid
Good catch!
The file usage logic should be gone as part of ๐ Store the file path instead of ID for the navigation logo Needs work , so I would prefer to focus on addressing that issue that indirectly would solve this one.
- ๐บ๐ธUnited States smustgrave
@plopesc should this continue? Or closed and credit moved over?
- Status changed to Closed: duplicate
2 months ago 8:20pm 13 September 2024 - ๐จ๐ฆCanada m4olivei Grimsby, ON
Letโs close this as a duplicate of ๐ Store the file path instead of ID for the navigation logo Needs work , and continue efforts there, and also remember to transfer credits. I'll make a note of those who contributed here on the other issue.