CumulusCI icon indicating copy to clipboard operation
CumulusCI copied to clipboard

Task update_package_xml does not write correct package.xml for AssignmentRules

Open Szandor72 opened this issue 2 years ago • 3 comments

Describe the bug

We have a DX project that is also deployed against a persistent org. In that case cumulusci deploys from /src after converting DX metadata. Package.xml is also created from /src via update_package_xml

If the DX source contains a Assignment Rule, deployment will fail immediately with:

Update of AssignmentRule package.xml: Error: You cannot install or upgrade a package that has a AssignmentRule component. Remove components of AssignmentRule type from the package.

Upon inspection cci creates the following package.xml:

    <types>
        <members>Case</members>
        <name>AssignmentRule</name>
    </types>

It should use Plural, i.e. AssignmentRules - when manually adding the Plural-s, the deploy tasks succeeds.

(Happy to patch this locally, just need a pointer)

Reproduction steps

  1. Create CCI Project with DX Source.
  2. Create an Pull an Assignment Rule
  3. (observe: no issues pulling/pushing to scratch org)
  4. connect cci to a persistent org
  5. run deploy against persistent org n. ...

Your CumulusCI and Python versions

cci 3.63

Operating System

Windows

Windows environment

PowerShell

CumulusCI installation method

pipx

Error Gist

No response

Additional information

No response

Szandor72 avatar Aug 18 '22 12:08 Szandor72

You could try changing this YML file:

https://github.com/SFDO-Tooling/CumulusCI/blob/main/cumulusci/tasks/metadata/metadata_map.yml#L42

Where exactly that file is on your computer is hard for me to predict. I could predict it better if you showed a stacktrace from --debug.

prescod avatar Aug 18 '22 17:08 prescod

(My answer via email was lost)

Thanks, @prescod ! Much appreciated, I know where to go and will remember to use --debug in the future.

Should I open a PR ?

Szandor72 avatar Aug 23 '22 07:08 Szandor72

Thanks a lot, Paul. Will work with --debug in the future. I am able to locate the file on my machine.

Should/Can I open a PR for the fix or will you create a Work Item?

Sz

On Thu, 18 Aug 2022, 19:57 Paul Prescod, @.***> wrote:

You could try changing this YML file:

https://github.com/SFDO-Tooling/CumulusCI/blob/main/cumulusci/tasks/metadata/metadata_map.yml#L42

Where exactly that file is on your computer is hard for me to predict. I could predict it better if you showed a stacktrace from --debug.

— Reply to this email directly, view it on GitHub https://github.com/SFDO-Tooling/CumulusCI/issues/3331#issuecomment-1219775478, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEAGS6VTBRMSHE2PEACTMLTVZZ2PZANCNFSM565DIXQQ . You are receiving this because you authored the thread.Message ID: @.***>

Szandor72 avatar Oct 11 '22 08:10 Szandor72