dapr / components-contrib

Community driven, reusable components for distributed apps
Apache License 2.0
548 stars 480 forks source link

Fix ptr for Dapr to compile #3468

Closed cicoyle closed 5 months ago

cicoyle commented 5 months ago

Working to finish up the last bits to get Sam's PR here running successfully in CI, but we need to fix the ptr here: opts.ContinuationToken = &q.token which requires the version bumped for azcosmos. In the linter step for the PR you will see this:

  Error: ../../../go/pkg/mod/github.com/dapr/components-contrib@v1.13.2/state/azure/cosmosdb/cosmosdb_query.go:264:[28](https://github.com/dapr/dapr/actions/runs/9702087968/job/26777134911?pr=7847#step:6:30): cannot use q.token (variable of type string) as *string value in assignment
  Error: ../../../go/pkg/mod/github.com/dapr/components-contrib@v1.13.2/state/azure/cosmosdb/cosmosdb_query.go:288:11: cannot use queryResponse.ContinuationToken (variable of type *string) as string value in assignment) (typecheck)

This PR fixes the above issue

yaron2 commented 5 months ago

1.13 is using Go 1.21

cicoyle commented 5 months ago

1.13 is using Go 1.21

I'll fix this. One sec

cicoyle commented 5 months ago

1.13 is using Go 1.21

I'll fix this. One sec

Actually I can't. Since

go: github.com/Azure/azure-sdk-for-go/sdk/data/azcosmos@v1.0.0 requires go >= 1.22.0; switching to go1.22.4

But to fix the ptr issue in dapr I need that version of azcosmos

ItalyPaleAle commented 5 months ago

Dependencies have been updated in #3463. In a release branch, please don't change the Go compiler version or any dependency such as cloud provider SDKs unless there are critical bugs or security issues.

cicoyle commented 5 months ago

closing since the indirect dependency needed to be lowered in the dapr PR to resolve this issue. Artur beat me to committing the fix on Sams branch, but it should be resolved now