Hi,
I am unsure if I have the dependencies working for my package. After creating two packages I expected a package with any dependencies would automatically install those dependencies.
Instead I got this error message:
$ sfdx force:package:install -i 04t0N000000LFFdQAO -u EmptyOrg1
...
$ sfdx force:package:install:get -i 0Hf0E0000008STCSA2 -u test-few5zg80loix@nelson_company.net
ERROR: Encountered errors installing the package!,Installation errors:
1) Variable does not exist: CoreController, Details: FeatureOneController: Variable does not exist: CoreController
I have the following folder structure
├── README.md
├── config
│ └── project-scratch-def.json
├── core
│ └── main
│ └── default
│ ├── aura
│ └── classes
│ ├── CoreController.cls
│ └── CoreController.cls-meta.xml
├── feature-one
│ └── main
│ └── default
│ ├── aura
│ └── classes
│ ├── FeatureOneController.cls
│ └── FeatureOneController.cls-meta.xml
└── sfdx-project.json
The sfdx-project.json file looks like this:
{
"packageDirectories": [
{
"path": "core",
"default": true,
"id" : "0Ho0N0000004C9XSAU",
"versionNumber" : "0.0.0.NEXT",
"versionDescription" : "Core 0.0.0.1",
"versionName": "Core1V0.0.0.1"
},
{
"path": "feature-one",
"id" : "0Ho0N0000004C9cSAE",
"versionNumber" : "0.0.0.NEXT",
"versionDescription" : "Feature One 0.0.0.2 this package has the dependency on core",
"versionName": "Feat1V0.0.0.2",
"dependencies": [
{
"packageId": "0Ho0N0000004C9XSAU",
"versionNumber": "0.0.0.LATEST"
}
]
}
],
"namespace": "HelloDemo01",
"sfdcLoginUrl": "https://login.salesforce.com",
"sourceApiVersion": "41.0"
}
That original json file will build the packages I want but I need to install my core package if I want feature-one to install. Dependencies aren't installed automatically, is that not expected?
I also tried changing my dependencies to list the subscriber id like this (https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_dev2gp_config_dependencies.htm)
"dependencies": ["04t0N000000L8AQQA0"]
I get this error when I try and rebuild the package:
$ sfdx force:package2:version:create -i 0Ho0N0000004C9cSAE
ERROR: Dependency must specify either a subscriberPackageVersionId or both packageId and versionNumber: "04t0N000000L8AQQA0".
Thanks
Nelson