question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

*.profile-meta.xml files are not pulled after object deletion

See original GitHub issue

Summary

After custom object deletions in a scratch org, files related to profile are not updated by sfdx force:source:pull command.

Steps To Reproduce:

  1. Create a new scratch org.
  2. Open the new scratch org.
  3. Create a new Custom Object.
  4. Retrieve modified metadata with sfdx force:source:pull
  5. Verify the profile files are referencing, for instance, the new custom object layouts.
  6. In the scratch org, delete the created Custom Object
  7. Retrieve the metadata using sfdx force:source:pull again

Expected result

The *.profile-meta.xml files doesn’t contain any reference to deleted custom object assets.

Actual result

The *.profile-meta.xml files keeps references to deleted custom object assets. This will cause failure to any upcoming sfdx force:source:push execution.

Additional information

Created Object: screenshot 2019-01-27 at 3 00 29 p m

Retrieved metadata using sfdx force:source:pull screenshot 2019-01-27 at 3 01 27 p m

Retrieved metadata after custom object deletion. screenshot 2019-01-27 at 3 02 55 p m

Content of profile-meta.xml files after custom object deletion and pulling of scratch org source code. screenshot 2019-01-27 at 3 06 09 p m

ERROR: result of sfdx force:source:push -f into a new scratch org with the last pulled source code version: screenshot 2019-01-27 at 3 10 59 p m

SFDX CLI Version: sfdx-cli/6.50.0-9817aece8a (darwin-x64) node-v8.9.4

OS and version: darwin18 (MacOS Mojave)

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
clairebianchicommented, Feb 5, 2019

@sauloefo Thank you for the offer, but sadly this part of our codebase is not currently public.

0reactions
github-actions[bot]commented, Dec 9, 2021

We have determined that the issue you reported exists in code owned by another team that uses only the official support channels. To ensure that your issue is addressed, open an official Salesforce customer support ticket with a link to this issue. We encourage anyone experiencing this issue to do the same to increase the priority. We will keep this issue open for the community to collaborate on.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot delete profile error in Salesforce DX
One way to get this back is to run sfdx force:source:pull --forceoverwrite; Exclude the Admin.profile by adding it to the .forceignore file in ......
Read more >
How to Exclude Source When Syncing or Converting
Retrieve Unpackaged Source Defined in a package.xml File · Convert the Metadata Source to Source Format · Salesforce DX Usernames and Orgs.
Read more >
DX Complete Guide - Scratch Orgs - Ryan Wingate
9 - Create a Scratch Org · project-scract-def.json contains scratch org definition · Config folder can contain multiple of these files - must...
Read more >
Unexpected modified/outdated/deleted unstaged files ...
Hi Chris, yes, but I also could not reproduce it manually. It rarely happens. stefanjung.netlify.com – Your DITA/DITA-OT XML consultant. Top.
Read more >
Salesforce-metadata-xml File to Retrieve/Deploy Components
( objects, Apex , Aura etc) we have many ways & tools to do it. I am giving various options here in this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found