-
Notifications
You must be signed in to change notification settings - Fork 841
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
cannot find module providing package github.com/Azure/azure-sdk-for-go/sdk/internal/runtime #15384
Comments
Unfortunately this is due to mixing of module/no-module code. Our SDK is split into two buckets. Our current SDK, which we call track 1, is all the content under the The problem here is that when you We have an issue tracking the conversion of track 1 to a Go module here but there is cost associated with this change. Until this is sorted out I fear that this problem will surface from time to time. At any rate, the offending module has been deleted in #15388, so in the future this should not happen. |
I'm facing this exact same issue today, various modules have this
and
These are the only ones I've tested but could happen with more. |
@abelal83 do you see this when creating a new app, or is there more to it? I'm guessing the latter as it works for me with a new app, but maybe I'm missing something (my repro is with Go 1.17).
|
Yup brand new app,
I see the same result as you
However, the issue arises when I use with other imports package main
import (
"fmt"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/arm"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/cosmos/armcosmos"
)
func main() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
fmt.Print(err)
return
}
fmt.Print(cred)
con := arm.NewDefaultConnection(cred, nil)
fmt.Print(con)
client := armcosmos.NewDatabaseClient(con, "xyz")
} The error I get in VS Code is
The other 2 packages import and work just fine. |
Ah I see. We're in the middle of refactoring the
We'll also be updating our docs/samples as part of the refresh to reference the new packages. |
Thanks for this. It's late here but I'll be sure to give it a try tomorrow. |
works perfectly now, thank you @jhendrixMSFT. |
Hi @adeturner. Thank you for opening this issue and giving us the opportunity to assist. We believe that this has been addressed. If you feel that further discussion is needed, please add a comment with the text “ |
1 similar comment
Hi @adeturner. Thank you for opening this issue and giving us the opportunity to assist. We believe that this has been addressed. If you feel that further discussion is needed, please add a comment with the text “ |
Thanks |
Apologies, I had to reopen this; whilst the original issue is fixed (go get everything) the latest build is still problematic for me. Is there an easy workaround? Starting with an empty cache...
Its quite hard to understand all the versions, releases and dependencies between the two tracks and for each module; what should and shouldnt be working. Is this documented/coded somewhere? |
I think the problem here is that your path to See https://github.com/Azure/azure-sdk-for-go/tree/main/sdk/servicebus/armservicebus |
Thanks Joel... I did get it working but forgot to update. I'll be honest, I didn't really understand how to use the servicebus library so gave up and wrapped az cli to get the job done, and then azure-service-bus-go for the client+topic/sub building. If there is any documentation or samples that explains how to use the auto-generated APIs with a local service principal I've love to see it. That said, even for azure-service-bus-go I mostly had to read the code to work it out... |
Hi, I have the same issue with package
I don't get why the error is about |
It seems that it worked by removing |
In WSL2, I'm naively trying to install the SDK, it cant find sdk/internal/runtime package
$ go version
go version go1.16.5 linux/amd64
$ go get -u -d github.com/Azure/azure-sdk-for-go/...
go: downloading github.com/Azure/azure-sdk-for-go v56.3.0+incompatible
go: downloading github.com/Azure/azure-sdk-for-go/sdk/armcore v0.8.0
go: downloading github.com/Azure/azure-sdk-for-go/sdk/azcore v0.19.0
go: downloading github.com/Azure/azure-sdk-for-go/sdk/internal v0.7.0
go: downloading github.com/Azure/azure-sdk-for-go/sdk/monitor/armmonitor v0.1.0
go: downloading github.com/Azure/go-autorest v14.2.0+incompatible
go: downloading github.com/Azure/go-autorest/autorest v0.11.19
go: downloading github.com/Azure/go-autorest/autorest/date v0.3.0
go: downloading github.com/Azure/go-autorest/autorest/to v0.4.0
go: downloading github.com/Azure/go-autorest/autorest v0.11.20
go: downloading github.com/Azure/go-autorest/autorest/validation v0.3.1
go: downloading github.com/Azure/go-autorest/tracing v0.6.0
go: downloading github.com/Azure/go-autorest/logger v0.2.1
go: downloading github.com/Azure/go-autorest/autorest/adal v0.9.13
go: downloading github.com/Azure/go-autorest/autorest/azure/auth v0.5.8
go: downloading github.com/Azure/go-autorest/autorest/adal v0.9.15
go: downloading github.com/Azure/go-autorest/autorest/azure/cli v0.4.2
go: downloading github.com/Azure/go-autorest/autorest/azure/cli v0.4.3
go: downloading github.com/Azure/azure-sdk-for-go v0.2.0-beta
github.com/Azure/azure-sdk-for-go/sdk/armcore imports
github.com/Azure/azure-sdk-for-go/sdk/internal/runtime: cannot find module providing package github.com/Azure/azure-sdk-for-go/sdk/internal/runtime
Just updating to mention I can see it in a branch only
[https://github.com/Azure/azure-sdk-for-go/blob/7d922f1ae7f000c2b6a7360503500a252fc962a2/sdk/internal/runtime/frame_error.go#L17]
It affects individual downloads of azcore too
The text was updated successfully, but these errors were encountered: