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

Incorrect handling of packages without an alias #19

Open
sharwell opened this issue Mar 17, 2017 · 0 comments
Open

Incorrect handling of packages without an alias #19

sharwell opened this issue Mar 17, 2017 · 0 comments
Labels

Comments

@sharwell
Copy link
Member

sharwell commented Mar 17, 2017

When an import is specified using a path without an alias given, the package identifier assigned to that import is expected to be the single package seen in source files in that location. Currently GoWorks assumes that the package name and the folder name are the same, but this is not always the case.

💡 A workaround when this occurs is to explicitly assign an alias to the import which happens to match the true name of the package:

// Broken:
import (
  "github.com/zalando/go-keyring/secret_service"
)

// Working:
import (
  ss "github.com/zalando/go-keyring/secret_service"
)
@sharwell sharwell added the bug label Mar 17, 2017
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