Re: [go-nuts] Re: Go += Package Versioning

2018-02-23 Thread Richard Wilkes
Ah… yes, that would probably let me work on it. Didn’t occur to me — thanks for pointing it out. It seems unpleasant to deal with, though, especially since there is a non-zero chance that you then commit your go.mod file with that change inadvertently. I think a local replace will do that.

[go-nuts] Re: yaml 1.1 release

2018-02-23 Thread Dmitri Shuralyov
Just as a heads up, this package (gopkg.in/yaml.v2) is now also affected by issue https://github.com/niemeyer/gopkg/issues/54. It wasn't one of the affected import paths a week ago. On Friday, February 23, 2018 at 2:20:22 PM UTC-5, Roger Peppe wrote: > > Of course I mean 2.1. Version two. TWO

Re: [go-nuts] Re: Go += Package Versioning

2018-02-23 Thread David Anderson
On Fri, Feb 23, 2018 at 3:34 PM, Richard Wilkes wrote: > Overall, I really like the direction vgo is headed. > > One thing that seems to be difficult, if not impossible to do (I've yet to > figure out how to do so, anyway) is to work with code that has yet to be >

[go-nuts] Re: New to Go; Saying Hello !

2018-02-23 Thread bucarr
Another newbie here. Welcome and I feel the same way about Go! -- 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

[go-nuts] Re: Go += Package Versioning

2018-02-23 Thread Richard Wilkes
Overall, I really like the direction vgo is headed. One thing that seems to be difficult, if not impossible to do (I've yet to figure out how to do so, anyway) is to work with code that has yet to be committed and resides outside of your module. This is a frequent occurrence for me, as I often

Re: [go-nuts] Re: Go += Package Versioning

2018-02-23 Thread Aram Hăvărneanu
> Ah… yes, that would probably let me work on it. Didn’t occur to me > — thanks for pointing it out. It seems unpleasant to deal with, > though, especially since there is a non-zero chance that you then > commit your go.mod file with that change inadvertently. See my proposal here:

Re: [go-nuts] Re: Float multiplication bug?

2018-02-23 Thread Michael Jones
This question is already answered, but i was on a plane and added a bit to the printing and the comments. in case anyone ever refers to this thread in the future, this is the better version of the program to run: https://play.golang.org/p/EK0XMnMUKwv On Fri, Feb 23, 2018 at 8:06 AM, Michael Jones

[go-nuts] Re: Go += Package Versioning

2018-02-23 Thread David Collier-Brown
> > Some forms of attempted versioning don't do well with vgo (:-)) > I tried a main named "consumer" that imported "gopkg.in/Shopify/sarama.v1", > and got > ``` > [davecb@miles consumer]$ vgo build > can't load package: import cycle not allowed > package gopkg.in/Shopify/sarama.v1 > imports

Re: [go-nuts] Appreciating Go

2018-02-23 Thread Bakul Shah
On Thu, 22 Feb 2018 12:55:01 + Jesper Louis Andersen wrote: > > For sums, in Go, I have to return a pair, > > x, err := someOperation(..) > > but this is slightly inconsistent, insofar I can return "nil, nil", which > might not be a valid value, or I can

Re: [go-nuts] Appreciating Go

2018-02-23 Thread Ian Lance Taylor
On Fri, Feb 23, 2018 at 5:23 PM, Bakul Shah wrote: > > I once worked out some details of adding sum types to Go and I > think it is quite doable and easy to implement. There is an extensive discussion of sum types in Go over at https://golang.org/issue/19412. Ian -- You

Re: [go-nuts] Appreciating Go

2018-02-23 Thread Bakul Shah
On Fri, 23 Feb 2018 17:39:16 -0800 Ian Lance Taylor wrote: Ian Lance Taylor writes: > On Fri, Feb 23, 2018 at 5:23 PM, Bakul Shah wrote: > > > > I once worked out some details of adding sum types to Go and I > > think it is quite doable and easy to

Re: [go-nuts] New to Go; Saying Hello !

2018-02-23 Thread Daniel Skinner
hi :) On Fri, Feb 23, 2018, 8:26 AM wrote: > So, I started programming in Go about a month ago. I can't stop. > I can't even describe why I am enjoying the language so much, except by > saying... > > It's fun to program in Go! > > I have now embarked on a mission to

Re: [go-nuts] New to Go; Saying Hello !

2018-02-23 Thread 'Axel Wagner' via golang-nuts
o/ We're happy to have you :) On Fri, Feb 23, 2018 at 6:11 PM Daniel Skinner wrote: > hi :) > > On Fri, Feb 23, 2018, 8:26 AM wrote: > >> So, I started programming in Go about a month ago. I can't stop. >> I can't even describe why I am enjoying the

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Henrik Johansson
A sidenote is that there seems to always be issues with using kubernetes client. Is it structured very un Go-ish? Very nice writeup! NB: I was also hit by the casing issue with the same viper dependency. fre 23 feb. 2018 kl 08:28 skrev David Anderson : > I should add: even

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Nic Pottier
Right, any self import needs to change for the vgo case. (but not for the go case unless you force everybody currently using your library to start using semantic versioning paths) -Nic On Fri, Feb 23, 2018 at 10:06 AM, Zellyn Hunter wrote: > On Fri, Feb 23, 2018 at 10:01 AM

Re: [go-nuts] "golang.org/x/net/internal/iana" //use of internal package not allowed

2018-02-23 Thread Ian Lance Taylor
On Fri, Feb 23, 2018 at 2:10 AM, wrote: > > "golang.org/x/net/internal/iana" //use of internal package not allowed > > how to import You can't. It's not allowed. What are you really trying to do? Ian -- You received this message because you are subscribed to the Google

Re: [go-nuts] vgo and enterprise GitHub servers

2018-02-23 Thread Richard Wilkes
Filed https://github.com/golang/go/issues/24076 for this. On Thursday, February 22, 2018 at 5:28:58 PM UTC-8, andrey mirtchovski wrote: > > can you create an issue for this? we're also suffering from the same > internally. please make it about GitHub Enterprise, as that is what > they call it

Re: [go-nuts] All goroutines hung in futex / sleep

2018-02-23 Thread Ian Lance Taylor
On Fri, Feb 23, 2018 at 1:19 AM, Michael Andersen wrote: > > Ok I found the problem. A tight loop was indeed preventing the garbage > collector from proceeding, and then the GC was stopping everything else. The > loop contained atomic.LoadUint64 and

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Jon Calhoun
Not ideal, but you *could* release a new major version where the "breaking" change is the import path change. Eg if you are on v3 now, make a v4 folder and the upgrade to v4 process would involve updating import paths. I wouldn't do this right away since vgo is just a prototype and could change to

[go-nuts] Re: Build started to fail with 1.10

2018-02-23 Thread Vladislav Mitov
Not sure, I'l building in golang:latest https://github.com/miracl/gomiracl/blob/master/Dockerfile#L23. On Friday, February 23, 2018 at 12:26:27 PM UTC+2, Dave Cheney wrote: > > The failing line was added in december last year, > > >

[go-nuts] Re: Build started to fail with 1.10

2018-02-23 Thread Vladislav Mitov
Interesting fact is that if I remove "-std=c99" from CGO_CFLAGS it works locally, fails in Travis though. On Friday, February 23, 2018 at 6:32:29 PM UTC+2, Vladislav Mitov wrote: > > Not sure, I'l building in golang:latest > https://github.com/miracl/gomiracl/blob/master/Dockerfile#L23. > > On

[go-nuts] Re: yaml 1.1 release

2018-02-23 Thread roger peppe
Of course I mean 2.1. Version two. TWO is the version. On 23 February 2018 at 19:17, roger peppe wrote: > I'm happy to announce the release of goyaml 1.1. > > It includes the following improvements: > > - Add Encoder and Decoder types > This allows encoding and decode

[go-nuts] yaml 1.1 release

2018-02-23 Thread roger peppe
I'm happy to announce the release of goyaml 1.1. It includes the following improvements: - Add Encoder and Decoder types This allows encoding and decode multiple YAML documents in a stream. - Alternative timestamp support (e.g. 2015-01-01). Credit to anthonybishopric. - If a value implements

[go-nuts] Re: New to Go; Saying Hello !

2018-02-23 Thread Dmitri Shuralyov
Hello! I can really relate to what you're describing. When I started programming in Go 5 years ago, I felt the same way, and I still do to this day! There are so many moments of joy and bliss that happen when working with it daily. :) Hope you continue to enjoy it too! On Friday, February

[go-nuts] Re: Appreciating Go

2018-02-23 Thread Doğan Kurt
Go is great because it's creators are great. Being smart alone doesn't mean anything. Bjarne Stroustrup is smart. It takes a good taste, a lot of first hand experience and many other things. Simplicity is the main characteristic of Go. Let's see where it comes from; Ken Thompson is a walking

Re: [go-nuts] http.shutdownPollInterval documentation

2018-02-23 Thread Sridhar
Thanks. I was fairly certain that's what it meant. Wasting more time, the pedant in me argues - but "Left as an exercise for the reader" generally implies it's a solved problem and the reader is to take time to re-solve to hone their skills. On Friday, 23 February 2018 00:50:24 UTC,

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Nicolas Grilly
On Fri, Feb 23, 2018 at 8:20 AM, David Anderson wrote: > The date+hash format is irritating to construct by hand, but could be > trivially lifted into a tool (perhaps even vgo itself). > Very true. I suffered from the same issue while trying vgo. This could be improved to ease

[go-nuts] Re: Build started to fail with 1.10

2018-02-23 Thread Владислав Митов
Nah, it's not that - https://travis-ci.org/miracl/gomiracl/jobs/345158452. If fails also in golang:latest where the yaml gotcha it's not a thing. Solid suggestion though, thanks. On Friday, February 23, 2018 at 11:02:59 AM UTC+2, Владислав Митов wrote: > > Ah, I read about that but ti says `go

Re: [go-nuts] All goroutines hung in futex / sleep

2018-02-23 Thread Michael Andersen
Ok I found the problem. A tight loop was indeed preventing the garbage collector from proceeding, and then the GC was stopping everything else. The loop contained atomic.LoadUint64 and atomic.CompareAndSwapUint64, but neither of those seem to qualify as preemption points. Fixing that loop fixes

[go-nuts] Re: Build started to fail with 1.10

2018-02-23 Thread Владислав Митов
Ah, I read about that but ti says `go version go1.10 linux/amd64`. I'll try putting it in quotes now. On Friday, February 23, 2018 at 1:57:53 AM UTC+2, Nic Pottier wrote: > > This is almost certainly because your .travis file is specifying your > version as `1.10` vs `"1.10"` > > So your build

[go-nuts] vgo with package path without dot

2018-02-23 Thread wilk
Hi, I work with GOPATH per project. Then I use to give them a one word path directly under src: $GOPATH/src/myapp But I found that it doesn't work with vgo. It looks at /usr/local/go/src/ instead of my GOPATH. The same when i use replace with a clone of a libs. If there is a dot in the

[go-nuts] Re: Build started to fail with 1.10

2018-02-23 Thread Dave Cheney
The failing line was added in december last year, https://github.com/golang/go/commit/7cba779cea5#diff-56c7df71bce32f8e50115128ae30941eR13 This also adds a dependency on time.h. Is time.h available in your build container? On Friday, 23 February 2018 20:09:02 UTC+11, Владислав Митов wrote: > >

[go-nuts] Re: Float multiplication bug?

2018-02-23 Thread steve_bagwell
Thanks guys. That's very helpful. I forgot that what I saw (and re-used) as the "height" was not precise enough to make it comparable. On Thursday, February 22, 2018 at 3:33:38 PM UTC-5, Steve Bagwell wrote: > > > Hello Everyone, > > This looks like a Golang bug to me. What do you all think?

Re: [go-nuts] Re: Float multiplication bug?

2018-02-23 Thread Michael Jones
One subtle thing is the difference between an ideal number, its floating-point representation, and its printed form. On Fri, Feb 23, 2018 at 5:46 AM, wrote: > Thanks guys. That's very helpful. I forgot that what I saw (and re-used) > as the "height" was not precise

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Nic Pottier
Thanks for the great write up Dave, you've inspired me to "try harder" to use it on a few of my projects after running into similar issues. As you noted, my remaining big question mark is how existing libraries that are above v1 transition to a vgo style while remaining backwards compatible

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread roger peppe
On 23 February 2018 at 12:31, Nic Pottier wrote: > Thanks for the great write up Dave, you've inspired me to "try harder" to > use it on a few of my projects after running into similar issues. > > As you noted, my remaining big question mark is how existing libraries that >

[go-nuts] "golang.org/x/net/internal/iana" //use of internal package not allowed

2018-02-23 Thread sdlaovip
"golang.org/x/net/internal/iana" //use of internal package not allowed how to import -- 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

[go-nuts] New to Go; Saying Hello !

2018-02-23 Thread fractalbach
So, I started programming in Go about a month ago. I can't stop. I can't even describe why I am enjoying the language so much, except by saying... It's fun to program in Go! I have now embarked on a mission to create an online game, using Go for the server. I thought I should stop by here and

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Zellyn
Fantastic post. One small answer below: On Friday, February 23, 2018 at 2:22:32 AM UTC-5, David Anderson wrote: > > The version to use in that replacement was hard to come by. Since vgo was > unable to compute the right dependency list without this replacement, it > bailed without giving me any

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Nic Pottier
On Fri, Feb 23, 2018 at 7:59 AM, roger peppe wrote: > As Russ pointed out to me, you can work around that by using a > 0.0.0-2101234543-4f34f456eeefdcba version in your go.mod require > section. If you've got that, it ignores the version tags. Right, that works for

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread roger peppe
On 23 February 2018 at 15:00, Nic Pottier wrote: > On Fri, Feb 23, 2018 at 7:59 AM, roger peppe wrote: >> As Russ pointed out to me, you can work around that by using a >> 0.0.0-2101234543-4f34f456eeefdcba version in your go.mod require >> section.

Re: [go-nuts] Go += Package Versioning

2018-02-23 Thread Zellyn Hunter
On Fri, Feb 23, 2018 at 10:01 AM Nic Pottier wrote: > Right, that works for clients of the library (and I did manage to get > my projects working with that and it now feels magical) but authors of > modules above v1 are posed with a bit of a quandary as to how to give >