dmc icon indicating copy to clipboard operation
dmc copied to clipboard

Receiving undefined error retrieving CustomMetadata

Open jnottingham opened this issue 9 years ago • 1 comments

Update 9/29/2016: I upgraded to DMC 1.2.3 and am having the same problem with this one org specifically. I have not experienced this with any other production or sandbox instances.

I am having an issue with my production org specifically, which is currently on Summer 16. My sandboxes, on Winter 17, are not experiencing this problem. I am using DMC 1.1.0 on Windows 10 in the standard command prompt.

If I do a dmc retrieve src/customMetadata/* or any glob pattern that matches this, I receive a response of [err] undefined: undefined

c:\%repodir%>dmc retrieve src/customMetadata/* [dmc] using org: myLogin (default) [dmc] loaded .dmcignore [dmc] matching types [dmc] * matched type: CustomMetadata [err] undefined: undefined [dmc] [NOT OK]

This occurs even though I have now specified this folder in my .dmcignore: src/customMetadata/* src/customM*/* src/customM*

I have tried changing deploy_mode to 'metadata', I have tried several api_versions, with no change in results. I get a Salesforce System Error/gack when I try to do the same thing in MavensMate, so it must be some issue with Salesforce.

The best way I have found to retrieve all the rest of my metadata without this crashing my retrieve is by manually removing CustomMetadata from the dmc index.json file. This change is overwritten when I re-index, of course. I tried to build globbing patterns that would grab everything but this one folder, but haven't found a clean solution yet.

Here are some thoughts on how to work around a situation like this, not a DMC problem really

  • Allow excluding specific metadata from being included in a retrieve at all, perhaps by using persistent attributes in the JSON index
  • Do not even try to retrieve any metadata type that is excluded in .dmcignore
  • See if there is any more information we could display in the case of a transaction failure like this

Does anyone have ideas on a better workaround than modifying the project index?

jnottingham avatar Sep 27 '16 15:09 jnottingham

Hmm, it's possible that there is a bug in .dmcignore that could be fixed. It should be ignoring it. With Dreamforce next week I am going to be pretty tied up but if you want to try to patch it I'm open to a PR to speed things up. Otherwise I'll look at it when I get back.

kevinohara80 avatar Sep 30 '16 00:09 kevinohara80