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

storage: Simple GAE Standard app is broken #686

Closed
imjasonh opened this issue Jun 27, 2017 · 3 comments
Closed

storage: Simple GAE Standard app is broken #686

imjasonh opened this issue Jun 27, 2017 · 3 comments
Assignees

Comments

@imjasonh
Copy link
Contributor

My simplified GAE app is:

func init() {
  http.HandleFunc("/", handler)
}
func handler(w http.ResponseWriter, r *http.Request) {
  ctx := appengine.NewContext(r)
  client, err := storage.NewClient(ctx, option.WithHTTPClient(urlfetch.Client(ctx)))
  if err != nil {
    log.Errorf(ctx, "storage.NewClient: %v", err)
    return
  }
  obj := client.Bucket(bucket).Object(object).NewWriter(ctx)
  if _, err := io.Copy(obj, strings.NewReader("hello")); err != nil {
    log.Errorf(ctx, "io.Copy: %v", err)
    return
  }
  if err := obj.Close(); err != nil {
    log.Errorf(ctx, "obj.Close: %v", err)
    return
  }
}

When I deploy with gcloud app deploy I get this error:

google.golang.org/cloud/storage/acl.go:65: invalid type assertion: v.(map[string]<inter>) (non-interface type *storage.ObjectAccessControl on left)
google.golang.org/cloud/storage/acl.go:144: invalid type assertion: v.(map[string]<inter>) (non-interface type *storage.ObjectAccessControl on left)
google.golang.org/cloud/storage/storage.go:49: undefined: storage.DevstorageFull_controlScope
google.golang.org/cloud/storage/storage.go:53: undefined: storage.DevstorageRead_onlyScope
google.golang.org/cloud/storage/storage.go:57: undefined: storage.DevstorageRead_writeScope
@imjasonh
Copy link
Contributor Author

PEBKAC

@amaendeepm
Copy link

Sorry, the resolution is not clear here. I am getting the same exact error in acl.go library while trying to deploy. Could you suggest the fix here ?

google.golang.org/cloud/storage/acl.go:101: invalid type assertion: v.(map[string]) (non-interface type *storage.ObjectAccessControl on left)
google.golang.org/cloud/storage/acl.go:174: invalid type assertion: v.(map[string]) (non-interface type *storage.ObjectAccessControl on left)

@jba jba self-assigned this Oct 30, 2017
@vsoch
Copy link

vsoch commented Jul 9, 2021

I just hit this error trying to install https://github.com/regclient/regclient

yoshi-automation added a commit that referenced this issue Nov 29, 2021
This is an auto-generated regeneration of the gapic clients by
cloud.google.com/go/internal/gapicgen. Once the corresponding genproto PR is
submitted, genbot will update this PR with a newer dependency to the newer
version of genproto and assign reviewers to this PR.

If you have been assigned to review this PR, please:

- Ensure that the version of genproto in go.mod has been updated.
- Ensure that CI is passing. If it's failing, it requires your manual attention.
- Approve and submit this PR if you believe it's ready to ship.

Corresponding genproto PR: googleapis/go-genproto#726

Changes:

fix(compute): make parent_id fields required compute move and insert methods (#686)

  Source-Link: googleapis/googleapis@02df998

build(networkconnectivity): correct artifact name for npm
  PiperOrigin-RevId: 411807571
  Source-Link: googleapis/googleapis@221556e

docs(retail): Keep the API doc up-to-date feat: update grpc service config settings to reflect correct API deadlines
  PiperOrigin-RevId: 411660243
  Source-Link: googleapis/googleapis@72adf13

feat(servicecontrol): add C++ rules for many Cloud services
  PiperOrigin-RevId: 411620635
  Source-Link: googleapis/googleapis@eddd3d8

build(metastore): correct artifact name for npm
  PiperOrigin-RevId: 411598711
  Source-Link: googleapis/googleapis@970cd21

chore(longrunning): generate java files for google/api chore: generate java files for google/cloud/audit chore: generate java files for google/geo/type chore: generate java files for google/logging/type chore: generate java files for google/longrunning chore: generate java files for google/rpc chore: generate java files for google/rpc/context chore: generate java files for google/type chore: generate java files for google/cloud
  PiperOrigin-RevId: 411585075
  Source-Link: googleapis/googleapis@b21a21e

feat(contactcenterinsights): remove feature flag disable_issue_modeling
  PiperOrigin-RevId: 411140666
  Source-Link: googleapis/googleapis@9a182e6

feat(contactcenterinsights): new feature flag disable_issue_modeling docs: fixed formatting issues in the reference documentation
  PiperOrigin-RevId: 411102531
  Source-Link: googleapis/googleapis@68b0c8a

feat(securitycenter): Added a new API method UpdateExternalSystem, which enables updating a finding w/ external system metadata. External systems are a child resource under finding, and are housed on the finding itself, and can also be filtered on in Notifications, the ListFindings and GroupFindings API
  PiperOrigin-RevId: 411093163
  Source-Link: googleapis/googleapis@be8f988

feat(compute): Switch to string enums for compute (#685)
  Also introduce gapic_yaml for java clients to override default LRO configuration (which has too way too long timeouts).

  Also cleanup regenerate other files (grpc_service_config and service yaml)
  Source-Link: googleapis/googleapis@8ce4ea6

docs(cloudtasks): fix docstring formatting
  Committer: @parthea
  PiperOrigin-RevId: 410919520
  Source-Link: googleapis/googleapis@b5274f7

build(spanner/admin/database): add published name under submodules
  PiperOrigin-RevId: 410900101
  Source-Link: googleapis/googleapis@c246c88

chore(vmmigration): Prepare vmmigration  v1 BUILD.bazel for release
  PiperOrigin-RevId: 410873197
  Source-Link: googleapis/googleapis@6e8a083
yoshi-automation added a commit that referenced this issue Nov 29, 2021
This is an auto-generated regeneration of the gapic clients by
cloud.google.com/go/internal/gapicgen. Once the corresponding genproto PR is
submitted, genbot will update this PR with a newer dependency to the newer
version of genproto and assign reviewers to this PR.

If you have been assigned to review this PR, please:

- Ensure that the version of genproto in go.mod has been updated.
- Ensure that CI is passing. If it's failing, it requires your manual attention.
- Approve and submit this PR if you believe it's ready to ship.

Corresponding genproto PR: googleapis/go-genproto#726

Changes:

fix(compute): make parent_id fields required compute move and insert methods (#686)

  Source-Link: googleapis/googleapis@02df998

build(networkconnectivity): correct artifact name for npm
  PiperOrigin-RevId: 411807571
  Source-Link: googleapis/googleapis@221556e

docs(retail): Keep the API doc up-to-date feat: update grpc service config settings to reflect correct API deadlines
  PiperOrigin-RevId: 411660243
  Source-Link: googleapis/googleapis@72adf13

feat(servicecontrol): add C++ rules for many Cloud services
  PiperOrigin-RevId: 411620635
  Source-Link: googleapis/googleapis@eddd3d8

build(metastore): correct artifact name for npm
  PiperOrigin-RevId: 411598711
  Source-Link: googleapis/googleapis@970cd21

chore(longrunning): generate java files for google/api chore: generate java files for google/cloud/audit chore: generate java files for google/geo/type chore: generate java files for google/logging/type chore: generate java files for google/longrunning chore: generate java files for google/rpc chore: generate java files for google/rpc/context chore: generate java files for google/type chore: generate java files for google/cloud
  PiperOrigin-RevId: 411585075
  Source-Link: googleapis/googleapis@b21a21e

feat(contactcenterinsights): remove feature flag disable_issue_modeling
  PiperOrigin-RevId: 411140666
  Source-Link: googleapis/googleapis@9a182e6

feat(contactcenterinsights): new feature flag disable_issue_modeling docs: fixed formatting issues in the reference documentation
  PiperOrigin-RevId: 411102531
  Source-Link: googleapis/googleapis@68b0c8a

feat(securitycenter): Added a new API method UpdateExternalSystem, which enables updating a finding w/ external system metadata. External systems are a child resource under finding, and are housed on the finding itself, and can also be filtered on in Notifications, the ListFindings and GroupFindings API
  PiperOrigin-RevId: 411093163
  Source-Link: googleapis/googleapis@be8f988

feat(compute): Switch to string enums for compute (#685)
  Also introduce gapic_yaml for java clients to override default LRO configuration (which has too way too long timeouts).

  Also cleanup regenerate other files (grpc_service_config and service yaml)
  Source-Link: googleapis/googleapis@8ce4ea6

docs(cloudtasks): fix docstring formatting
  Committer: @parthea
  PiperOrigin-RevId: 410919520
  Source-Link: googleapis/googleapis@b5274f7

build(spanner/admin/database): add published name under submodules
  PiperOrigin-RevId: 410900101
  Source-Link: googleapis/googleapis@c246c88

chore(vmmigration): Prepare vmmigration  v1 BUILD.bazel for release
  PiperOrigin-RevId: 410873197
  Source-Link: googleapis/googleapis@6e8a083
codyoss pushed a commit that referenced this issue Dec 3, 2021
This is an auto-generated regeneration of the gapic clients by
cloud.google.com/go/internal/gapicgen. Once the corresponding genproto PR is
submitted, genbot will update this PR with a newer dependency to the newer
version of genproto and assign reviewers to this PR.

If you have been assigned to review this PR, please:

- Ensure that the version of genproto in go.mod has been updated.
- Ensure that CI is passing. If it's failing, it requires your manual attention.
- Approve and submit this PR if you believe it's ready to ship.

Corresponding genproto PR: googleapis/go-genproto#726

Changes:

fix(compute): make parent_id fields required compute move and insert methods (#686)

  Source-Link: googleapis/googleapis@02df998

build(networkconnectivity): correct artifact name for npm
  PiperOrigin-RevId: 411807571
  Source-Link: googleapis/googleapis@221556e

docs(retail): Keep the API doc up-to-date feat: update grpc service config settings to reflect correct API deadlines
  PiperOrigin-RevId: 411660243
  Source-Link: googleapis/googleapis@72adf13

feat(servicecontrol): add C++ rules for many Cloud services
  PiperOrigin-RevId: 411620635
  Source-Link: googleapis/googleapis@eddd3d8

build(metastore): correct artifact name for npm
  PiperOrigin-RevId: 411598711
  Source-Link: googleapis/googleapis@970cd21

chore(longrunning): generate java files for google/api chore: generate java files for google/cloud/audit chore: generate java files for google/geo/type chore: generate java files for google/logging/type chore: generate java files for google/longrunning chore: generate java files for google/rpc chore: generate java files for google/rpc/context chore: generate java files for google/type chore: generate java files for google/cloud
  PiperOrigin-RevId: 411585075
  Source-Link: googleapis/googleapis@b21a21e

feat(contactcenterinsights): remove feature flag disable_issue_modeling
  PiperOrigin-RevId: 411140666
  Source-Link: googleapis/googleapis@9a182e6

feat(contactcenterinsights): new feature flag disable_issue_modeling docs: fixed formatting issues in the reference documentation
  PiperOrigin-RevId: 411102531
  Source-Link: googleapis/googleapis@68b0c8a

feat(securitycenter): Added a new API method UpdateExternalSystem, which enables updating a finding w/ external system metadata. External systems are a child resource under finding, and are housed on the finding itself, and can also be filtered on in Notifications, the ListFindings and GroupFindings API
  PiperOrigin-RevId: 411093163
  Source-Link: googleapis/googleapis@be8f988

feat(compute): Switch to string enums for compute (#685)
  Also introduce gapic_yaml for java clients to override default LRO configuration (which has too way too long timeouts).

  Also cleanup regenerate other files (grpc_service_config and service yaml)
  Source-Link: googleapis/googleapis@8ce4ea6

docs(cloudtasks): fix docstring formatting
  Committer: @parthea
  PiperOrigin-RevId: 410919520
  Source-Link: googleapis/googleapis@b5274f7

build(spanner/admin/database): add published name under submodules
  PiperOrigin-RevId: 410900101
  Source-Link: googleapis/googleapis@c246c88

chore(vmmigration): Prepare vmmigration  v1 BUILD.bazel for release
  PiperOrigin-RevId: 410873197
  Source-Link: googleapis/googleapis@6e8a083
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

4 participants