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:
- Pull or create a local page file with a UUID matching an existing remote page.
- Change the local page file's
pathvalue to a different alias. - Run
canvas push --include-pages. - 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
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 #5
balintbrewsPublished
@drupal-canvas/cli@0.15.1.Comment #7
wim leersHow does this relate to #3589077: `canvas push` clears the URL alias of an existing page when the local spec has no path field?
Comment #8
wim leersComment #9
balintbrewsThis 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.
Comment #10
balintbrews