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

SA1019: grouper.IDAliases is deprecated #4431

Open
JamieMagee opened this issue Dec 3, 2024 · 2 comments
Open

SA1019: grouper.IDAliases is deprecated #4431

JamieMagee opened this issue Dec 3, 2024 · 2 comments

Comments

@JamieMagee
Copy link
Contributor

Describe the bug
Since #4405 was merged I am seeing the following lint errors

probes/hasOSVVulnerabilities/impl.go:63:28: SA1019: grouper.IDAliases is deprecated: this is now private and should not be used outside the scanner (staticcheck)
        aliasVulnerabilities := []grouper.IDAliases{}
                                  ^
probes/hasOSVVulnerabilities/impl.go:65:55: SA1019: grouper.IDAliases is deprecated: this is now private and should not be used outside the scanner (staticcheck)
                aliasVulnerabilities = append(aliasVulnerabilities, grouper.IDAliases(vuln))
                                                                    ^
probes/hasOSVVulnerabilities/impl.go:68:9: SA1019: grouper.Group is deprecated: this is now private and should not be used outside the scanner (staticcheck)
        IDs := grouper.Group(aliasVulnerabilities)
               ^
probes/hasOSVVulnerabilities/impl.go:24:2: SA1019: "github.com/google/osv-scanner/pkg/grouper" is deprecated: this is now private and should not be used outside the scanner (staticcheck)
        "github.com/google/osv-scanner/pkg/grouper"

Reproduction steps
Steps to reproduce the behavior:

  1. Checkout lastest main
  2. run make check-linter

Expected behavior
No errors

Additional context
The change was made upstream in google/osv-scanner#1309. And the package is set to be removed in google/osv-scanner#1376.

@spencerschrock
Copy link
Member

Might as well wait until the v2 alpha to see what new API we have to work with. Worst case we can write a helper to do the grouping for our own needs

@spencerschrock
Copy link
Member

the linter warnings were silenced in #4449 , but leaving this open to track the migration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

2 participants