Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid Count Value Error. #291

Closed
jpwijbenga opened this issue Nov 19, 2019 · 3 comments
Closed

Invalid Count Value Error. #291

jpwijbenga opened this issue Nov 19, 2019 · 3 comments

Comments

@jpwijbenga
Copy link

Description

Formatter gives cryptic error message: "Invalid Count Value" when trying to format small XML. Not sure if the document is faulty or formatter has a bug.

<?xml version="1.0" encoding="UTF-8"?>
<a>
	The Total (<value-of />) is not equal to the sum (<value-of />).
</a>

Formatter Implementation

v2

XML Tools Version

2.5.0

VS Code Version

1.40.1 User

Operating System

Win10 Ent (x64) 1809

@SebastianZ
Copy link

This seems to be a bug in the formatter.

Here's another simple test case:

<x>foo<y><z>bar</z></y></x>

Trying to format this also results in an "Invalid count value" error.

Though if you insert a line break after "foo" like this

<x>foo
<y><z>bar</z></y></x>

the XML will be formatted correctly.

Sebastian

@DotJoshJohnson DotJoshJohnson added this to the Release: v2.5.1 milestone Jul 2, 2020
@DotJoshJohnson
Copy link
Owner

This should be fixed by #317.

@SebastianZ
Copy link

I can confirm that this issue is gone in the latest version.

The output of my example looks like this now after formatting:

<x>foo<y>
  <z>bar</z>
</y>
</x>

I had expected it to format it like this:

<x>foo
  <y>
    <z>bar</z>
  </y>
</x>```

Though at least the error is gone, so thank you for fixing this!

Sebastian

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants
@SebastianZ @jpwijbenga @DotJoshJohnson and others