Newly added menu links are invisible until published

Created on 4 April 2024, over 1 year ago

Problem/Motivation

When adding a new menu link in a sub workspace, it does not show up in the UI until the change is pushed all the way to live. It looks like that was supposed to be fixed in https://www.drupal.org/project/drupal/issues/3040258 🐛 Menu link content changes are not visible on non-live workspaces Fixed . Maybe it's just not working with sub workspaces? Note that renaming a link works as expected.

Steps to reproduce

Be in a sub workspace. Add a new menu link. See that it is not in the UI. Push to stage and publish to live. See that it is now visible in the UI.

🐛 Bug report
Status

Active

Version

10.1

Component
Workspaces 

Last updated 4 months ago

No maintainer
Created by

🇺🇸United States michelle Wisconsin, USA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @michelle
  • 🇮🇹Italy apaderno Brescia, 🇮🇹
  • 🇺🇸United States damienmckenna NH, USA
  • 🇺🇸United States damienmckenna NH, USA
  • 🇷🇴Romania amateescu

    I was 100% sure we had test coverage for this, so I looked into it and turns out it's a problem that can only be reproduced in the UI, and even though WorkspaceMenuLinkContentIntegrationTest is a functional test, it's doing CRUD operations on menu links via API calls :/

  • Pipeline finished with Failed
    over 1 year ago
    Total: 176s
    #149334
  • Status changed to Needs review over 1 year ago
  • 🇷🇴Romania amateescu

    Opened a MR for it, and the bug can be easily tested by changing the existing coverage to do menu link operations via the UI, as it should :)

    Btw, the problem is not only for sub workspaces, top-level ones have the same issue.

  • Pipeline finished with Success
    over 1 year ago
    Total: 991s
    #149354
  • Status changed to RTBC over 1 year ago
  • 🇺🇸United States smustgrave

    Following the steps

    1. Standard Drupal install
    2. Enable workspaces
    3. Go to stage space
    4. Create a menu link
    5. Go back to live space
    6. Don't see menu link

    Applying MR fixes the problem.

    1) Drupal\Tests\workspaces\Functional\WorkspaceMenuLinkContentIntegrationTest::testWorkspacesWithCustomMenuLinks
    Behat\Mink\Exception\ExpectationException: Link with label stage link not found.
    /builds/issue/drupal-3438771/core/tests/Drupal/Tests/WebAssert.php:587
    /builds/issue/drupal-3438771/core/tests/Drupal/Tests/WebAssert.php:313
    /builds/issue/drupal-3438771/core/modules/workspaces/tests/src/Functional/WorkspaceMenuLinkContentIntegrationTest.php:106
    /builds/issue/drupal-3438771/vendor/phpunit/phpunit/src/Framework/TestResult.php:729
    ERRORS!
    Tests: 1, Assertions: 14, Errors: 1.
    

    Shows the test coverage

    • catch committed 01dd63eb on 10.3.x
      Issue #3438771 by amateescu, Michelle, smustgrave: Newly added menu...
    • catch committed 1522a33e on 11.x
      Issue #3438771 by amateescu, Michelle, smustgrave: Newly added menu...
  • Status changed to Fixed over 1 year ago
  • 🇬🇧United Kingdom catch

    Committed/pushed to 11.x and cherry-picked 10.3.x, thanks!

  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024