Page MenuHomeSoftware Heritage

patterns: adds a list of common patterns to exclude
ClosedPublic

Authored by marmoute on Sep 28 2022, 7:34 PM.

Details

Summary

This is a first batch of things (VCS and tools) we know that we don't
want to scan. The list will likely extend in the future and we should
also apply DVCS's ignore request too.

This will need D8571 to have landed to actually produce result when scanning something else than '.'

Diff Detail

Repository
rDTSCN Code scanner
Branch
ignore-common
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 31896
Build 49920: Phabricator diff pipeline on jenkinsJenkins console · Jenkins
Build 49919: arc lint + arc unit

Event Timeline

Build has FAILED

Patch application report for D8572 (id=30924)

Rebasing onto f4f0917769...

Current branch diff-target is up to date.
Changes applied before test
commit 4c57d130f6822d9e054c5161873781b6218ec147
Author: Pierre-Yves David <pierre-yves.david@ens-lyon.org>
Date:   Wed Sep 28 19:32:53 2022 +0200

    patterns: adds a list of common patterns to exclude
    
    This is a first batch of things (VCS and tools) we know that we don't
    want to scan. The list will likely extend in the future and we should
    also apply DVCS's ignore request too.

Link to build: https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/184/
See console output for more information: https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/184/console

Harbormaster returned this revision to the author for changes because remote builds failed.Sep 28 2022, 7:34 PM
Harbormaster failed remote builds in B31896: Diff 30924!
fixed black and flak8 warning

Build is green

Patch application report for D8572 (id=30925)

Rebasing onto f4f0917769...

Current branch diff-target is up to date.
Changes applied before test
commit ff402405f79f0ea206481567a3edf8095b4ed4c4
Author: Pierre-Yves David <pierre-yves.david@ens-lyon.org>
Date:   Wed Sep 28 19:32:53 2022 +0200

    patterns: adds a list of common patterns to exclude
    
    This is a first batch of things (VCS and tools) we know that we don't
    want to scan. The list will likely extend in the future and we should
    also apply DVCS's ignore request too.

See https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/185/ for more details.

ardumont added a subscriber: ardumont.

lgtm

"As usual", i don't know how well that module is covered, it'd be good to
have a test around the scan function to check it behaves as we want.

Another suggestion inline.

swh/scanner/scanner.py
85

Maybe add a todo on it to make this configurable from the usual swh config file.

This revision is now accepted and ready to land.Sep 29 2022, 9:47 AM

lgtm

"As usual", i don't know how well that module is covered, it'd be good to
have a test around the scan function to check it behaves as we want.

Another suggestion inline.

I am planning to follow up with more cleanup and improved testing.
(especially once the swh.core logic is fixed/refactored)

added the TODO comment suggested by ardumont

Build is green

Patch application report for D8572 (id=30957)

Rebasing onto f4f0917769...

Current branch diff-target is up to date.
Changes applied before test
commit 4363c9a9e3079ea84d8ea8e6a99d14055bba55ac
Author: Pierre-Yves David <pierre-yves.david@ens-lyon.org>
Date:   Wed Sep 28 19:32:53 2022 +0200

    patterns: adds a list of common patterns to exclude
    
    This is a first batch of things (VCS and tools) we know that we don't
    want to scan. The list will likely extend in the future and we should
    also apply DVCS's ignore request too.

See https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/187/ for more details.