Today two of my colleagues – one working on a na12 org and one working on a na15 org – have found that the meta.xml files that the Eclipse Force IDE pulls back for classes and triggers are missing the package version dependency element “packageVersions”. They believe it was working earlier this week after Summer ’13 had been rolled out. This is for several managed packages that we and third parties have created, and the problem is with the additional non-packaged code that we add for specific customers.
Has anyone else experienced this? Is it an enhancement (related to “InstalledPackage”?) or is something broken? If the latter, is there a workaround?
Answer
**** UPDATE: 4th July 2013, Issue Resovled? ****
I now see this in my metadata XML file!
<?xml version="1.0" encoding="UTF-8"?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>28.0</apiVersion>
<packageVersions>
<majorNumber>1</majorNumber>
<minorNumber>0</minorNumber>
<namespace>packagea</namespace>
</packageVersions>
<packageVersions>
<majorNumber>1</majorNumber>
<minorNumber>0</minorNumber>
<namespace>packageb</namespace>
</packageVersions>
<status>Active</status>
</ApexClass>
Salesforce have listed the issue and fixed here.
One oddity still is that the Versions tab still shows this…
I’ll feed this back on my case see if they can explain this.
Original Issue Observations
Yes there is definitely something wrong here.
I have two test managed packages installed and I created the following…
public with sharing class TestPackageMeta {
private packageb__Sales_Invoice__c sinv;
private packagea__WorkOrders__c wo;
}
This resulted in this, no references to the packages…
<?xml version="1.0" encoding="UTF-8"?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>28.0</apiVersion>
<status>Active</status>
</ApexClass>
However the strange thing is this, one reference to package a, but not package b….
Yet reassuringly Show Dependencies showed this…
I also checked that the package dependencies have not been affected and thankfully not…
I’ve also raised a case on our Premier support contract to see if we can get some traction on this, case number 09403195.
Attribution
Source : Link , Question Author : Keith C , Answer Author : Andrew Fawcett