Re: [go-nuts] Re: Golang Error - When marshelling data

2016-06-17 Thread Konstantin Khomoutov
On Fri, 17 Jun 2016 00:50:20 -0700 (PDT) User123 wrote: [...] > When i return http response from a function should i use > *func makeCalls() (string, error, *http.Response, error) * > or > *func makeCalls() (string, error, http.Response, error) * > > For the struct i created above what should b

[go-nuts] Re: Golang Error - When marshelling data

2016-06-17 Thread User123
Have found the cause of the issue The message that I was trying to marshall had *0x10a3c2d0 (when fmt.Println) *which was http response. >From https://github.com/revel/revel/issues/1037 i found that *Since Go 1.6 http.Request struct contains `Cancel <-chan struct{}` which* *results in `json:

Re: [go-nuts] Re: Golang Error - When marshelling data

2016-06-16 Thread Konstantin Khomoutov
On Thu, 16 Jun 2016 04:55:41 -0700 (PDT) User123 wrote: > Is it giving error since it has null values? > > I'm just not able to get it. Since this code works perfectly fine in > 1.4.2 A wild guess: 1) Your error message is: json: unsupported type: <-chan struct {} and indeed the doc

[go-nuts] Re: Golang Error - When marshelling data

2016-06-16 Thread User123
Is it giving error since it has null values? I'm just not able to get it. Since this code works perfectly fine in 1.4.2 On Thursday, June 16, 2016 at 4:08:38 PM UTC+5:30, User123 wrote: > > I cannot provide the full code sincethere are some dependencies. > > I did fmt.println on the data that I

[go-nuts] Re: Golang Error - When marshelling data

2016-06-16 Thread User123
I cannot provide the full code sincethere are some dependencies. I did fmt.println on the data that I am trying to marshall and it looks like this *%!(EXTRA main.JobResponseRoot={{92b4f95b309e8db0f8d56afadefc} http.res {[{{ map[] } "Date","Time","Time_Zone","Source","Name","Raw_Data"* * 0x10a

[go-nuts] Re: Golang Error - When marshelling data

2016-06-16 Thread Dave Cheney
Hello, Can you please provide a runnable code sample that shows the problem. Thanks Dave On Thursday, 16 June 2016 19:44:00 UTC+10, User123 wrote: > > The data I am trying to marshal contains serialized data. This data is > received in http response. > > It works perfectly when I try in versi