2

Since Winter'19 release my team is getting following errors when pushing our code to the scratch orgs (or converting it to mdapi format):

[xmldom error]  element parse error: Error: invalid tagName:
@#[line:5,col:38]
[xmldom error]  element parse error: Error: invalid tagName:
@#[line:6,col:28]
[xmldom error]  element parse error: Error: invalid tagName:
@#[line:7,col:32]
[xmldom error]  element parse error: Error: invalid tagName:
@#[line:8,col:36]
[xmldom error]  element parse error: Error: attribute equal must after attrName
@#[line:9,col:40]

Error message is quite helpful with what's wrong but not with pointing the exact troublesome file as you can see. Seems to be project specific because I don't get any errors when pushing for example lwc-recipes code.

Besides errors showing up in the console everything is fine and the entire code is pushed to the scratch org in the end. However, I still wonder if we have some issues in some of our files or not.

Did someone else encounter such errors or we are the only ones? And if you had, did you find the root cause?

UPDATE 29.03.2019: I just noticed that it happens only when --force flag is added to the sfdx force:source:push -f command

3
  • There was a major SFDX update last night. Did that fix the problem?
    – David Reed
    Mar 29, 2019 at 12:41
  • Unfortunately, still have it on sfdx-cli/7.1.4-79f97a7df8 win32-x64 node-v10.15.3
    – neff
    Apr 3, 2019 at 11:25
  • 1
    While someone here might be able to help with an answer, I'd recommend also checking in with the Salesforce DX Trailblazer Community group. The product team is quite active there.
    – David Reed
    Apr 3, 2019 at 14:20

1 Answer 1

2

The Error: invalid tagName: is saying that you have an empty tag that can't be parsed in some xml somewhere.

When we had this problem, it was because of formula fields that used <> instead of !=.

A quick switch over and everything was fine!

This could also be caused in places where there is a < and then a > somewhere else. For example a formula like OR(Item_Count__c < 2, Item_Count__c > 5). Or even just a < symbol on its own.

1
  • 1
    that's exactly it! We had in in Validation rules and field defitinion. in addition it still showed up when there was no >, just <, like this: FirstField__c < SecondField__c. thanks @fred. BTW that's strange that it occurrs just for forced pushes
    – neff
    May 9, 2019 at 15:32

You must log in to answer this question.

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