[go-nuts] Invalid Segment Alignment when pushing to iTunesConnect

2017-10-21 Thread pruest
I'm getting the following error when trying to publish a go app to the itunes connect app store. ERROR ITMS-90209: "Invalid Segment Alignment. The app binary at 'bios.app/bios' does not have proper segment alignment. Try rebuilding the app with the latest Xcode version." Please: Can anyone

[go-nuts] go.crypto/ssh - ssh.NewServerConn Unexpected Output

2017-10-21 Thread liuzheng712
When I use telnet to test, ctrl-D and Enter will comes those thing, I'm looking the code. Escape character is '^]'. SSH-2.0-Go ^D

Re: [go-nuts] Easiest way to work with database

2017-10-21 Thread Rodolfo
Vickey, you can work with timestamps, to me is the easiest way to work with time data in any language and framework, because always an Int value :D Good Luck! 2017-10-21 21:35 GMT-04:00 : > HiShawn, > > I just want to know say i have a test table in postgres. With 2

Re: [go-nuts] Easiest way to work with database

2017-10-21 Thread vickey . coool
HiShawn, I just want to know say i have a test table in postgres. With 2 column one date and another string.i want to create an HTML table which can be updated and deleted by a click. Like Time| string X:xx| xyz update delete X:xx| xyz update delete X:xx| xyz update delete X:xx|

[go-nuts] Re: Gremlin go client...

2017-10-21 Thread Mandolyte
I have used the qasaur package, but it has been a while. At the time, I filed an issue to bring it up to date to the then current version of gremlin. The package is pretty small and the interactions with the gremlin server are pretty simple. It worked ok for the simple things I was doing at

Re: [go-nuts] How to run (individual) tests and benchs of the stdlib?

2017-10-21 Thread Leon Klingele
Hi Dave, > you must use the source that matches the version of Go thanks for clarifying. Finally I am able to run the latest benchs :) -- 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

Re: [go-nuts] How to run (individual) tests and benchs of the stdlib?

2017-10-21 Thread Dave Cheney
The key here is to understand that the go tool works with import paths, not files or directories. This statement isn't absolutely true as there are many inconsistencies that water down this statement, but if you're ever stuck about how to do something with the Go tool, think about "how do I

Re: [go-nuts] How to run (individual) tests and benchs of the stdlib?

2017-10-21 Thread Dave Cheney
Hi, I think you've got a bit confused here. If you want to run the tests of a package in the standard library; you must use the source that matches the version of Go you have installed; that is the version in $(go env GOROOT). Try this command go test -bench=. crypto/tls On Sunday, 22

Re: [go-nuts] How to run (individual) tests and benchs of the stdlib?

2017-10-21 Thread google
So how _do_ I run the crypto/tls benchmarks of github.com/golang/go? $ cd $GOPATH/src/github.com/golang/go/src/crypto/tls $ git rev-parse HEAD 5f740d6875ab6961381f2f4614b21ff6ddf448a4 $ go test -bench=. common.go:10:2: use of internal package not allowed -- You received this message because you

[go-nuts] Re: will the following code always print two 1?

2017-10-21 Thread Dave Cheney
no to your first example, yes to the second. On Sunday, 22 October 2017 08:01:08 UTC+11, T L wrote: > > package main > > import "fmt" > import "sync" > import "sync/atomic" > > func main() { > var a, b int32 = 0, 0 > > go func() { > a = 1 > atomic.AddInt32(, 1) >

Re: [go-nuts] will the following code always print two 1?

2017-10-21 Thread Jan Mercl
On Sat, Oct 21, 2017 at 11:01 PM T L wrote: > fmt.Println(a) // always print 1? Possibly. But the statement may never execute. > //== > fmt.Println(x) // always print 1? Same answer. -- -j -- You received this message because you are subscribed

[go-nuts] Re: Should you check error from ResponseWriter.Write()?

2017-10-21 Thread Tamás Gulácsi
If you have to account the downloads made by the client, you would check those errors and don't increment the download times if that write returned error. But this is a very contrived example, I don't know any such case in real life. -- You received this message because you are subscribed to

[go-nuts] will the following code always print two 1?

2017-10-21 Thread T L
package main import "fmt" import "sync" import "sync/atomic" func main() { var a, b int32 = 0, 0 go func() { a = 1 atomic.AddInt32(, 1) }() for { if n := atomic.LoadInt32(); n == 1 { fmt.Println(a) // always print 1? break

[go-nuts] Re: sync.Map performance problem

2017-10-21 Thread Val
Hi Barce For the CPU going wild, it would be best to share the code (if you can't share the whole project, then a relevant part of it that is runnable and exhibits the perf problem). There are many possible problems that could cause this, it is not self-evident that the use of sync.Map is the

[go-nuts] Re: Should you check error from ResponseWriter.Write()?

2017-10-21 Thread groenendaal92
Could you give an example situation where you *would* be able to do something about that error? And again, when might Write() return an error at all? Even if I couldn't do anything to fix the situation for the client receiving that Write() I could log the error just so I know it happened and

[go-nuts] Should you check error from ResponseWriter.Write()?

2017-10-21 Thread Tamás Gulácsi
You should, if you can do anything about that error. But usually, you can't. -- 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] Should you check error from ResponseWriter.Write()?

2017-10-21 Thread groenendaal92
Should you check the error returned from calling http.ResponseWriter.Write()? I ask because in all the examples I've seen this error is not checked. If it is okay to ignore that error then why? What kind of errors would be returned from Write()? Thanks, Lucas -- You received this message

Re: [go-nuts] Easiest way to work with database

2017-10-21 Thread Shawn Milochik
http://jmoiron.github.io/sqlx/ This is a really great reference. It is for another library, but the beginning of the tutorial is the most useful documentation I've seen for the standard library. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group.

[go-nuts] Gremlin go client...

2017-10-21 Thread forfader
I need gremlin client to access JanusGraph graph database from Go. I'll be using the JanusGraphServer configuration. I'm always amazed at the broad range of open source go libraries. This is the first time that I've come up wanting, when looking for a go open source library. I found the

[go-nuts] Easiest way to work with database

2017-10-21 Thread vickey . coool
I work a lot with databases and i have recently started learning golang. Is three hardest language when comes to database. And there are no good places to find information. I am not able to work with databases even after searching and reading documentation and blog. I create typos and

[go-nuts] Mermaid parser

2017-10-21 Thread Ged Wed
Mermaid is a markdown format for expressing workflow diagrams like sequence diagram etc. You can then render it as svg. Is there anything similar written in golang ? I want to use it for documentation but also for allowing users to visualise and edit workflows running on top of nats. It's

Re: [go-nuts] How to run (individual) tests and benchs of the stdlib?

2017-10-21 Thread helloPiers
You've missed the regexp argument to -bench; try just a . to match all benchmarks. (In fact go test will be interpreting crypto/tls/... as the regular expression, and with no further parameter is trying to test what's in the current directory.) -bench regexp Run only those benchmarks

[go-nuts] sync.Map performance problem

2017-10-21 Thread barce show
I use sync.Map in my program to support access concurrently, but witin two hours with less than 50 clients, my program run out all of my cpu, so I go back to read the pkg document, and I find this sentence "For use cases that do not share these attributes, it will likely have comparable or

[go-nuts] sync.Map performance problem

2017-10-21 Thread barce show
how to understand this sentence For use cases that do not share these attributes, it will likely have comparable or worse performance and worse type safety than an ordinary map paired with a read-write mutex. -- You received this message because you are subscribed to the Google Groups

Re: [go-nuts] How to run (individual) tests and benchs of the stdlib?

2017-10-21 Thread Leon Klingele
`go test crypto/tls/...` indeed works fine (from $HOME), but I want to run benchmarks as well, which fails: ``` $ pwd /home/leon $ go test -bench crypto/tls/... can't load package: package .: no Go files in /home/leon ``` ``` $ go env | grep "GO\(PATH\|ROOT\).*" GOPATH="/home/leon/dev/go"

[go-nuts] Re: slice of pointer of struct vs slice of struct

2017-10-21 Thread Juliusz Chroboczek
> I have started to use non pointer slices much more as of late. > Every time I bother measuring it is always faster and it is better for the > GC (usually, caveats apply). So do I. I was just pointing out a caveat that tripped me a couple times. > It also, perhaps naively, feels safer... :)

[go-nuts] interface conversion fails: backends.Client is *mock.client, not *mock.client

2017-10-21 Thread google
I've been trying to debug a really strange issue and stuck believing it being a bug in the Go compiler toolchain. interface conversion: backends.Client is *mock.client, not *mock.client Steps to reproduce: $ cd $(mktemp -d) $ git clone https://github.com/leonklingele/pick -b