3

I'm currently in a CI process. I refreshed my sandbox from production, setup my project in Eclipse, and committed all the metadata to GitHub. Now when I try to build I'm getting the following error :

Error: package.xml(CompanyDashboards/EDR1):An object 'CompanyDashboards/EDR1' of type Dashboard was named in package.xml, but was not found in zipped directory

So I checked my package.xml, and I can see the dashboard is there :

<members>CompanyDashboards/EDR1</members>

Now the weird thing is that it's not in my dashboards folder. Nothing even happen when I refresh the individual folder from server. Another weird thing is when I want to 'Add and Remove Metadata API' I can see that the EDR1 dashboard is actually there, but it's not adding it. I even tried to create the file myself in the dashboards folder (EDR1.dashboard), then tried to refresh from server, but nothing happen.

I have the same problem with an email template, but I found the error message quite funny :

Error: package.xml(unfiled$public):An object 'unfiled$public' of type EmailTemplate was named in package.xml, but was not found in zipped directory

It might be helpful if Salesforce could point me which Email Template they are talking about ?

Update

unfiled$public issue has been fixed, I remove the folder from the package.xml as it's a sfdc standard folder. However I still have the issue with the dashboards

Does anyone can point me if I'm doing anything wrong? Much appreciate

3
  • When you go to the Add/Remove Metadata components, have you refreshed the metadata from the server? (Top right on the 'Choose metadata Components' page). Personally I also prefer to use the Synchronize function to compare my code with what's on the server.
    – Nick Cook
    Apr 10, 2015 at 1:37
  • Yeah I did, I tried the same thing in Mavensmate doesn't seems to work either.
    – brovasi
    Apr 10, 2015 at 2:17
  • Have you maybe verified that the requsted dashboard is indeed present on the source org? The easiest way to do that would be to go to Reports tab, locate 'Company Dashboards' dashboard folder (you'll easily distinguish dashboards folder from the reports folder by the blue folder icon, while the reports folder has a yellow one), and see whether EDR1 dashboard folder even exists. If not, I'd either remove reference to it from the package.xml, or create one with exact same name and then 'refresh from server' in Eclipse.
    – dino ursic
    Jul 30, 2015 at 11:05

2 Answers 2

2

Not sure whether your problem is still present, but I'll post my findings as it took me > 3 hrs to finally reach a breakthrough.

Basically, I had encountered the same issue as you, where I was unable to retrieve some of the dashboards neither via Eclipse, nor the Force.com Migration Tool. I've tried several approaches, first one being the one that I had recommended you in the comment to your question. After verifying that the dashboard indeed exists on the org from which I was trying to retrieve the metadata, I assumed the issue might be in the fact that I had a report folder named the same as dashboard folder (same API name). Renaming the folder didn't help, so further googling led me to this post on salesforce.success.com:

The folder being hidden or the users personal folder is the only way I've ever seen that error.

Which all led me to believe that there might be some issues with folder access. Sharing the dashboard folder with the user I'm using to connect via Force.com IDE again didn't help, so I assumed I might need to share the dashboard too. That also didn't help, but thourough inspection of dashboard finally led me to conlusion that some of the reports used as datasource(s) for the dashboard were inaccessible to my user. You'll easily notice that if you try to edit the dashboard and see following message in one of the dashboard components:

Error: The source report is based on a report type that is inaccessible to the dashboard's running user.


So at this point you have 2 potential solutions. Either you'll remove the component from the dashboard entirely, or you'll figure out what is the underlying report and fix sharing on it.

I hope this might save someone's entire afternoon of hairpulling.

1
  • Thanks for coming back to me on this one. I'm not working on this project anymore, so I won't be able to test it. But I gave you a vote for that because was a very good explanation. I hope that will help someone else. ANT script is so great but metadata api can be quite frustrating sometimes.
    – brovasi
    Jul 30, 2015 at 22:38
0

Do you want deploy your code on sandbox? You need to double check that file CompanyDashboards/EDR1 exist in your working directory or zip file. Please share your build.xml and task that you want to perform. Also you can see my scripts - https://github.com/SergeyTrusov/sf-build-scripts

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .