web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Facing Issue while imp...
Power Apps
Unanswered

Facing Issue while importing manage solution using new PCF CLI

(0) ShareShare
ReportReport
Posted on by 200

Hi,

I have followed the steps which were given to import PCF Control using new CLI "pac pcf push --publisher-prefix  " , but getting the following error

 

Error: Import Solution Failed: CustomControl with name Rooh.RecordPreview failed to import with error: CustomControls with Name Rooh.RecordPreview Import Solution Failed with following error: Custom Control with name Rooh.RecordPreview already created by another publisher. Please change your control's name and try importing again

 

The organization had solution which was build using by earlier CLI version - 0.2.71, we deleted the older CLI solution but still got the same error

 

When I checked in custom controls metadata the manifest file was still there in custom control metadata, I tried to delete the metadata using POSTMAN Request,but was unable to delete

{

    "error": {

        "code": "0x8004f032",

        "message": "The 'Delete' operation on the current component(name='WebResource', id='6afa6373-156b-4f9c-865d-dbf6f484fab4') failed during managed property evaluation of condition: 'Managed Property Name: iscomponentdeletionenabled; Component Name: WebResource; '",

        "innererror": {

            "message": "The 'Delete' operation on the current component(name='WebResource', id='6afa6373-156b-4f9c-865d-dbf6f484fab4') failed during managed property evaluation of condition: 'Managed Property Name: iscomponentdeletionenabled; Component Name: WebResource; '",

            "type": "System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=9.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]",

            "stacktrace": "   at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.Delete(EntityReference entityReference, InvocationContext invocationContext, CallerOriginToken callerOriginToken, WebServiceType serviceType, Boolean checkAdminMode, Boolean checkOptimisticConcurrency, Dictionary`2 optionalParameters)\r\n   at Microsoft.Crm.Extensibility.OData.CrmODataExecutionContext.Delete(EntityReference entityReference, Boolean checkForOptimisticConcurrency)\r\n   at Microsoft.Crm.Extensibility.OData.EntityController.DeleteEntityImplementation(String& entityName, String key)\r\n   at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute[TResult](ILogger logger, EventId eventId, ActivityType activityType, Func`1 func, IEnumerable`1 additionalCustomProperties)\r\n   at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute[TResult](ILogger logger, XrmTelemetryActivityType activityType, Func`1 func)\r\n   at lambda_method(Closure , Object , Object[] )\r\n   at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass10.<GetExecutor>b__9(Object instance, Object[] methodParameters)\r\n   at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary`2 arguments, CancellationToken cancellationToken)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__2.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__1.MoveNext()"

        }

    }

 

Since it was managed solution should this component not have been deleted when I deleted managed solution?

 

 

 

I have the same question (0)
  • Hemant Gaur Profile Picture
    on at
    Framework was declared GA last week, check out https://aka.ms/PCFBlog

    Hemant
  • hansgfixed Profile Picture
    37 on at

    Any workaround? Considering that pa component framework is still in preview no one can assure me there won't be any breaking changes again when I now update all pcfs, remove them from the orgs, re-import and set them up. 

  • liun Profile Picture
    48 on at

    @HemantG Thanks for the explaination. Understood. 

     

    With the addition of publisher prefix to the begining of root namespace, it seems introduced some inconsistency in the metadata:

     

    The solution.zip\customization.xml will display the custom control name with prefix, and folder name will have prefix:

    <CustomControl>
    <Name>myprefix_MyRootNameSpace.SecondLevelNS.MyControl</Name>
    <FileName>/Controls/myprefix_MyRootNameSpace.SecondLevelNS.MyControl/ControlManifest.xml</FileName>
    </CustomControl>

    but the actual manifest still declare the namespace without prefix:

    <manifest>
    <control constructor="MyControl" namespace="MyRootNameSpace.SecondLevelNS">

    It could create some confusion because in general, the string before the first dot is the root namespace, and the publisher prefix maybe just same as the root namespace (using organization name). In our case. it became meck_meck.pcf.ImageControl. 

     

    My feedbak is letting namespace handle the differences between same control name from different publisher, without adding prefix in build process. 

     

    Thanks

     

      

  • Hemant Gaur Profile Picture
    on at
    Fair point Lium. I apologize for this suboptimal experience and we are activity looking into how this can be handled better.

    One thing which I would like to call out is that lot of design and engineering effort had gone into making PCF much more robust and scaleable as we release it as GA. This change is also part of those internal feature investments and we will share more details soon.



    One core reason for PCF to be still in preview is to have that flexibility of making breaking changes now as opposed to production. We try hard not to do it but that's the price we pay for making bits available early as preview.

    Again feedback and any inputs are highly appreciated and we will continue to learn and improve.

    Regards,
    Hemant
  • liun Profile Picture
    48 on at

    @namohant 

    This seems related to the issue reported in the "new tooling" thread that the new build tool will add the prefix as part of the control name, while the old control has a different name but same guid.  

    I feel the addition of prefix during build is unecessary because the namespace should already tookcare that, and it cause huge pain if the PCF is already used on many forms. Now we have to remove them, delete old one, and re-add back to all forms. 

     

  • namohant Profile Picture
    Microsoft Employee on at

    We are looking into the issue. Will share an update as soon as possible. 

     

    -Nando

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
Kalathiya Profile Picture

Kalathiya 428

#2
WarrenBelz Profile Picture

WarrenBelz 374 Most Valuable Professional

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 333 Super User 2025 Season 2

Last 30 days Overall leaderboard