Artifact Dependencies

Updated 4 months ago by Copado Solutions

Artifact Dependencies Overview

As of Copado V12, the artifact dependencies feature allows you to make package artifacts dependent on each other. You can now develop and maintain a set of interdependent packages with the flexibility to promote them separately in a modular way.

Artifact dependencies are available for unlocked packages and second-generation packages. Unlocked packages can hold dependencies with other unlocked packages or 2GP.

Creating an Artifact Dependency

In order to create an artifact dependency in Copado, follow the steps below:

  1. Navigate to the related list section in the unlocked package or 2GP Artifact record.
  2. Next, locate the Related list named Artifact Dependencies and click on New.
  3. Fill in the fields in the Artifact Dependency record:
    • Dependent Artifact: Designates the artifact record which cannot be installed or managed without the depending one.
    • Depending Artifact: The depending package artifact which contains required dependencies for the metadata of the dependent package.
    • Depending Artifact Version: The minimum or exact version of the depending artifact. This particular version will be used during version creation and installation operations.
    • Depends on the latest version: If checked, the latest version of the depending artifact will be used when creating a new version and for installation operations.
  4. Once a dependency record is created, you will need to generate a new version of the package so that the new version is aware that it has a dependency. To generate a new version, click on Generate New Version in the unlocked package or 2GP Artifact record.

Artifact dependencies can be seen at the moment of loading metadata into a scratch org.

  1. On the first step in the Scratch Org Wizard, from the metadata sources available, select Unlocked Packages or Second-Generation Packages.
  2. In the next screen, enter the Sfdx Project details.
  3. Select an artifact and a version and click on Add to Selection.

  1. If the selected package has any packages dependent on it, they will be selected automatically. You can scroll down to the Selected Packages section where all the packages selected will be listed.
  • Firstly, you will see the package you have selected. The Included by column value will be User Selected.
  • Secondly, you will see all the dependent packages. The Included by column value will be the name of the main package.


How did we do?