#go-nuts

/

      • kitak has quit
      • soylentbomb has quit
      • kitak joined the channel
      • timonv joined the channel
      • timonv has quit
      • mh` has quit
      • mh` joined the channel
      • mzdravkov
        It really bugs me how it's 2 o'clock and it's 2014 here, and somewhere else it's still 2013
      • driti joined the channel
      • this looks so wrong. Really bad design, imho
      • zz_mboersma is now known as mboersma
      • driti has quit
      • darkgray
        I hear it'll be patched by tomorrow.
      • bmats has quit
      • smw has quit
      • calavera has quit
      • mneorr joined the channel
      • cubahero joined the channel
      • collinvandyck is now known as collin|rip
      • alexvr
        you're from the future!
      • neurodrone joined the channel
      • tomboy64 has quit
      • waynr joined the channel
      • waynr
        howdy folks
      • kernal joined the channel
      • chimeracoder
        mzdravkov: you should tell the admins
      • mzdravkov: though from what I hear over at /r/outside, they rarely respond directly to bug reports :(
      • juztinw joined the channel
      • andrewpthorp joined the channel
      • calavera joined the channel
      • cubahero has quit
      • timonv joined the channel
      • cubahero joined the channel
      • velco has quit
      • shodan45 has quit
      • r04r|away is now known as r04r
      • shodan45 joined the channel
      • shodan45 has quit
      • adiabatic
        mzdravkov: quit whining, all of us in GMT-7 are only in the future compared to the Alaskans and Hawaiians
      • and even then it's only for a couple hours
      • calavera has quit
      • Wessie
        Not our fault you settled in there
      • FunnyLookinHat has quit
      • jhawk28 has quit
      • adiabatic
        on the other hand, we have a daytime high of 22˚C (73˚F) in the dead of winter, so I suppose it's worth it
      • shodan45 joined the channel
      • dominikh
        °, not ˚ :P
      • adiabatic
        22º?
      • chimeracoder
        adiabatic: where are you?
      • juztin_ has quit
      • zombor has quit
      • adiabatic
        22°?
      • dominikh
        that one
      • adiabatic
        chimeracoder: southern california
      • dominikh
        unless you tricked my bad eyes :P
      • juztinw has quit
      • vince_prignano joined the channel
      • chimeracoder
        dominikh: you are correct
      • adiabatic
        dominikh: pity cmd-k is easier than cmd-*
      • chimeracoder
        dominikh: I'm impressed that you could tell the difference, though
      • dominikh
        hah
      • chimeracoder
        adiabatic: aren't you in GMT-8, then?
      • adiabatic
        What's ˚, then?
      • chimeracoder
      • dominikh
        adiabatic: pff. I need to press alt_gr + shift + ;
      • adiabatic
        chimeracoder: we swap back and forth. I'm not sure whether -7 is summertime or wintertime
      • dsantiag_ joined the channel
      • dominikh: on the other hand, you get a real meta key for your emacs
      • dominikh
        true
      • nanoyak has quit
      • dsantiago has quit
      • pengux has quit
      • adiabatic
        chimeracoder: thanks
      • mneorr joined the channel
      • hah
      • andrewpthorp
        Are there any resources for project structure? It seems having a bunch of *.go and *_test.go files in the root directory is silly, but I'm wondering what the best approach is
      • dominikh
        what's silly about that?
      • adiabatic
        Is it getting cluttered?
      • andrewpthorp
        Cluttered as it grows
      • chimeracoder
        andrewpthorp: should your project actually be split into separate packages?
      • dominikh
        ls $(go env GOROOT)/src/pkg/net – we don't mind.
      • andrewpthorp
        Not packages, I'm just talking about dir structure
      • joshnz joined the channel
      • timonv has quit
      • dominikh
        dir structure == packages. one package per directory, one directory per package
      • andrewpthorp
        I thought I had seen some projects with test/*_test.go and app/*.go
      • perhaps I am mistaken
      • dominikh
        if you want your tests to be in a different package, sure, you can do that. no whitebox testing then, though
      • it's not idiomatic though
      • andrewpthorp
        Yeah, I don't necessarily want that
      • dominikh
        c.f. ls $(go env GOROOT)/src/pkg/net – there's nothing wrong with that
      • andrewpthorp
        So the general accepted rule is to have all of the source and tests in the root directory?
      • dominikh
        s/root directory/package directory – but yes.
      • nanoyak joined the channel
      • andrewpthorp
        right yeah, sorry, that's what I mean
      • wlll_ has quit
      • Thanks for the guidance
      • mneorr has quit
      • dominikh
        no problem
      • andrewpthorp
        Any recommend projects to read through for sample code>
      • tombell has quit
      • wlll joined the channel
      • cgt
        andrewpthorp: stdlib
      • dominikh
        I recommend reading the standard library. that's a lot of small "projects"
      • tombell joined the channel
      • hajimeho_ joined the channel
      • croaky has quit
      • new_one joined the channel
      • kei has quit
      • andrewpthorp
        Where is the stdlib code at?
      • mischief
        in the source distribution
      • dominikh
        cd $(go env GOROOT)/src/pkg
      • brianm_ joined the channel
      • jackneill has quit
      • zozoR has quit
      • andrewpthorp
        Yeah, I was hoping to be able to scan it on code.google.com or github.com
      • pengux has quit
      • dominikh
        how's that better than having it on your local disk? :)
      • andrewpthorp
        IT's not! :)
      • vince_prignano
        On high load, go web server returns 500 error, loading a template that do exists. Anyone knows if this is a bug or what/
      • ?
      • hajimeho_ has quit
      • dominikh
        https://code.google.com/p/go/source/browse/#hg%... if you're so keen on a terrible interface :P
      • andrewpthorp
        But I can read it on my phone without bringing my laptop out
      • When flying tomorrow :)
      • dominikh
        wouldn't enjoy reading that on a phone though, but yea
      • there it is
      • pengux joined the channel
      • andrewpthorp
        Thanks a bunch
      • chimeracoder
        vince_prignano: kind of hard to answer without any context
      • brianm_ has quit
      • a nonexistant template is not the only thing that could cause a 500 error
      • brianm_ joined the channel
      • dominikh
        if you're really parsing the template on every request (which sounds silly), you might simply be running out of file handles
      • vince_prignano
        chimeracoder: Yeah sorry, I am trying to serve a simple html page using martini framework.
      • knivey has quit
      • dominikh: I am really new to the language :), there is any way to cache a template?
      • james4k
        closing your files?
      • dominikh
        parse it once, store it somewhere
      • brianm_ has quit
      • neurodrone has quit
      • calavera joined the channel
      • vince_prignano
        dominikh: ok, thanks nice hint :)
      • brianm_ joined the channel
      • brianm_ has quit
      • AndroidVaan joined the channel
      • james4k: yes the file is being closed I suppose, I will look into martini
      • SpNg
        I have apiece of JSON data that could come in either as an array of strings or floats. What is the best way to handle this? an interface{} with reflection and type assertion?
      • dominikh
        1) hit the guy who produces the json 2) do the strings contain numbers or string data? 3) if strings, yeah interface{}. if numbers as strings, there's a struct tag for that I believe
      • luke_s has left the channel