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

CLDR-15161 3rd meter: correct error count #1671

Merged
merged 1 commit into from
Jan 3, 2022

Conversation

srl295
Copy link
Member

@srl295 srl295 commented Dec 22, 2021

  • send in dpath (not fullpath) to check(), avoid spurious collision errors
  • also add some more debugging values to the response payload

CLDR-15161

  • This PR completes the ticket. (hopefully!)

- send in dpath (not fullpath) to check(), avoid spurious collision errors
- also add some more debugging values to the response payload
@srl295 srl295 requested review from macchiati and btangmu December 22, 2021 23:44
@srl295 srl295 self-assigned this Dec 22, 2021
@srl295 srl295 mentioned this pull request Dec 22, 2021
1 task
@@ -142,25 +142,34 @@ static LocaleCompletionResponse getLocaleCompletion(final CLDRLocale cldrLocale,

final List<CheckStatus> results = new ArrayList<>();
for (final String xpath : file) {
lcr.allXpaths ++;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unusual space before "++"

i wish we were using similar formatting tools for java as we're using for js

public int ignoredHidden = 0;
public int allXpaths = 0;
public int statusMissing = 0;
public int ignoredOutOfCov = 0;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it might be worthwhile to make a stronger distinction between debug and non-debug items

is this data included in json, and if so, is it actually used/needed on the front end?

could these be private?

on the one hand, it can be convenient and flexible like this to be public (and maybe included in json), however in the long run there's a risk of cruft, dead code, and unnecessary dependencies

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, they are included in the JSON, and so could be used in an expanded sort of meter with a breakout.

} // else: out of coverage level, do not count the path.
} else {
// out of coverage level, do not count the path.
lcr.ignoredOutOfCov ++;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there's that space plus plus again

@srl295 srl295 merged commit a118e5e into unicode-org:main Jan 3, 2022
@srl295
Copy link
Member Author

srl295 commented Jan 3, 2022

Merging so we can get eyes on the functionality.. will leave ticket open to revisit formatting (thanks)

@srl295 srl295 deleted the cldr-15161/meter3ter branch January 3, 2022 21:58
@@ -193,6 +205,13 @@ static LocaleCompletionResponse getLocaleCompletion(final CLDRLocale cldrLocale,
public int provisional = 0;
final public String level;

// The following are more or less debug items
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not shown to user, but calculated as part of counts

public int ignoredHidden = 0;
public int allXpaths = 0;
public int statusMissing = 0;
public int ignoredOutOfCov = 0;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, they are included in the JSON, and so could be used in an expanded sort of meter with a breakout.

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

Successfully merging this pull request may close these issues.

2 participants