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

go 1.14 context.WithValue value is map type error #39909

Closed
kjcx opened this issue Jun 29, 2020 · 1 comment
Closed

go 1.14 context.WithValue value is map type error #39909

kjcx opened this issue Jun 29, 2020 · 1 comment
Labels
FrozenDueToAge WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.

Comments

@kjcx
Copy link

kjcx commented Jun 29, 2020

What version of Go are you using (go version)?

$ go version
1.14.4

Does this issue reproduce with the latest release?

yes 1.13 is right

What operating system and processor architecture are you using (go env)?

go env Output
$ go env

What did you do?

What did you expect to see?

package main

import (
"context"
"fmt"
)

func main(){
var md = make(map[string]string)
md["test"] = "it a map"
ctx := context.WithValue(context.TODO(),"key",md)
fmt.Println(ctx)
}
context.TODO.WithValue(type string, val

context WithValue donot write map type

What did you see instead?

can write map

@davecheney
Copy link
Contributor

Do you mean that when you printed the value of ctx it was missing some information?

@davecheney davecheney added the WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. label Jun 29, 2020
@kjcx kjcx closed this as completed Jul 8, 2020
@golang golang locked and limited conversation to collaborators Jul 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Projects
None yet
Development

No branches or pull requests

3 participants