Hi,

pb with new version on my menu : each "update.php" multiplies menu links on my main menu; where I had 10 links described, I end up with 20 or more links that I have to manually deactivate and I have to do it every "update.php" because they reactivate themselves; I have no idea how to remove these links.. the site becomes unmanageable

 

 

Comments

@ - I don't have an answer for you and you are the first to report any problems. I've passed a link to this post along to other core developers and hopefully someone will have an idea very soon for you. 

I'll do some testing to see if I can replicate this problem. 

Hi, sorry for your troubles.

I'm trying to recreate your issue on my test site. I haven't been able to so far. This is what I did:

Created a fresh Backdrop site with version 1.20.3. Added some pages and added them to the Primary Navigation. It's a mono-lingual site with no contributed modules enabled.

I then upgraded the site 1.21.0 and ran upgrade.php. Cleared all caches. The same number of menu items in the primary navigation. No duplicates.

So there might be some other contributed module that's helping to cause your issue. Or perhaps the site was an upgrade from Drupal 7 and there's some odd configuration still around?

You mention "each update.php". Does that mean this has been happening with previous code upgrades as well?

I wish you luck in tracking this down.

Hi,

i am not a dev so no code upgrade for me; this trouble occurs only with the 1.21 version ..and not at all with the previous one.

This site was created from scratch; i had an equivalent site under drupal 7 but i have choosen to recreate one with the same functions ...

It is also a mon-lingual site.

apparently a simple "clean cache" is enough to multiply the menu items

luckily I'm with a host with which it's very easy to restore the previous day's version; as I'm on a production site, I restored the site with version 1.20 and no more problem, I couldn't leave the site as it was..

klonos's picture

Hello @philippeg 👋

Sorry this is giving you a hard time. Can you please post a list of the contributed modules that you have enabled on the site?

Another option you can consider is to join us during our weekly Office Hours, where we can troubleshoot this together.

I have pretty much the same phenomenon on another site related to migrating to 1.21: when I disable a link from a menu and purge the cache afterwards, the link re-enables itself..and if I continue to purge the cache the links multiply each time

Do the sites have all the same modules enabled? If not which are common between the two sites?

a lot are common difficult to say it can take hours to test ... what kind of module can have this effect ? What is the link between a cache cleaner module and a menu ?

Is it possible to narrow the scope of searches

Personally I’d start with any menu related modules, turn them off one by one and see if it changes the behaviors.

ok but what can be the link with a cache cleaner ?

Maybe the menu gets rebuilt when the cache is cleared and there’sa conflict in the menu rebuilding function — or something like that.

I tried to deactivate each menu related module without success ...

i saw in the release notice something about

[PS] Optimize menu_navigation_links_rebuild() #5389

is that can be related ?

Can you navigate to admin/structure/menu/ , open the Primary Navigation menu (click Manage links) and check if you see duplications in that listing of links? (I assume that the menu shown on your screenshot is the Primary Navigation).

What theme are you using? Are you using the Layout API to display the menu on your home page, or is this menu "hard printed" by your theme? Check the home page layout by visiting admin/structure/layouts and clicking on Manage blocks for the Home page. Check if a Primary Navigation block is actually included there in the Header or another region.

Like others in this thread, I think that this is the result of some unexpected interaction with a contrib module. I'm wondering especially about the Menu Node API module, which creates new tables in the database. Install your site in a local environment to avoid messing it up further, and try to disable that module (you'll need to disable MEnu Node Views first). Then clear caches and check if that does anything. 

 

"Can you navigate to admin/structure/menu/ , open the Primary Navigation menu (click Manage links) and check if you see duplications in that listing of links? (I assume that the menu shown on your screenshot is the Primary Navigation)." yes a lot of lines duplicated.

"What theme are you using? Are you using the Layout API to display the menu on your home page, or is this menu "hard printed" by your theme? Check the home page layout by visiting admin/structure/layouts and clicking on Manage blocks for the Home page. Check if a Primary Navigation block is actually included there in the Header or another region." Bartik; all is ok for layers

 

ike others in this thread, I think that this is the result of some unexpected interaction with a contrib module. I'm wondering especially about the Menu Node API module, which creates new tables in the database. Install your site in a local environment to avoid messing it up further, and try to disable that module (you'll need to disable MEnu Node Views first). Then clear caches and check if that does anything." tried without effect.

On one of my site, i could stop the multiplication of links in doing this : deactivate the two modules : Menu node views and Menu node API    AND reactivate them; if i deactivate only i could not stop the multiplication of links at each cache cleaning.

But i tried to adopt the same recipe in another site without success ..

All attempts to solve this problem have proved unsuccessful; I completely stop the migration of the remaining drupal 7 sites

I think it was mentioned before, but if you are able to come to office hours or weekly meetings - we might be able to be more help. 

https://backdropcms.org/news/events

This seems like a hard one to diagnose in the forum. So far, we haven't gotten another other reports of a similar problem.

:-(

maybe but i can't do nothing i have tried to inactivate 80% of contrib module for nothing .. that i see it's before the update i have no problem; it can come from a contrib module but you have always a contrib module on a site how to find the good one; one ask me to put on the forum the list of the contrib module i have done this  .. 

 

A great relief, I tried everything I could depending on my skills without success; in a last test, i disabled 99% of the "contrib" modules without success either...and and yes when you read the information on the new release there is indeed a menu reconstruction function added or modified  https://github.com/backdrop/backdrop-issues/issues/5389

Thanks

indigoxela's picture

@philippeg this abécédaire page of which the menu items get duplicated - what sort of page is that? Is it a view or some module provided page?

If it's a view: does it have a menu item set by the views UI?

If it's a module - a public contrib one, or a custom one? Does it implement hook_menu?

i am not a dev so certainly not a custom; you have to know that when this occurs all kind of menu items are duplicated and i have this problem on site where this abécédaire doesn't exist; here it is a link that use semantic views

an exemple

and i have done test with others menus on the same site and i have duplicates links too ..

indigoxela's picture

Many thanks for the infos.

 

have this problem on site where this abécédaire doesn't exist;

...

i have done test with others menus on the same site and i have duplicates links too

I didn't mean to suggest, that this exact page causes the problem - it's not your page alone, we discovered some hidden duplication.

What we still struggle with, is to reproduce the duplication of visible menu items. Being able to do that, might help to understand what exactly is going on.

So any info you provide can be helpful and is appreciated. We're planning to provide a bugfix update soon.

"What we still struggle with, is to reproduce the duplication of visible menu items."

what do you mean exactly ?

indigoxela's picture

what do you mean exactly ?

You see duplication in regular menu items (hence "visible"). We had some trouble to reproduce, but are now able to.

In the meantime we found the reason for the problem. A bugfix release will be done today or tomorrow. Stay tuned.

If you're interested in technical background information, see this issue.

And many thanks for your patience.

I tested 1.21.1; the problem has disappeared and everything seems to be working well at first sight .. Thank you it must not have been easy to correct urgently ...