-
Notifications
You must be signed in to change notification settings - Fork 101
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
fix: Mixed Case false positives #1430
Conversation
...ssor/src/main/java/org/mobilitydata/gtfsvalidator/processor/MixedCaseValidatorGenerator.java
Outdated
Show resolved
Hide resolved
❌ Invalid acceptance test. |
{"ROUTE 1", false}, | ||
{"route 1 Boulevard", false}, | ||
{"Another bad value", false}, | ||
{"MixedCaseButSingleWord", false}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feel free to add/suggest more test values.
❌ Invalid acceptance test. |
❌ Invalid acceptance test. |
a496c24
to
2c602a8
Compare
❌ Invalid acceptance test. |
@davidgamez I've seen this test fail a few times on different PRs - let me know if there is anything I can do / look for to prevent or fix when this happens. |
Hi @briandonahue I think the test is doing what is expected to do. In this PR, as in others, there are changes made to the notices logic then the threshold of new/dropped notices is greater than 1%. What we can do is review the test results and make sure the changes that we are planning make sense. You can download the reports and review the example notices. |
@briandonahue I was looking into the acceptance test reports, and it seems that some of the new warnings are coming from the use of full statements in the fields. File/field: stop.txt/stop_desc @isabelle-dr, do you think we should trigger the mixed case warning rule in the case of |
❌ Invalid acceptance test. |
@briandonahue and @davidgamez I am surprised by the acceptance test results in this PR. It has new errors and dropped errors, which is surprising since the mixed case check is a warning. Is this because it's out of date with master? |
To @davidgamez's question
I believe the answer is yes, but I am not entirely sure. @tzujenchanmbd, is |
❌ Invalid acceptance test. |
@isabelle-dr I merged master and it's still having issues. I also apparently closed the PR earlier - no idea how I did that... re-opened. Might need @davidgamez's help with the test errors... |
❌ Invalid acceptance test. |
We have sentences in the stop.txt/stop_desc field example:
|
After a conversation during the contributor meeting, we've decided to go with
|
@briandonahue, would you be able to review the acceptance test report to evaluate if this PR removed most of the false positives, or if they still constitute a big portion? |
❌ Invalid acceptance test. |
This contribution does not follow the conventions set by the Google Java style guide. Please run the following command line at the root of the project to fix formatting errors: |
This contribution does not follow the conventions set by the Google Java style guide. Please run the following command line at the root of the project to fix formatting errors: |
❌ Invalid acceptance test. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When we designed the acceptance tests a while back, this is exactly what we had in mind for how it would be useful :)
I had a quick look at the acceptance test report, this change looks good to me, the number of false positives triggered by this notice dropped significantly with the latest changes.
Thank you for the good work @briandonahue and @davidgamez, I am glad we found a way to retain this notice in the validator!
The last step is a code review by one of the core developers! cc @davidgamez |
...ssor/src/main/java/org/mobilitydata/gtfsvalidator/processor/MixedCaseValidatorGenerator.java
Outdated
Show resolved
Hide resolved
...ssor/src/main/java/org/mobilitydata/gtfsvalidator/processor/MixedCaseValidatorGenerator.java
Outdated
Show resolved
Hide resolved
This contribution does not follow the conventions set by the Google Java style guide. Please run the following command line at the root of the project to fix formatting errors: |
❌ Invalid acceptance test. |
❌ Invalid acceptance test. |
Summary:
Should close #1402. False positives when warning for Mixed Case values such as when numbers and letters are mixed.
Expected behavior:
Values with a letter and numbers such as
A102
302-B
and those with only numbers like321
should not trigger a warning.Please make sure these boxes are checked before submitting your pull request - thanks!
gradle test
to make sure you didn't break anything