You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
But after generating it(test.pb.go), the package name of the imported third library is wrong.
import (
status "github.com/mypkg/myproject/api/status"....
)
status "github.com/mypkg/myproject/api/status" is its own package name, not the package name of a third party dependency, am I doing something wrong? Please help me. Thanks!
This default is set for your entire workspace, which includes the contents of your vendor directory, and will override the existing options set.
When using a v1buf.gen.yaml, you cannot exclude a local directory from managed mode using except, you can only provide named modules (such as the buf.build/googleapis/googleapis you currently have configured). You have two options:
Disable managed mode and manage all file options, such as option go_package manually in each file.
I would suggest migrating and then disabling the file option for your vendor folder, since this will make it very explicit which files you are not managing with managed mode and still provide you with the convenience of managed mode for your own modules.
Closing this issue for now, please feel free to re-open if you run into additional problems. Thanks!
#2622
test.proto
contentI use
buf generate proto
But after generating it(test.pb.go), the package name of the imported third library is wrong.
status "github.com/mypkg/myproject/api/status"
is its own package name, not the package name of a third party dependency, am I doing something wrong? Please help me. Thanks!Here is the full test project
The text was updated successfully, but these errors were encountered: