cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DianaBirkelbach
Super User
Super User

Bug in "pac pcf push" when updating images

I think I have an issue with the PowerApps CLI (I'm using the latest version: "Microsoft.PowerApps.CLI.1.1.6").

I've defined some images in my manifest file.

The first time I could use "pac pcf push", and the images were uploaded together with my control. But once the control was uploaded, I cannot update my control again.

In order update my component, I have two options: I have to delete the component from my environment or I have to delete the images in my manifest (since the images were uploaded before, I can still see them). 

Here is the error (sorry, there are a few german words, but you'll get the point)

2020-01-24 18_41_37-Developer Command Prompt for VS 2017.png

And this is the content of my manifest:

 

 

 

<?xml version="1.0" encoding="utf-8" ?>
<manifest>
  <control namespace="ORBIS.PCF" constructor="AutocompleteMetadata" version="0.0.16" display-name-key="ORBIS.PCF.AutocompleteMetadata" description-key="ORBIS.PCF.Entity and attribute autocomplete" control-type="standard">
    <!-- property node identifies a specific, configurable piece of data that the control expects from CDS -->
    <property name="controlValue" display-name-key="Property_Display_Key" description-key="Property_Desc_Key" of-type="SingleLine.Text" usage="bound" required="true" />
    <property name="behavior" display-name-key="Behavior" description-key="Behavior" of-type="Enum" usage="input" required="true">
      <value name="Entity" display-name-key="Entity" description-key="Entity names" default="true">Entity</value>
      <value name="Attribute" display-name-key="Attribute" description-key="Attributes for an entity" >Attribute</value>
    </property>
    <property name="entityName" display-name-key="EntityName" description-key="EntityName needed only for attribute type" of-type="SingleLine.Text" usage="input" required="false" />     
    <resources>
      <code path="index.ts" order="1"/>
      <css path="css/Metadata.css" order="1" />   
      <img path="css/imgs/DownArrowTransparent.png"/>
      <img path="css/imgs/DownArrowTransparent2.png"/>
    </resources>
     <feature-usage>
      <uses-feature name="WebAPI" required="true" />
      <uses-feature name="Utility" required="true" />
    </feature-usage>
  </control>
</manifest>

 

 

 

 Best regards,

Diana

1 ACCEPTED SOLUTION

Accepted Solutions
sheldoncopper73
Resolver I
Resolver I

Hi,

 

Try using this command for importing solution pac pcf push -pp ikl -f

View solution in original post

8 REPLIES 8
HemantG
Power Apps
Power Apps

I am following this up with CLI tooling team and we will share the update soon.  

 

hemant 

BhuvitaSisodiya
Frequent Visitor

Can you try refering your weresource like below in your css.

background-image: url(/webresources/cc_Board.Board/img/Scoring.png);

sheldoncopper73
Resolver I
Resolver I

Hi,

 

Try using this command for importing solution pac pcf push -pp ikl -f

View solution in original post

As @sheldoncopper73 says have you tried to use the --force command with your push request.

 

so pac pcf push -pp orb -f

 

Your component manifest is identical to a few of mine and I've published them multiple times without issues including replacing the images with better versions.

---
If this post has answered your question please consider it for "Accept as Solution" or if it has been helpful give it a "Thumbs Up".

Thank you @sheldoncopper73 and @ben-thompson ! 🙂 This fixed the problem. Where have you find the "-f" Option, since it's not documented yet? 

Unfortunately making the full upload takes about 3 minutes  😞 , but at least I don't have remove the control from the form in order to update it. 👍

If force update is taking time one more thing you could try is changing something from ControlManifest.xml file 

 

Do Minor changes somewhere you tags display-name-keys or description like putting an s after 

 

Then build and push solution using (pac pcf push -pp xyz)

 

Note: You would have to these steps every time you want to update

Eg -

 

  <data-set name="sampleDataSet" display-name-key="Dataset_Display_Key">
 
  <data-set name="sampleDataSet" display-name-key="Dataset_Display_Keys">
 
 
 

It still makes no difference. This time I've checked exactly: it takes about 6-8 minutes !!! 

But I also have problems with generating the solution using the msbuild for my solution project (cdsproj). It must be something with a proxy or the company antivirus. When I'm in home office it works fast.

I have no idea where to check what's happening.

The log in /obj/builld.log just shows that the first 3 minutes are lost between cleaning and building.

[15:16:40] [clean]  Initializing...
  [15:16:40] [clean]  Cleaning build outputs...
  [15:16:40] [clean]  Succeeded
  Cleaning output directory: bin\Debug\, Intermediate directory: obj\Debug\ and Solution Packager working directory: obj\Debug\
  Removing log file: bin\Debug\SolutionPackager.log and generated solution package: bin\Debug\PowerAppsTools_orb.zip
  
  > pcf-project@1.0.0 build C:\birdia\Source\Repos\ORBIS.PCF.Autocomplete.Metadata
  > pcf-scripts build "--noColor" "--buildMode" "development" "--outDir" "C:\birdia\Source\Repos\ORBIS.PCF.Autocomplete.Metadata\out\controls" "--buildSource" "MSBuild"
  
  [15:19:50] [build]  Initializing...
 [15:19:50] [build]  Validating manifest...
  [15:19:50] [build]  Validating control...
  [15:19:51] [build]  Generating manifest types...
  [15:19:51] [build]  Compiling and bundling control...

The only way it works fast, is using the update mode of pac pcf push.

 

Thanks again for trying to help. At least I can use the "-f" argument, so I can go in this time to grab a coffee, instead of removing the component from the form 🙂 . That helps too.

 

That will be your company's anti-virus software and policy.

 

I used to have the same 10 years ago at a previous company maintaining some Java code that used libraries that also consisted of 1,000s of small files (if it triggered when compiling you could drink your coffee and then go for a 15 minute walk).. We eventually got a waiver that allowed us to disable the software when compiling...

---
If this post has answered your question please consider it for "Accept as Solution" or if it has been helpful give it a "Thumbs Up".

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Users online (26,533)