[go-nuts] Download a zip file from a URL

2022-03-09 Thread Gaurav
err != nil { return err } return nil } func main() { err := DownloadFile("https://store1.gofile.io/download/78f1898f-2b02-465a-a39c-4cf7e35822a2/test.zip";) if err != nil { fmt.Println(err) } } What am I missing here? Regards Gaurav -- You received this message because you are subscrib

Re: [go-nuts] ANN: A new package to wrap errors and record a stack trace

2022-01-03 Thread Gaurav Maheshwari
he Google Groups > "golang-nuts" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to golang-nuts+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/golang-nuts/CAKLmikOVd%3

Re: [go-nuts] ANN: A new package to wrap errors and record a stack trace

2022-01-03 Thread Gaurav Maheshwari
So in a way, > github.com/cockroachdb/errors has too much stuff for me, so I prefer > something leaner. > > > Mitar > > On Mon, Jan 3, 2022 at 7:27 AM Gaurav Maheshwari > wrote: > > > > Did you check https://github.com/cockroachdb/errors ? How does it > differ

[go-nuts] Re: Go API receive calls twice when hit through browser

2020-09-25 Thread gaurav...@gmail.com
First request must be OPTION and second must be GET/ POST , This is default browser behaviour. On Friday, 25 September 2020 at 15:22:27 UTC+5:30 smartaq...@gmail.com wrote: > Team, > > Hi all, hope you are doing good. > > I've made a hosted a small api on my windows 10 enterprise machine: > > `

[go-nuts] syscall.GetQueuedCompletionStatus returning qty as 0

2019-08-21 Thread gaurav
I am using a library which is watching a NAS directory for changes using golang syscall on windows platform. while making syscall.GetQueuedCompletionStatus I am getting value of qty as 0, I tried to check the syscall source code but not able to debug it. syscall source code is one of the comp

Re: [go-nuts] Not getting correct results with sort.Slice().

2017-11-09 Thread gaurav
I realized the mistake :-p It needs to be this: sort.Slice(indexes, func(i, j int) bool { return ratings[indexes[i]] < ratings[indexes[j]] }) On Thursday, November 9, 2017 at 6:02:29 PM UTC+5:30, gaurav wrote: > > Hi Jan, > > I am still unable to understand why is the contr

Re: [go-nuts] Not getting correct results with sort.Slice().

2017-11-09 Thread Gaurav Agarwal
int index int } And then create slice of these structs and defined less() based on rating, would it change anything conceptually? On Thu, Nov 9, 2017 at 5:54 PM, Jan Mercl <0xj...@gmail.com> wrote: > On Thu, Nov 9, 2017 at 1:17 PM gaurav wrote: > > > I must be missing something ba

[go-nuts] Not getting correct results with sort.Slice().

2017-11-09 Thread gaurav
Hi All, I must be missing something basic here: a simple usage of sort.Slice is not sorting the slice correctly for me. I must be missing something very basic here; could someone please check this out? https://play.golang.org/p/AEMq_9ml1n package main import ( "fmt" "sort" ) func main() { rati

[go-nuts] Should we use frameworks like Go IRIS based on fasthttp to create foundation of my web application or do I start create framework from scratch

2017-04-30 Thread Gaurav Rai
Should we use frameworks like Go IRIS based on fasthttp to create foundation of our web application or do we should start create our framework from scratch for our web application Where I can found good tutorials or documentation about advances topic in golang based on like syscall,exec,os

Re: [go-nuts] Understanding go routine heap

2016-08-20 Thread gaurav
I may be trying to suggest more than I properly understand, but looking at src for WaitGroup, - Done() calls and Add(-1) which in turn calls atomic.AddUint64() that should be a store-release - Wait() calls a atomic.LoadUint64() that should be a load-acquire So anything written before calling D

Re: [go-nuts] Fast ConcurrentCounter without memory sharing

2016-08-14 Thread Gaurav Agarwal
at we wanted to know which is it, at any given moment so as to access the required memory location. Do you have any alternate ideas for this? On Sun, Aug 14, 2016 at 10:18 PM, Ian Lance Taylor wrote: > On Sun, Aug 14, 2016 at 2:25 AM, gaurav wrote: > > > > How do I get to know th

[go-nuts] Fast ConcurrentCounter without memory sharing

2016-08-14 Thread gaurav
de visible to all cores immediately? Or else, does atomic.LoadInt32()guarantee to return the latest values? I think the problem is that atomic package does not say anything about visibility of memory updates across cores. -- cheers, gaurav -- You received this message because you are

Re: [go-nuts] Re: go process memory limits and gurantees

2016-08-09 Thread gaurav
ould it would have helped here? I think this is what you were mentioning above? > > > *From: *> on behalf of gaurav < > gaurava...@gmail.com > > *Date: *Tuesday, August 9, 2016 at 7:17 AM > *To: *golang-nuts > > *Subject: *[go-nuts] Re: go process memory limits a

[go-nuts] Re: go process memory limits and gurantees

2016-08-09 Thread gaurav
er and size. > > > On Sunday, August 7, 2016 at 4:37:42 PM UTC+8, gaurav wrote: >> >> Hi everyone, >> >> I am a bit unclear about how to specify memory limits for Go processes >> and what can be assumed about the Garbage collection behavior when >> approa

[go-nuts] go process memory limits and gurantees

2016-08-08 Thread gaurav
Bumping the thread up one last time.. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://gr

[go-nuts] go process memory limits and gurantees

2016-08-07 Thread gaurav
nforce the above desired behavior. Keeping it at default will probably only guarantee me that half the heap contains live/useful objects at any give time. Please let me know if there is something I have missed to read regarding this or if there is already a way to achieve this? -- cheers, gaura