forcedotcom / forcedotcom/cli

force:cmdt:record:insert causes deployments to fail if there is a Metadata Relationship data type

Open
#544 9 comments 1 reaction 0 assignees View on GitHub
area:custom-schema bug owned by another team
Dominant language
No language data
Stars
571
Forks
80
Avg merge
2d 15h
Merged PRs (30d)
3

Description

### Summary

Using `force:cmdt:record:insert` generates XML with Metadata Relationship data types tagged as `xsi:type="xsd:undefined"`. When deploying the resulting Custom Metadata Records the following error is received:

`ERROR running force:source:deploy: Deploy failed`

Replacing `xsi:type="xsd:undefined"` with `xsi:type="xsd:string"` fixes the issue.

### Steps To Reproduce:

1. Create two metadata type objects linked with a Metadata Relationship
1. Create CSVs for both metadata types
1. Run `force:cmdt:record:insert` to create XML Custom Metadata Records for each Type
1. Deploy Custom Metadata Records

### Expected result

Deploy should be successful

### Actual result

Deploy fails with `ERROR running force:source:deploy: Deploy failed`

### Additional information

Replacing `xsi:type="xsd:undefined"` with `xsi:type="xsd:string"` in the XML generated with `force:cmdt:record:insert` fixes the issue.

Version: sfdx-cli/7.68.6-d37008df83 darwin-x64 node-v12.18.3

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.