Re: [go-nuts] Forking/transfering a repository and import paths

2018-12-13 Thread Sotirios Mantziaris
Hi, if i understood correctly this solves the location of the repository path but the repo path will still point to the old repo. It would be nice if the repo location could be anywhere and the import path anything e.g. hosted on any machine with the root package name be something different (locat

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread snmed
Indeed vendoring is a possible way we will consider that option but with go mod instead with dep. I strongly believe that the module way go is heading is the right way, but i'd like to have more documentation about using go modules in an air gapped network environment. Anyway thank you for your

[go-nuts] Presidence of Operators

2018-12-13 Thread 伊藤和也
Can I say the precedence of paretheses are lower than unary operators and higher than binary operators. unary operators (high) ↑ parentheses ↑ ↑ binary operators (low) -- You received this message because you are subscribed to the Google Groups "golang-nu

[go-nuts] Is tip.golang.org down?

2018-12-13 Thread Tharaneedharan Vilwanathan
I see this error message: builder.Init: build cache is disabled by GOCACHE=off, but required as of Go 1.12 exit status 1 Any problem? Regards dharani -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop rec

Re: [go-nuts] Zombie Child process not being claimed by wait

2018-12-13 Thread Ian Lance Taylor
On Thu, Dec 13, 2018 at 9:33 PM wrote: > > I'm debugging an odd issue with Process.Wait, and wondering if anyone would > have any ideas / hit this before: > > I have a go process, which starts a child process (it sets DEATH_SIGNAL on > that process, not sure if it's relevant). > Then, a backgrou

Re: [go-nuts] Homoiconic metaprogramming in Go

2018-12-13 Thread Ian Lance Taylor
On Thu, Dec 13, 2018 at 9:25 PM Dmitry Ponyatov wrote: > > Is it possible to do metaprogramming in Go? > > What I want to have is a way to run arbitrary code in compile time, which has > full access to compiler data structures > (parsed syntax trees, compiler stages callbacks, direct code generat

[go-nuts] Zombie Child process not being claimed by wait

2018-12-13 Thread rodrigo . toste . gomes
I'm debugging an odd issue with Process.Wait, and wondering if anyone would have any ideas / hit this before: I have a go process, which starts a child process (it sets DEATH_SIGNAL on that process, not sure if it's relevant). Then, a background go routine runs Wait on that process in order to s

[go-nuts] Unix binary installations for Go

2018-12-13 Thread rpolzer via golang-nuts
Hi, I am wondering what is the recommended way to package a Unix binary written in Go. What I want, to adhere to standard Unix conventions: - Something like "./configure --prefix=/opt/foo" that "does something" to set a final install location. It should also autodetect possible optional depen

[go-nuts] Homoiconic metaprogramming in Go

2018-12-13 Thread Dmitry Ponyatov
Is it possible to do metaprogramming in Go? What I want to have is a way to run arbitrary code in compile time, which has full access to compiler data structures (parsed syntax trees, compiler stages callbacks, direct code generator calls). As a variant, it can be some Lisp system runs between

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread Nathan Fisher
We use dep at work and commit the vendor folder. The main benefit we see is that it ensures consistent builds across machines, tends to be faster, and allows offline development. assuming you don’t have to use a third party security or infrastructure team to download the dependencies. If you do the

[go-nuts] Re: scanner.Scan is holding my goroutine ;(

2018-12-13 Thread Ivan Korjavin
Guys, you are right. It should work. I made a mistake, the problem was in the surrounding code. I posted it here https://github.com/korjavin/goscan just for educational purpose. The actual problem wasn't scanner.Scan it was `errs <- err` but it took me hours to understand. Sorry, and thank you!

Re: [go-nuts] scanner.Scan is holding my goroutine ;(

2018-12-13 Thread 'Kevin Malachowski' via golang-nuts
Can you post a short, self-contained (compile-able and runnable) example which shows the problem? Preferably hosted on play.golang.org for easy sharing and editing. If the scanner is reading from a reader which has been closed (returns io.EOF), the sc.Scan should return false (and the sc.Err wo

Re: [go-nuts] scanner.Scan is holding my goroutine ;(

2018-12-13 Thread Dan Kortschak
Can you wrap the call to scanner.Scan in a func that has access to the ccn context and returns false when it's closed? On Thu, 2018-12-13 at 14:04 -0800, Ivan Korjavin wrote: > I have a goroutenie with  scanner.Scan > It looks like: > > ``` > cnn.SetReadDeadline(time.Now().Add(c.rTimeout)) // 10s

[go-nuts] [security] Go 1.11.3 and Go 1.10.6 are released

2018-12-13 Thread Dmitri Shuralyov
Hi gophers, We have just released Go 1.11.3 and Go 1.10.6 to address three recently reported security issues. We recommend that all users update to one of these releases (if you’re not sure which, choose Go 1.11.3). - cmd/go: remote command execution during "go get -u" The issue is CVE-2018

[go-nuts] scanner.Scan is holding my goroutine ;(

2018-12-13 Thread Ivan Korjavin
I have a goroutenie with scanner.Scan It looks like: ``` cnn.SetReadDeadline(time.Now().Add(c.rTimeout)) // 10s scanner := bufio.NewScanner(cnn) for scanner.Scan() { ... } ``` cnn is a net.Conn there My problem is when I call cnn.Close() (and I tried cnn.SetReadDeadline(time.Now()) in addition

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread Jeff Kowalczyk
On Thursday, December 13, 2018 at 11:27:40 AM UTC-8, Daniel Theophanes wrote: > > Vendoring will be around a long time. Support for vendoinrg + modules is > getting better with the 1.12 release even. > > If you need to develop offline, that is the way to go. Also, vendoring is > not a footgun.

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread Ian Lance Taylor
On Thu, Dec 13, 2018 at 4:00 AM akshita babel wrote: > > Hey, can anyone guide me on how to take octet stream as input in API and/or > how to convert octet stream to byte array using golang If you want to ask an unrelated question, please send a new message, rather than replying to an existing t

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread Daniel Theophanes
Hi, Vendoring will be around a long time. Support for vendoinrg + modules is getting better with the 1.12 release even. If you need to develop offline, that is the way to go. Also, vendoring is not a footgun. You check in your vendor directory and that ensures all developers and CI tools are o

[go-nuts] Re: Registering a Go app as a protocol handler under Mac OS X

2018-12-13 Thread sateeshandey
Hi Joe, Hope you have achieved what you are trying to. Not sure if some one will go through my post. Since it's more than a year from since this conversation was started. I have a developed an app in JavaFX. The idea is to use it in win and mac. For win created installer using InnoSetup wich al

Re: [go-nuts]

2018-12-13 Thread akshita babel
A RESTful API, with a post call which is taking a file in octet stream form as an input. On Thu, Dec 13, 2018, 6:25 PM roger peppe What kind of API? FWIW, an octet stream is conventionally represented as > an io.Reader in Go, and you can convert to a byte array using > ioutil.ReadAll. > > See htt

Re: [go-nuts]

2018-12-13 Thread roger peppe
What kind of API? FWIW, an octet stream is conventionally represented as an io.Reader in Go, and you can convert to a byte array using ioutil.ReadAll. See https://golang.org/pkg/io#Reader and https://golang.org/pkg/io/ioutil#ReadAll On Thu, 13 Dec 2018 at 12:01, akshita babel wrote: > Hey, can

[go-nuts]

2018-12-13 Thread akshita babel
Hey, can anyone guide me on how to take octet stream as input in API and/or how to convert octet stream to byte array using golang -- 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, s

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread akshita babel
Hey, can anyone guide me on how to take octet stream as input in API and/or how to convert octet stream to byte array using golang On Thu, Dec 13, 2018 at 5:14 PM snmed wrote: > I'm not sure if i fully understand your point on "vetted binaries", but if > every source code is vetted and then tran

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread snmed
I'm not sure if i fully understand your point on "vetted binaries", but if every source code is vetted and then transferred to the isolated environment, there should not be a problem with security issues. All the developer machine living already in the same isolated environment and also i would

Re: [go-nuts] Go offline development recommendations

2018-12-13 Thread Wojciech S. Czarnecki
On Wed, 12 Dec 2018 22:15:23 -0800 (PST) snmed wrote: > Thank you very much for your reply. It seems to be a possible way to do it, > what do you think about the athens way? >From the secop pov it'll be a hells gate. Also it does not allow for vetted binary arifacts as current unix/Go ways do.