akaiiro has quit [Read error: Connection reset by peer]
bds has quit [Ping timeout: 252 seconds]
akaiiro7 has quit [Ping timeout: 246 seconds]
DTZUZO has quit [Ping timeout: 240 seconds]
DTZUZO has joined #crystal-lang
<FromGitter>
<girng> i'm going to just use puts and gets instead of read_bytes and see if the delay is there
zorp_ has quit [Ping timeout: 272 seconds]
<FromGitter>
<girng> ok just tested it with puts and gets, same exact thing. hmm i wonder what could be causing this
baweaver is now known as baweaver_away
Vexatos has quit [Ping timeout: 252 seconds]
RX14 has joined #crystal-lang
DTZUZO has quit [Ping timeout: 240 seconds]
<FromGitter>
<ninetailschris> https://carc.in/#/r/4v86 Any reason why I can access the nested array?
<FromGitter>
<newtonapple> @ninetailschris u have to use `a[0][1].as(Array)[0]`
<FromGitter>
<newtonapple> that's how i read it anyway.
Raimondii has joined #crystal-lang
Raimondi has quit [Ping timeout: 240 seconds]
Raimondii is now known as Raimondi
ashirase has quit [Ping timeout: 260 seconds]
ashirase has joined #crystal-lang
DTZUZO has joined #crystal-lang
zorp_ has joined #crystal-lang
<FromGitter>
<codenoid> :( it's too hard, to find crystaller in southeast asia
<FromGitter>
<j8r> You can enventually find Rubyists to convert @codenoid 😁
<FromGitter>
<codenoid> it's hard to find available and skilled Rubyists too :(
<FromGitter>
<asterite> codenoid where are you from?
<FromGitter>
<codenoid> @asterite indonesia
<FromGitter>
<j8r> @codenoid what the most common dev skills around?
<FromGitter>
<codenoid> PHP
<FromGitter>
<j8r> meh... other topic, I've found a way to follow redirections :D `HTTP::Client.follow("http://redd.it").get` . I'll send a PR
<FromGitter>
<j8r> I don't know what specs I can add to test redirections
<FromGitter>
<j8r> My implementation may not be really clean, but nice on the API side. We'll see on the PR
Yxhuvud has quit [Remote host closed the connection]
return0e has quit [Ping timeout: 244 seconds]
return0e has joined #crystal-lang
ua_ has quit [Ping timeout: 240 seconds]
sagax has quit [Read error: Connection reset by peer]
Yxhuvud has joined #crystal-lang
bds has joined #crystal-lang
<FromGitter>
<asterite> j8r: following redirects is very easy. The problem is how to design it in a flexible way (you don't always want to follow redirects automatically, I think). I don't think a PR will be accepted just as is without a previous discussion (which exists: #6011)
<FromGitter>
<Sija> but for simple retry it might be an overkill
bds has quit [Ping timeout: 250 seconds]
Raimondii has joined #crystal-lang
Raimondi has quit [Ping timeout: 240 seconds]
Raimondii is now known as Raimondi
<FromGitter>
<girng> is tcp's nagle aglorithm supposed to be disabled on the server or the socket??
<FromGitter>
<girng> because it's in the docs for tcpsocket, and for TCPServer and not sure. hell, i'll just do it on both to make sure
DTZUZO has joined #crystal-lang
<FromGitter>
<girng> ok. @opyrpin i disabled nagles algorithm on both client and server. and getting response times of 60-71ms average through TCP ping, and the ICMP ping to that server is 43-55MS
<FromGitter>
<girng> way better than before, right? seems normal range?
<FromGitter>
<Blacksmoke16> @Sija neat, might have to look into that, thanks
return0xe has joined #crystal-lang
return0e has quit [Ping timeout: 240 seconds]
<FromGitter>
<girng> wait WTF. nagle algorithm can be enabled by the client?
<FromGitter>
<girng> that's such crap. i don't want clients to be able to change the way my server communicates
<dom96>
Maybe you should just use UDP?
<FromGitter>
<girng> i guess it's their fault if they enable nagle, they'll get higher response times (just tested it). so whatever rofl. i'm going to have it disabled with my game by default. if people want to hack they'll just get worse response times idc.
<FromGitter>
<girng> @dom96 ya. im going to use udp for player movement data i think
akaiiro7 has quit [Remote host closed the connection]
<FromGitter>
<j8r> Dumb question what's the difference between `self.new` and `initialize`? `self.new` avoid allocations?
<oprypin>
j8r, `def self.new(stuff); result = self.allocate(); result.initialize(stuff); return result`
<oprypin>
(except u cant actually call initialize but the language does it)
<FromGitter>
<j8r> so its better to have one initialize, that `self.new` can call, instead of having several initializes overloads calling the "main" initialize
<FromGitter>
<Sija> usually you'd specify one `initialize` and several `self.new` overloads (if needed)
commavir has quit [Quit: leaving]
commavir has joined #crystal-lang
<oprypin>
j8r, they usually serve a different purpose. the important thing to note is that `initialize` cannot call any other method, which significantly hampers code reuse. that's why you sometimes have to rely on `self.new`. but other than that, yes, just `def initialize`.