Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Picklist deploy resulting in "Cannot update or delete a picklist while a picklist background job is being executed" error #1

Closed
petter-eikeland opened this issue Jan 21, 2024 · 4 comments · Fixed by #8
Assignees
Labels
bug Something isn't working
Milestone

Comments

@petter-eikeland
Copy link

petter-eikeland commented Jan 21, 2024

Describe the bug
"Cannot update or delete a picklist while a picklist background job is being executed" thrown upon pre picklist deployer (see screenshot below).

To Reproduce
This is an intermittent, but frequent issue (≈ 5–10% of pipeline runs). This occurs when there are multiple picklists to be deployed in the pre deployer.

Expected behavior
When getting "Cannot update or delete a picklist while a picklist background job is being executed", retry the picklist deployment.

Screenshots
image

Platform Details (please complete the following information):

  • OS: Linux
  • Version [e.g. CLI Version eg: 1.6.6]: 25.5.3 (December 23)
  • Salesforce CLI(sfdx cli) Version: sf version that is on 25.5.3
  • CI Platform: Azure DevOps
@azlam-abdulsalam azlam-abdulsalam added bug Something isn't working and removed analysis labels Jan 25, 2024
@azlam-abdulsalam azlam-abdulsalam added this to the February 2023 milestone Jan 25, 2024
@azlam-abdulsalam
Copy link

@Rocko1204 can you have a look

@Rocko1204 Rocko1204 linked a pull request Feb 2, 2024 that will close this issue
5 tasks
@Rocko1204
Copy link
Collaborator

Rocko1204 commented Feb 2, 2024

Hi @petter-eikeland Also for you the info . The picklist background job is a known Salesforce error that can also occur in the install and build jobs. So I can't guarantee whether 3 minutes (6 retries a 30 seconds) is enough. In my tests, 10 seconds wasn't enough. But more runs doesn't make sense at first. So we should start with this settings.

@petter-eikeland
Copy link
Author

Sounds good! If the picklist background job is still running after 3 minutes, then it is more a Salesforce issue, than a deployment issue. Thank you for following this up swiftly @Rocko1204 😄

@dschibster
Copy link

Are one or more of your picklists dependent on one another? This is the issue that made it obvious to me. I handled it by making the deployment of the dependencies a separate step inside the post-folders, while only keeping the values in my package. That resolved the issue for me mostly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants