Overview

Canvas page pushes currently allow a local page file to update the path alias of an existing remote page when the UUID matches. This can unintentionally change the public URL of an existing page during a content push, and/or cause other issues.

Steps to reproduce:

  1. Pull or create a local page file with a UUID matching an existing remote page.
  2. Change the local page file's path value to a different alias.
  3. Run canvas push --include-pages.
  4. The existing remote page can be updated with the new alias.

Proposed resolution

Add remote-aware page validation during canvas push so existing pages are checked against their remote path aliases before pushing.

If a local page UUID matches an existing remote page and the normalized local path differs from the normalized remote path, report a validation error and stop the push.

Issue fork canvas-3589174

Command icon 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

balintbrews created an issue. See original summary.

hooroomoo made their first commit to this issue’s fork.

  • balintbrews committed 55af77c8 on 1.x
    chore(CLI Tool): #3589174 Prevent CLI pushes from changing existing page...
balintbrews’s picture

Assigned: balintbrews » Unassigned
Status: Active » Fixed

Published @drupal-canvas/cli@0.15.1.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

wim leers’s picture

Assigned: Unassigned » balintbrews
balintbrews’s picture

This issue targets the the same area. Let's discuss what to do with that other one over at #3589077: `canvas push` clears the URL alias of an existing page when the local spec has no path field.

balintbrews’s picture

Assigned: balintbrews » Unassigned
Status: Patch (to be ported) » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.