Questions tagged [2gp]

Questions about second-generation packaging (2GP). Includes the partner-centric feature of Managed 2GP as well as the customer-centric feature of Unlocked Packages.

Filter by
Sorted by
Tagged with
2
votes
1answer
42 views

Simulate trusted relationship (kinda @NamespaceAccessible behaviour) for base 1gp package and 2gp extension

We have our huge monolithic 1gp legacy package as well as 2gp extension package. And there are some secret configs (e.g. s3 keys, twillio account creds etc. in protected custom settings) in 1gp ...
0
votes
0answers
13 views

2GP: the same class name in 2 packages with the same namespace [duplicate]

We have 2(2GP) Packages for example "A" and "B" on the one namespace for example "pkg2". In Package A we have an apex trigger with the name "ContactTrigger" and ...
0
votes
1answer
32 views

2gp, 2 dev hubs, 2 repositories, 1 namespace. Will there be ancestry issues?

I have a 2gp, namespaced package working great. My question is, if I want to experiment in a fork of my git repository, wipe out my sfdx-project.json file in the fork, link it to a NEW dev_hub in the ...
1
vote
1answer
27 views

2GP Package Information

I am creating 2GP unlocked packages, no issue. I have created a DevHub, completed all my pre requisites (Enabled Dev Hub, 2GP), attached namespace org to the devhub. When I am trying to get the ...
0
votes
1answer
15 views

INVALID_SESSION_ID: force:canvasApp does not load connected app

I am trying to create a 2GP that includes an Aura component which loads a canvas app using force:canvasApp. I have successfully created this aura component in my packaging organisation, by creating a ...
0
votes
2answers
30 views

Why ancestors are required for 2GP?

As long as 2GP have a System Version Control as source of truth, it seems to me that the branching mechanism of SVC would be enough to create versions from another previous version of a 2GP. Having ...
3
votes
1answer
45 views

How to create a canvas application displaying a connected app in a 2GP

I am trying to create a 2GP that includes an Aura component, which shows a canvas app using force:canvasApp. I have tested this Aura component by creating it in the developer console. I did this in ...
1
vote
1answer
36 views

SFDX: Having multiple project config files (one per dev hub) and switching between them dynamically when creating package version

We would like to switch between different dev hubs in our sfdx 2gp project. E.g. we have one dev hub representing our BPO org (for major releases) and couple free registered dev hubs to play around ...
2
votes
1answer
87 views

Tableau CRM Dashboard Packaging with AppExchange Apps

We are working on an AppExchange App which will be an ISV app and not the OEM application. Currently there are few standard reports and dashboards are part of package which can be used by customers ...
2
votes
1answer
22 views

Extending a picklist with additional values 2GP

I'm creating a 2 GP package packageB which depends on several 1 GP packages. In packageB, I'd like to extend a picklist from packageA, one of the managed packages, with additional values. I tried ...
6
votes
2answers
56 views

How to list one package on both the English and Japanese AppExchange marketplaces?

We are attempting to list our App on the Japanese App exchange. We have successfully listed on the English App exchange; the App has passed its security review recently. (The term "marketplace&...
1
vote
0answers
68 views

Global Value Set is not translated in managed package

I developed a 2GP managed package. I enabled the translation workbench in the package and translated custom fields. These are well working in the organization where the package is installed. I also ...
0
votes
0answers
61 views

2gp: How to debug/fix tests failing ONLY on package version creation

We are trying to create our first major version of new 2gp package and getting some tests failures as result of 'package version create' command. These failures look sort of weird for us (basically ...
1
vote
1answer
56 views

2GP push error modify managed object

i have the following error when i want to push a 2GP in a new Scrach org force-app\main\default\objects\Country__mdt\fields\Country_Code__c.field-meta.xml Cannot modify managed object: entity=...
2
votes
1answer
57 views

2gp: Should components names be unique across all the packages of the same namespace?

Let's say that we have couple 2gp managed packages all sharing the same namespace. Should all components/classes/pages etc. have unique name across all the packages of the same namespace? Are there ...
3
votes
1answer
75 views

2GP Workflow and Upgrade Questions

I am having difficulty understanding the 2GP workflow. I have read through the documentation and have watched a number of videos but it is still not clicking for me. I was hoping to have someone point ...
0
votes
0answers
18 views

Experiences Security warning with custom components

I am getting a security warning in Digital Experiences after packaging my custom components. I am not calling any third party scripts from my components. I tried reducing the Site's CSP settings but ...
0
votes
1answer
31 views

Second Generation Packages: ERROR running force:package:version:create: : The object 'Object' of type Settings metadata does not exist

I am getting this error when I create version of a new second generation managed package. The project has simple Apex class without code and dependency on single 1st generation managed package. Are ...
0
votes
1answer
33 views

2GP packaging error: These entities are not supported: [NavigationLinkSet]

I am creating a new package for communities. I have included the communityTemplateDefination/lightning bolt/theme defintion and my NavigationMenu (in the navigation menu folder) but when I package it ...
1
vote
1answer
44 views

2GP package dependency version

When configuring sfdx-project.json for 2GP managed package you specify it's dependencies. My package depends on our 1GP managed package. So I specified 1GP package version Id in depencensies. But what ...
2
votes
2answers
52 views

Trouble creating a version for 2GP

Following is my sfdx-project.json : { "packageDirectories": [ { "path": "force-app", "default": true }, { "path": &...
1
vote
0answers
95 views

Unable to package Flow with scheduled path

We are trying to add a Flow to a 2GP Managed Package the Flow has a scheduled action. When we run the command: sfdx force:package:version:create .... We get an error message: ERROR running force:...
3
votes
1answer
42 views

Can objects such as PackagePushRequest be made available in a scratch org?

The question relates to some new API 51 objects that allow second generation packaging push upgrades to be scheduled. Running this script in our Partner Business Org (PBO): List<String> names = ...
5
votes
2answers
95 views

Push upgrade app for second generation packages?

Based on the Scheduling Push Upgrades and the Push a Package Upgrade documentation, while Salesforce UI to schedule push upgrades is available for first generation packages (1GP), for second ...
3
votes
1answer
173 views

How do I package an upgradable Experience Builder Site?

I need to provide an unlocked package containing a customizable "starter kit" for using features of my managed package so customers have an easy starting point to create their own experience....
0
votes
0answers
38 views

2GP Managed Package Installation Error: (My_Flow) A flow can’t be triggered by My_Event__e records. Change the object in the Start element

I have a 2PG Managed Package which includes two Flow which use Platform Event as the starting object. When we try and install the Beta package into a Scratch Org it fails with error: (On_My_Flow1) A ...
0
votes
0answers
22 views

Provider Free Capacity [duplicate]

I've updated the cachePartition metadata of a 2GP package, which has previously passed security review. <platformCachePartitionTypes> ... <allocatedPartnerCapacity>2</...
1
vote
0answers
31 views

Issue while promoting 2GP beta package to Managed Package

We are facing one issue while promoting the 2gp beta package to managed package. Please consider the following scenario. Created a package with command - sfdx force:package:version:create -p ...
0
votes
0answers
46 views

2GP: Filtered report charts in Lightning Record Pages can't be packaged (Error with flexipage unknown)

I am facing an Error when trying to package a Lightning Record Page via 2GP but I am not able to push it. The following Error is printed in the Terminal: Account_Record_Page.flexipage-meta.xml ...
4
votes
1answer
211 views

I want to package (unlocked 2GP) a Digital Experience; what metadata do I need?

I have a requirement to package a Digital Experience (aka Community) in a no-namespace, unlocked 2GP using an Experience Bundle. Having looked around, I could only find information about how to deal ...
1
vote
1answer
63 views

Unhandled errors are not coming to user designated for 2GMP

Apex documentation has contradicting information about Second Generation(2GP) Package Apex Unhandled Exception support. This page states that Apex exception errors don’t trigger email notifications. ...
12
votes
2answers
931 views

Extension packages & Licence Management in 2GP

In the first generation of Managed Packages (1GP), you are able to create Managed Extension packages that technically required a base package. Both could be distributed and licensed using the same ISV ...
0
votes
1answer
116 views

Apex compile failure on package installation

While performing a development I replaced a class name (from ExampleCtrl to ExampleController) and a few methods were also renamed. While this package was correctly installed on my scratch org, it is ...
3
votes
1answer
71 views

How do we handle additions to page layouts with SalesforceDX / 2GP?

I've found some time to return to an older project of mine, moving my org away from the org development model to the package development model to make better use of SFDX and CI/CD. The issue I'm ...
2
votes
1answer
26 views

Is there a scripted/coded/API way to remove a metadata item from an Unlocked Package?

When an Unlocked Package is installed into a subscriber org, the metadata from the package is tagged as belonging to the package. In that subscriber org, we can go to the package details through the ...
0
votes
1answer
54 views

Include two different package Directories during unlocked package creation

I am having different set of LWC components some under force-app and some under common folder. My sxdf-project.json is { "packageDirectories": [{ "path": "...
0
votes
1answer
25 views

Load data into object after Unlocked package

I want to load some data into an object after a package gets installed. I tried using a post-install script but seems these only work for Second-Generation Managed packages and not for Unlocked ...
3
votes
1answer
86 views

When referencing a 1GP connected app from a 2GP package, what happens when the certificate associated with the connected app is updated?

Given this detail about referencing an explicit version of a connected app from a 1GP managed package to include it in a 2GP package, what are the implications of updating an expiring certificate for ...
2
votes
0answers
32 views

Page layout assignments in 2GP

We are working on 2GP for one of our applications. We are facing one issue that page layout assignment is not happening after the installation of 2GP. Our package contains everything including the ...
1
vote
1answer
36 views

Enabling Unlocked Packages and 2GP on a HUB

So basically my company has a dev hub, that owns all our 1GP enterprise managed/unmanaged packages. What will happen to 1GP packages if we turn on "Enable Unlocked Packages and Second-Generation ...
3
votes
1answer
360 views

This app can't be upgraded: Invalid Upgrade: The currently installed version does not share a common ancestor with this version

I am trying to upgrade from v0.6 to v0.7 of a Managed Package which uses 2GP. I am getting this error message: This app can't be upgraded. There are problems that prevent this package from being ...
0
votes
1answer
45 views

Clarifications on salesforce 2g packages [closed]

I am working on 2g package generation and these are few questions troubling me : Is it mandatory to keep metadata in namespace org to create 2g package version. What if namespace org is empty and all ...
3
votes
1answer
137 views

Package a custom field on LiveChatTranscript object using 2gp

We are creating an AppExchange application where we need to package a custom field on the LiveChatTranscript object. While creating a 2GP package, we are getting an error: LiveChatTranscript....
1
vote
1answer
162 views

ERROR: Removing metadata components from a second-generation managed package is a pilot feature that requires acceptance into a pilot program

I am trying to create a new package version using 2GP. When I run this command sfdx force:package:version:create ... I am getting this error: ERROR running force:package:version:create: Can’t ...
3
votes
1answer
177 views

2GP Create Package Version Fails when running tests

I've recently added some Field Level Security checks into the Apex code of a 2GP managed package. But when I run: sfdx force:package:version:create ... A lot of the tests fail, saying the fields are ...
0
votes
1answer
71 views

Can we package Layout assignment for Record Types and Record Type page assignment via PS?

Is there any place we can refer, which metadata can be added to a 2G managed package. For example, I need to know whether we can package the following option in a 2G managed package, Layout assignment ...
1
vote
0answers
54 views

SFDX packaging - Report folder sharing settings

I am running into an issue while trying to install an unmanaged package / deploying metadata through SFDX. On the ORG I am working on we have Report Folders which should be initially shared with some ...
0
votes
1answer
125 views

Trying to Package Connected Apps in Second-Generation Managed Packaging

I am fairly new to Salesforce, and currently trying to explore Connected App in 2GP. I have done some reading and came across some posts that is similar to my situation here. Package Connected App ...
1
vote
1answer
364 views

ERROR running force:org:create: We don’t recognize this namespace: x. Did you register it in your Dev Hub org?

I am trying to create a Scratch Org with a Namespace using command: sfdx force:org:create -s -f config/project-scratch-def.json -a my-namespace -d 30 But I get this error: ERROR running force:org:...
3
votes
2answers
380 views

2GP Extension Package With Dependencies on External Packages

I need to create an AppExchange Package (extension to Health Cloud), which has dependencies on the Health Cloud package. As per documentation/community, 2GP is the recommended way to package new ...