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

Sort by fingerprint and line number for ignorefile #1457

Merged
merged 1 commit into from Feb 13, 2020

Conversation

@ngan
Copy link
Contributor

ngan commented Feb 13, 2020

When fingerprints are the same, the sorting is not deterministic and causes diffs in ignorefile when it gets updated. Add line number to the sorting algo as a tie breaker.

This is done here as well:
https://github.com/presidentbeef/brakeman/blob/master/lib/brakeman/report/report_json.rb#L41

@ngan ngan force-pushed the ngan:fix-config-sorting branch from e31db72 to 312d573 Feb 13, 2020
When fingerprints are the same, the sorting is not deterministic and
causes diffs in ignorefile when it gets updated. Add line number to the
sorting algo as a tie breaker.

This is done here as well:
https://github.com/presidentbeef/brakeman/blob/master/lib/brakeman/report/report_json.rb#L41
@ngan ngan force-pushed the ngan:fix-config-sorting branch from 312d573 to ff853ad Feb 13, 2020
@presidentbeef presidentbeef merged commit 2b0a101 into presidentbeef:master Feb 13, 2020
9 checks passed
9 checks passed
ci/circleci: default Your tests passed on CircleCI!
Details
ci/circleci: test-2-3 Your tests passed on CircleCI!
Details
ci/circleci: test-2-4 Your tests passed on CircleCI!
Details
ci/circleci: test-2-5 Your tests passed on CircleCI!
Details
ci/circleci: test-2-6 Your tests passed on CircleCI!
Details
ci/circleci: upload-coverage Your tests passed on CircleCI!
Details
codeclimate All good!
Details
codeclimate/diff-coverage 100% (98% threshold)
Details
codeclimate/total-coverage 95% (0.0% change)
Details
@ngan ngan deleted the ngan:fix-config-sorting branch Feb 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants
You can’t perform that action at this time.