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

About using third-party dependencies locally #2705

Open
sishui opened this issue Jan 12, 2024 · 0 comments
Open

About using third-party dependencies locally #2705

sishui opened this issue Jan 12, 2024 · 0 comments

Comments

@sishui
Copy link

sishui commented Jan 12, 2024

#2622

test.proto content

syntax = "proto3";

package api;

option go_package = "github.com/mypkg/myproject/api";


import "status/status.proto";   # this 3rd-party deps

message MyMessage {
    status.Status status = 1;
}

I use buf generate proto

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!

Here is the full test project

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

No branches or pull requests

1 participant