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

structslop linter failing on Go 1.20 with internal error: package "errors" without types was imported from ... #962

Closed
atc0005 opened this issue Mar 22, 2023 · 4 comments
Assignees
Labels
Milestone

Comments

@atc0005
Copy link
Owner

atc0005 commented Mar 22, 2023

Overview

The linter has been provided by images from this project since 2020-11-29, but I hadn't used it regularly until added to a shared set of importable workflows.

For the Go 1.19 based go-ci-oldstable image it works fine, but for Go 1.20 images it gives errors like this one:

structslop: internal error: package "errors" without types was imported from "github.com/atc0005/send2teams/internal/config"

It was called like this from the GitHub Actions workflow from the root of a cloned repo:

structslop ./...

References

@atc0005 atc0005 added bug Something isn't working unstable stable linting labels Mar 22, 2023
@atc0005 atc0005 added this to the Next Release milestone Mar 22, 2023
@atc0005 atc0005 self-assigned this Mar 22, 2023
@atc0005
Copy link
Owner Author

atc0005 commented Mar 22, 2023

How to reproduce:

  1. docker image pull golang:1.20.2
  2. docker container run -it --rm golang:1.20.2
  3. git clone https://github.com/atc0005/check-whois
  4. cd check-whois
  5. go install github.com/orijtech/structslop/cmd/structslop@v0.0.7
  6. structslop ./...

Output:

root@6c4091e45d1e:/go/check-whois# structslop ./...
structslop: internal error: package "errors" without types was imported from "github.com/atc0005/check-whois/internal/domain"

atc0005 added a commit to atc0005/shared-project-resources that referenced this issue Mar 22, 2023
Disabling until Go 1.20 compatibility issue can be resolved.

refs atc0005/go-ci#962
@atc0005
Copy link
Owner Author

atc0005 commented Mar 22, 2023

Opened upstream bug report.

For now, I've disabled use of the linter from the shared GH workflow.

@atc0005 atc0005 modified the milestones: Next Release, Future Mar 22, 2023
@atc0005
Copy link
Owner Author

atc0005 commented Mar 24, 2023

See also:

Might be worth exploring if the upstream bug report doesn't get any traction (i.e., the project may not be maintained any longer).


@atc0005 atc0005 modified the milestones: Future, v0.10.5 May 5, 2023
@atc0005
Copy link
Owner Author

atc0005 commented May 5, 2023

This was resolved per #994

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

No branches or pull requests

1 participant