Problem/Motivation
Started encountering exceptions with Menu Link Manipulator module after installing and creating Contexts.
See this thread: https://www.drupal.org/project/menu_manipulator/issues/3251675#comment-1...
Why does the Context UI module create MenuLinkContent to represent access to a Context? They are configuration entities, can they not be listed on the admin page with an EntityListBuilder?
Patching in the change on that comment above fixes the issue in that particular module, but this could be the source of heisenbugs for other users of Context/Context UI when used in conjunction with modules that use their own menu tree manipulators or add on to the core menu tree manipulator process.
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | after-update.png | 8.04 KB | lucassc |
| #9 | before-update.png | 12.83 KB | lucassc |
Issue fork context-3280556
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
paulocsI think we can remove this functionally. It's not common to create new menu links as I see in other modules. There is already the context list page to list all contexts.
I'll work on it.
Comment #3
randalv commentedI can post this in a new issue too, but seeing as the developer said they'll remove the functionality I figured this would be the right place to post this to.
Installing context_ui and creating a new context without have menu_link_content installed throws an error:
So, if we don't remove this functionality, we should at least make menu_link_content a dependency for context_ui :-)
Comment #5
paulocsI have also created an update hook to remove all content links that are child of
entity.context.collectionmenu.Comment #6
lucasscComment #7
lucasscHi!
Good to remove this functionally, I don't think it's very common either.
I created a new context without any conditions or reactions in branch 8.x-4.x-dev and the menu link was created in /admin/structure/menu/manage/admin (see before-update.png), then I checked out the MR !30's branch, accessed /update.php to run the update hook in #5 and the menu link was removed (see after-update.png).
I think it can be moved to RTBC.
Comment #8
paulocsHey @RandalV and @kevinquillen, would you like to double check my solution?
I think its okay to create an update hook to remove all content links that are child of
entity.context.collectionmenu.Comment #9
lucasscAttaching before x after screenshots.
Comment #11
paulocs