nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tvw has quit []
Devalo has joined #ruby
tdy1 has quit [Ping timeout: 248 seconds]
tvw has joined #ruby
tvw has quit [Client Quit]
Devalo has quit [Ping timeout: 256 seconds]
JeanCarloMachado has joined #ruby
tdump has joined #ruby
bturker has joined #ruby
<tdump>
quick question. I want to get a slice of a string from a certain index back to the beginning. In python I could enter a negative step. How would I accomplish this in ruby?
dnicole has joined #ruby
<tdump>
oh you know what I may have just figured something out
rwb has joined #ruby
tdy has joined #ruby
yeticry has quit [Ping timeout: 258 seconds]
raul782 has joined #ruby
djbkd has quit [Remote host closed the connection]
<tdump>
just typing my question in jogged something in my head. I came up with an adequate solution for the problem I was trying to solve. Thanks!
shashin has joined #ruby
tdump has quit [Quit: Leaving...]
yeticry has joined #ruby
djbkd has joined #ruby
bturker has quit [Ping timeout: 256 seconds]
ResidentBiscuit has joined #ruby
dnicole has quit [Ping timeout: 240 seconds]
nankyokusei has joined #ruby
djbkd has quit [Ping timeout: 260 seconds]
MrBusiness2 has joined #ruby
ResidentBiscuit has quit [Ping timeout: 258 seconds]
<b0nn>
.reverse
rfoust has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jenrzzz has quit [Ping timeout: 260 seconds]
Ebok has joined #ruby
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
nemermel has joined #ruby
nankyokusei has quit [Ping timeout: 258 seconds]
nemermel has quit [Client Quit]
_whitelogger has joined #ruby
Azure has quit [Remote host closed the connection]
weaksauce has joined #ruby
Azure has joined #ruby
tfitts has quit [Quit: Connection closed for inactivity]
byte512 has quit [Ping timeout: 246 seconds]
Jonah11_ has joined #ruby
maloik has quit [Remote host closed the connection]
maloik has joined #ruby
Jonah11_ has quit [Client Quit]
DLSteve has joined #ruby
pragmaticus has quit [Ping timeout: 256 seconds]
cpg has joined #ruby
jordanm has quit [Quit: Konversation terminated!]
dmtd has joined #ruby
ResidentBiscuit has joined #ruby
johnmccabe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jcao219 has quit [Ping timeout: 244 seconds]
Devalo has joined #ruby
<cpg>
hi, i started to have some trouble compiling 2.3.0 and 2.3.3 on mac os x (I suspect after upgrading xcode?)
ResidentBiscuit has quit [Ping timeout: 258 seconds]
chouhoul_ has joined #ruby
whathappens has quit [Quit: Leaving...]
<cpg>
the command is rbenv install 2.3.0
<cpg>
and it has been working for years (at least two)
<cpg>
on various versions of ruby
shashin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
raul782_ has joined #ruby
<cpg>
i cannot seem to fund a viable solution online other than re-tar the library or something
Devalo has quit [Ping timeout: 246 seconds]
<cpg>
i tried upgrading homebrew
<cpg>
uninstalling rbenv
chouhoulis has quit [Ping timeout: 260 seconds]
raul782 has quit [Ping timeout: 265 seconds]
patarr has quit [Ping timeout: 268 seconds]
jphase has quit [Remote host closed the connection]
chouhoul_ has quit [Ping timeout: 256 seconds]
jphase has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
BTRE has quit [Quit: Leaving]
BTRE has joined #ruby
ferr1 has quit [Read error: Connection reset by peer]
jphase has quit [Ping timeout: 260 seconds]
marxarelli has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
roshanavand has quit [Ping timeout: 240 seconds]
djbkd has joined #ruby
hahuang65 has joined #ruby
nowhereman has quit [Ping timeout: 244 seconds]
railssmith has quit [Ping timeout: 245 seconds]
SeepingN has quit [Quit: The system is going down for reboot NOW!]
marr has quit [Ping timeout: 250 seconds]
splud has quit [Quit: splud]
jaguarmagenta has joined #ruby
jenrzzz has joined #ruby
yeticry has quit [Ping timeout: 260 seconds]
cpg has left #ruby [#ruby]
yeticry has joined #ruby
nettoweb has joined #ruby
Vile` has joined #ruby
jaguarmagenta has quit [Ping timeout: 250 seconds]
arescorpio has joined #ruby
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
madsa_ has joined #ruby
mrwn has joined #ruby
ascarter has joined #ruby
mrwn has quit [Remote host closed the connection]
djbkd has quit [Ping timeout: 260 seconds]
postmodern has joined #ruby
mrwn has joined #ruby
CloCkWeRX has joined #ruby
jgnagy has joined #ruby
jphase has joined #ruby
madsa_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
[ohjn] has joined #ruby
[ohjn] has left #ruby [#ruby]
mrwn has quit [Remote host closed the connection]
jgnagy has quit [Ping timeout: 245 seconds]
<b0nn>
is this normally such a slow channel?
<havenwood>
b0nn: Friday night tends to be slow.
<b0nn>
oh, it's Friday
<baweaver>
havenwood: bonus points that there's someone named Friday on channel apparently
<b0nn>
It's a stinking hot Saturday afternoon here
jphase has quit [Ping timeout: 258 seconds]
<baweaver>
Not sure why I find that so amusing
Ebok has quit [Quit: This computer has gone to sleep]
<baweaver>
Speaking of Friday though, time for me to be off and doing things.
jphase has joined #ruby
pilne has quit [Remote host closed the connection]
sepp2k has quit [Read error: Connection reset by peer]
Immune has quit [Ping timeout: 250 seconds]
charliesome has joined #ruby
ascarter has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nankyokusei has joined #ruby
Dimik has joined #ruby
antoniobeyah has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
bturker has joined #ruby
enterprisey has joined #ruby
Puffball has quit [Remote host closed the connection]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sylario has quit [Quit: Connection closed for inactivity]
dnicole has joined #ruby
jphase has quit [Read error: Connection reset by peer]
Puffball has joined #ruby
bturker has quit [Ping timeout: 256 seconds]
jeffaustin81 has joined #ruby
kbdkode has quit [Quit: * ~ see ya ~ *]
jphase has joined #ruby
dnicole has quit [Ping timeout: 245 seconds]
madsa_ has joined #ruby
d^sh has quit [Ping timeout: 246 seconds]
bturker has joined #ruby
d^sh has joined #ruby
enterprisey has quit [Ping timeout: 260 seconds]
solocshaw has joined #ruby
<blackbombay>
b0nn: austrailia i guess?
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bturker has quit [Ping timeout: 256 seconds]
harai_ has quit [Ping timeout: 246 seconds]
<hays__>
style question. one of the few places i find myself using parens is when i am passing the result of a function call in a hash. is there a way to avoid using parens in this case?
solocshaw has quit [Ping timeout: 256 seconds]
jenrzzz has quit [Ping timeout: 256 seconds]
Jayson_Virissimo has joined #ruby
<blackbombay>
hays__: example?
<hays__>
foo "foo!", bar: baz(bop)
JoshS has joined #ruby
SCHAAP137 has quit [Quit: Leaving]
gnufied has quit [Quit: Leaving]
Vile` has quit [Ping timeout: 246 seconds]
nettoweb has joined #ruby
<blackbombay>
you should use parenthesis in scenarios like that, or the syntax will be ambigious. in fact even if you have" method_1_call method_2_call(123)" you should use parenthesis.
nettoweb has quit [Client Quit]
<havenwood>
or do it Seattle-style and omit parens unless it breaks the interpreter
<hays__>
however the above case seems to absolutely require parens
<hays__>
unless you do it outside the hash
<hays__>
bang = baz bop ; foo "foo!", bar: bang
<b0nn>
blackbombay: .nz
<blackbombay>
cool
<hays__>
but idiomatically it seems like the parens are justified in this case
<blackbombay>
i'm not a fan of the seattlerb style but so much time is wasted on style arguments that i prefer to avoid them. they matter much less than good logic and program design.
<hays__>
yeah i don't really care to argue--i totally respect/understand someone might prefer another way
<hays__>
was just curious what people thought about this case
<blackbombay>
in my personal opinion parenthesis in examples like yours, or in examples like the one i showed above, it makes it clearer at a glance which methods receive what arguments.
raul782_ has quit [Remote host closed the connection]
Sammichmaker has quit [Read error: Connection reset by peer]
<hays__>
blackbombay: so that article would argue that the benefit of seattlerb is not that you try to be overly clever, but that avoiding parens has more heuristic value when your lines of code are becoming too long/overly complex.
<hays__>
but yeah, I think the parens win out in this case too
<hays__>
because its better than separating it out as well. the parens actually are helping
JeanCarloMachado has quit [Ping timeout: 265 seconds]
nettoweb has joined #ruby
<b0nn>
right, I think this is my last question in this regard
jeffaustin81 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<b0nn>
how do I make it work for twitter's streaming APIs
<blackbombay>
hays__: true, never thought about that, but i try to avoid lines like: puts one(two(123) automatically.
<hays__>
yeh, its bad either way
railssmith has joined #ruby
<blackbombay>
forgot a paren there :)
<hays__>
lol
jeffaustin81 has joined #ruby
<hays__>
although.. one(two 123) is ... almost readable
<hightower2>
Hey, Is there a way to "stow" modules/classes I define through a 'require' into a hierarchy? In other words, if I have "module X; require 'y'; end", and if 'y.rb' has content "module Y; end", is there a way for this to actually result in X::Y rather than X and Y?
jeffaustin81 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ascarter has joined #ruby
govg has joined #ruby
jeffaustin81 has joined #ruby
jaguarmagenta has joined #ruby
Channel6 has joined #ruby
solocshaw has joined #ruby
jaguarmagenta has quit [Ping timeout: 268 seconds]
domgetter has joined #ruby
solocshaw has quit [Ping timeout: 256 seconds]
truenito has joined #ruby
raul782 has joined #ruby
zukin has joined #ruby
dmtd has quit [Quit: Connection closed for inactivity]
Jayson_Virissimo has quit []
nankyokusei has joined #ruby
Ebok has joined #ruby
blackbombay has quit [Read error: Connection reset by peer]
raul782 has quit [Read error: Connection reset by peer]
jgnagy has joined #ruby
zotherstupidguy has quit [Ping timeout: 240 seconds]
blackbombay has joined #ruby
DLSteve has quit [Quit: All rise, the honorable DLSteve has left the channel.]
nankyokusei has quit [Ping timeout: 268 seconds]
jgnagy has quit [Ping timeout: 258 seconds]
hanmac has quit [Ping timeout: 260 seconds]
warrshrike has left #ruby [#ruby]
govg has quit [Ping timeout: 260 seconds]
Immune has joined #ruby
dnicole has joined #ruby
ResidentBiscuit has joined #ruby
madsa_ has joined #ruby
plujon has quit [Quit: ERC (IRC client for Emacs 25.1.1)]
nettoweb has joined #ruby
tau has quit [Remote host closed the connection]
ResidentBiscuit has quit [Ping timeout: 258 seconds]
hanmac has joined #ruby
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zukin has quit [Ping timeout: 268 seconds]
gix has quit [Ping timeout: 260 seconds]
gix has joined #ruby
blackwind_123 has quit [Ping timeout: 246 seconds]
blackwind_123 has joined #ruby
dnicole has quit [Remote host closed the connection]
faces has quit [Ping timeout: 244 seconds]
Rodya_ has joined #ruby
Channel6 has quit [Quit: Leaving]
nadir has quit [Quit: Connection closed for inactivity]
Ebok has quit [Quit: This computer has gone to sleep]
bturker has joined #ruby
zotherstupidguy has joined #ruby
Rodya_ has quit [Remote host closed the connection]
bturker has quit [Ping timeout: 256 seconds]
truenito has quit [Ping timeout: 260 seconds]
enterprisey has quit [Remote host closed the connection]
chopin has joined #ruby
raul782 has joined #ruby
aryaching has quit [Ping timeout: 245 seconds]
raul782 has quit [Read error: Connection reset by peer]
ResidentBiscuit has joined #ruby
aidalgol has joined #ruby
aryaching has joined #ruby
brent__ has joined #ruby
raul782 has joined #ruby
<brent__>
so i'm trying to integrate s3 into a rails/react app, so the user can upload and store/retrieve files. THis is my first time looking into s3, anybody have any tips on how to approach this?
Devalo has joined #ruby
raul782 has quit [Read error: Connection reset by peer]
raul782 has joined #ruby
ResidentBiscuit has quit [Ping timeout: 240 seconds]
raul782 has quit [Read error: Connection reset by peer]
jcmj has quit [Quit: Bye]
raul782 has joined #ruby
Devalo has quit [Ping timeout: 246 seconds]
Rodya_ has joined #ruby
ayonkhan has joined #ruby
Asher has quit [Quit: Leaving.]
jenrzzz has joined #ruby
Asher has joined #ruby
arescorpio has quit [Quit: Leaving.]
d0nn1e has quit [Ping timeout: 250 seconds]
nankyokusei has joined #ruby
Jayson_Virissimo has joined #ruby
hahuang65 has quit [Ping timeout: 250 seconds]
d0nn1e has joined #ruby
dviola has quit [Quit: WeeChat 1.6]
nankyokusei has quit [Ping timeout: 260 seconds]
aryaching has quit [Remote host closed the connection]
dnicole has joined #ruby
jaguarmagenta has joined #ruby
jenrzzz has quit [Ping timeout: 265 seconds]
hahuang65 has joined #ruby
millerti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
johnzorn- has quit [Ping timeout: 240 seconds]
ayonkhan has quit [Read error: Connection reset by peer]
charliesome has joined #ruby
ayonkhan has joined #ruby
dnicole has quit [Ping timeout: 258 seconds]
jaguarmagenta has quit [Ping timeout: 260 seconds]
gizmore has quit [Remote host closed the connection]
Jayson_Virissimo has quit []
gizmore has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ascarter has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ascarter has joined #ruby
raul782 has quit [Remote host closed the connection]
ramfjord has quit [Ping timeout: 245 seconds]
ramfjord_ has quit [Ping timeout: 244 seconds]
ascarter has quit [Ping timeout: 260 seconds]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
jgnagy has joined #ruby
jgnagy has quit [Ping timeout: 256 seconds]
x77686d has joined #ruby
johnzorn has joined #ruby
ayonkhan has quit [Read error: Connection reset by peer]
ayonkhan has joined #ruby
xberg has joined #ruby
x77686d has quit [Quit: x77686d]
ResidentBiscuit has joined #ruby
redpants has quit [Quit: leaving]
ResidentBiscuit has quit [Ping timeout: 245 seconds]
ayonkhan has quit [Read error: Connection reset by peer]
ayonkhan has joined #ruby
giraffe has joined #ruby
tpendragon has joined #ruby
aidalgol has quit [Quit: zZzZzZzzz]
ayonkhan has quit [Read error: Connection reset by peer]
ayonkhan has joined #ruby
omphe has joined #ruby
byte512 has joined #ruby
antoniobeyah has quit [Quit: antoniobeyah]
<SkrubLord>
is nokogiri included in mechanize?
maattdd has joined #ruby
<al2o3-cr>
SkrubLord: i think so
jaguarmagenta has quit [Remote host closed the connection]
<SkrubLord>
btw, i deleted my .gem, is that bad?
<SkrubLord>
i mean i did not uninstall gems, though they were installed to my home, im on arch
Devalo has quit [Remote host closed the connection]
meinside has quit [Quit: Connection closed for inactivity]
Devalo has joined #ruby
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jenrzzz has quit [Ping timeout: 258 seconds]
Devalo has quit [Ping timeout: 246 seconds]
chiru has quit [Ping timeout: 265 seconds]
futilegames has joined #ruby
yardenbar has joined #ruby
postmodern has quit [Quit: Leaving]
postmodern has joined #ruby
chiru has joined #ruby
grh has quit [Ping timeout: 268 seconds]
dionysus69 has quit [Quit: dionysus69]
dionysus69 has joined #ruby
sdwrage has quit [Quit: This computer has gone to sleep]
Jackneill has joined #ruby
aryaching has joined #ruby
tmtwd has quit [Ping timeout: 260 seconds]
ResidentBiscuit has joined #ruby
yardenbar has quit [Ping timeout: 248 seconds]
zeroDi has joined #ruby
futilegames has quit [Quit: futilegames]
ResidentBiscuit has quit [Ping timeout: 240 seconds]
konsolebox has quit [Quit: Leaving]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
leitz has joined #ruby
<leitz>
if "item" is a base-10 hex number passed as a string, is there a bettwe way to end up with a string hex number than psr = item.to_i.to_s(16).upcase
<Mon_Ouie>
"base 10 hex number"?
function has quit [Quit: /dev/null is full]
Guest43 has quit [Ping timeout: 248 seconds]
dnicole has joined #ruby
<leitz>
Mon_Ouie, the string comes in as something like "10", I need to make that "A"
<leitz>
I was trying to figure out how to say "it startes as a decimal number and needs to be a hexidecimal."
aryaching has quit [Read error: Connection reset by peer]
aryaching_ has joined #ruby
<Mon_Ouie>
I'd say "Convert from base 10 representation to base 16", a number does not inherently have a base
<Mon_Ouie>
As far as I know what you wrote is the simplest method to do that
<leitz>
Ah, okay.
<toretore>
you can be explicit in the first parsing: to_i(10)
Hyuk has joined #ruby
<leitz>
After a year or two I'm still a newbie.
<toretore>
then it's immediately obvious what you're doing
lel has quit [Ping timeout: 246 seconds]
<apeiros>
numbers not having a base seems to be a concept which is hard to grasp for many :-/
ResidentBiscuit has joined #ruby
govg has quit [Quit: leaving]
<toretore>
how do i convert 123 to hex pls
lel has joined #ruby
ResidentBiscuit has quit [Ping timeout: 245 seconds]
tau has joined #ruby
dionysus69 has quit [Ping timeout: 250 seconds]
<apeiros>
now I wonder what you play at - convert to vs. represent as?
nankyokusei has joined #ruby
<toretore>
i have a number, 123 and i have to convert it to a hex number
<toretore>
help me pls
<toretore>
tbf it's not super obvious that numbers exist outside of their representation
konsolebox has joined #ruby
<toretore>
it's something you have to learn
xberg has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
JeanCarloMachado has joined #ruby
hightower3 has joined #ruby
tau has quit [Remote host closed the connection]
Derperperd has quit [Quit: Derperperd]
jcao219 has joined #ruby
<apeiros>
toretore: it's not. but it's easy to see. what base does "five" have? what base does the 5 eyes on a die have? what base do 5 apples have? they all represent the same number.
teclator has quit [Ping timeout: 258 seconds]
xberg_ has joined #ruby
xberg has quit [Ping timeout: 244 seconds]
hightower2 has quit [Ping timeout: 260 seconds]
Puffball has quit [Remote host closed the connection]
<toretore>
apeiros: yes it is, when you've been made aware of it
<apeiros>
yes. hence I fully agree with "not obvious" :)
eb0t has quit [Quit: WeeChat 1.4]
gizmore is now known as MIT
<MIT>
please sir, have you seen my license?
MIT is now known as gizmore
pawnbox has quit [Ping timeout: 260 seconds]
Puffball has joined #ruby
<gizmore>
fun fact
<gizmore>
i am back to PHP on gwf4 now :P
<gizmore>
it is better than rails somehoe
pawnbox has joined #ruby
<gizmore>
but php :/
<gizmore>
i would love to try another language... but gwf is huge
<User458764>
scootaloo Well done thanks for the tips
postmodern has quit [Quit: Leaving]
nankyokusei has joined #ruby
montanonic has quit [Remote host closed the connection]
Ebok has joined #ruby
pawnbox has joined #ruby
nankyokusei has quit [Ping timeout: 245 seconds]
jcao219 has joined #ruby
william3 has quit [Remote host closed the connection]
shinnya has quit [Ping timeout: 268 seconds]
william3 has joined #ruby
shashin has joined #ruby
william3_ has joined #ruby
zeroDi has quit [Quit: WeeChat 1.6]
william3 has quit [Ping timeout: 258 seconds]
william3_ has quit [Ping timeout: 246 seconds]
xall_ has joined #ruby
shashin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
psychicist__ has quit [Ping timeout: 248 seconds]
balazs_ has quit [Ping timeout: 260 seconds]
Devalo has quit [Remote host closed the connection]
dcluna has joined #ruby
SCHAAP137 has quit [Remote host closed the connection]
balazs_ has joined #ruby
centrx has joined #ruby
rippa has joined #ruby
Devalo has joined #ruby
SteenJobs has quit [Quit: SteenJobs]
beilabs has quit [Remote host closed the connection]
Devalo has quit [Ping timeout: 246 seconds]
hfp_work has quit [Ping timeout: 246 seconds]
beilabs has joined #ruby
psychicist__ has joined #ruby
hfp_work has joined #ruby
beilabs has quit [Ping timeout: 248 seconds]
sepp2k has quit [Read error: Connection reset by peer]
william3 has joined #ruby
x77686d has joined #ruby
binaryplease has joined #ruby
adavia has quit [Ping timeout: 246 seconds]
<hightower3>
Hey, when I do @logger= Logger.new(STDOUT), it opens a new fd instead of re-using the existing STDOUT. How can I force the @logger to use the existing STDOUT?
hfp_work has quit [Ping timeout: 265 seconds]
Ebok has quit [Quit: Leaving]
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jgnagy has joined #ruby
hfp_work has joined #ruby
ascarter has joined #ruby
the_drow has quit [Quit: This computer has gone to sleep]
<centrx>
hightower3: from looking at the source, Logger.new opens a new fd with open() if the one passed to it does not respond to :write and to :close
<centrx>
maybe try using $stdout?
<centrx>
or pass whatever existing fd you want to use
<hightower3>
centrx, right on, $stdout worked
<hightower3>
centrx, hm, I am trying to write a test for logger output, using code that comes down to: assert_output(/match/) { @logger.debug 'something'}
<hightower3>
but 'something' was being printed to screen instead of captured
ResidentBiscuit has joined #ruby
<hightower3>
centrx, oh, my mistake, I had changed the test. No difference between STDOUT/$stdout
<hightower3>
(both exhibit the same described problem)
ascarter has quit [Ping timeout: 244 seconds]
balazs_ has quit [Ping timeout: 260 seconds]
ResidentBiscuit has quit [Remote host closed the connection]
ResidentBiscuit has joined #ruby
SteenJobs has joined #ruby
ResidentBiscuit has quit [Client Quit]
pragmaticus has quit [Read error: No route to host]
balazs_ has joined #ruby
brendan- has joined #ruby
yardenbar has joined #ruby
SCHAAP137 has joined #ruby
workmad3 has quit [Ping timeout: 260 seconds]
sdwrage has joined #ruby
xall_ has quit [Ping timeout: 250 seconds]
psychicist__ has quit [Ping timeout: 250 seconds]
aryaching has joined #ruby
beilabs has joined #ruby
psychicist__ has joined #ruby
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
aryaching_ has joined #ruby
xall_ has joined #ruby
aryaching has quit [Ping timeout: 260 seconds]
function has joined #ruby
SCHAAP137 has quit [Remote host closed the connection]
jhack has joined #ruby
function has quit [Quit: found 1 in /dev/zero]
adavia has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
konsolebox has quit [Quit: Leaving]
nankyokusei has joined #ruby
sdwrage_ has joined #ruby
xcesariox has joined #ruby
sdwrage has quit [Ping timeout: 258 seconds]
luckyruby has quit [Quit: Leaving...]
nankyokusei has quit [Ping timeout: 248 seconds]
omphe has joined #ruby
balazs_ has quit [Ping timeout: 260 seconds]
fantazo has joined #ruby
balazs_ has joined #ruby
jgnagy has quit [Remote host closed the connection]
sdwrage_ has quit [Ping timeout: 260 seconds]
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sdwrage_ has joined #ruby
Derperperd has joined #ruby
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
vuoto has joined #ruby
JeanCarloMachado has joined #ruby
codfection has quit [Quit: Leaving]
jaguarmagenta has quit [Remote host closed the connection]
adavia has quit [Ping timeout: 260 seconds]
chouhoulis has joined #ruby
binaryplease has quit [Ping timeout: 256 seconds]
firstdayonthejob has quit [Ping timeout: 248 seconds]
jaguarmagenta has joined #ruby
psychici1t__ has joined #ruby
guanjian[m] has joined #ruby
psychicist__ has quit [Read error: Connection reset by peer]
balazs_ has quit [Read error: Connection reset by peer]
sdwrage_ has quit [Quit: This computer has gone to sleep]
binaryplease has joined #ruby
DLSteve has joined #ruby
binaryplease has quit [Client Quit]
fantazo has quit [Ping timeout: 250 seconds]
SCHAAP137 has joined #ruby
firstdayonthejob has joined #ruby
x77686d has quit [Quit: x77686d]
firstdayonthejob has quit [Ping timeout: 265 seconds]
cdg has joined #ruby
JeanCarloMachado has quit [Ping timeout: 260 seconds]
ResidentBiscuit has joined #ruby
brendan- has joined #ruby
x77686d has joined #ruby
psychici1t__ has quit [Ping timeout: 260 seconds]
fantazo has joined #ruby
nowhereman has quit [Ping timeout: 265 seconds]
Devalo has joined #ruby
firstdayonthejob has joined #ruby
Devalo has quit [Ping timeout: 246 seconds]
pawnbox has quit [Remote host closed the connection]
nikivi has joined #ruby
psychicist__ has joined #ruby
fantazo has quit [Quit: Verlassend]
konsolebox has joined #ruby
nowhereman has joined #ruby
symm- has joined #ruby
Bish has quit [Ping timeout: 256 seconds]
Bish has joined #ruby
lenwood has joined #ruby
Qommand0r has joined #ruby
Ebok has joined #ruby
omphe has joined #ruby
znz_jp has quit [Remote host closed the connection]
chouhoulis has quit [Remote host closed the connection]
nankyokusei has joined #ruby
znz_jp has joined #ruby
centrx has quit [Remote host closed the connection]
pilne has joined #ruby
nankyokusei has quit [Ping timeout: 268 seconds]
x77686d has quit [Quit: x77686d]
centrx has joined #ruby
reverberations has quit [Ping timeout: 268 seconds]
dviola has joined #ruby
pawnbox has joined #ruby
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
pragmaticus has joined #ruby
Ebok has quit [Quit: This computer has gone to sleep]
MrBusiness2 has quit [Ping timeout: 250 seconds]
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
futilegames has joined #ruby
kareelee has joined #ruby
beilabs has quit [Remote host closed the connection]
cdg_ has joined #ruby
cdg has quit [Ping timeout: 260 seconds]
pawnbox has quit [Remote host closed the connection]
jhack has quit [Quit: jhack]
antoniobeyah has joined #ruby
xcesariox has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
blackbombay has joined #ruby
workmad3 has joined #ruby
claudiuinberlin has quit [Remote host closed the connection]
claudiuinberlin has joined #ruby
xcesariox has joined #ruby
Derperperd has quit [Quit: Derperperd]
jaguarmagenta has quit [Remote host closed the connection]
skweek has quit [Ping timeout: 250 seconds]
konsolebox has quit [Ping timeout: 268 seconds]
reverberations has joined #ruby
futilegames has quit [Quit: futilegames]
ResidentBiscuit has quit [Remote host closed the connection]
ResidentBiscuit has joined #ruby
xcesariox has quit [Remote host closed the connection]
Salih has joined #ruby
Salih has joined #ruby
Salih has quit [Changing host]
ResidentBiscuit has quit [Ping timeout: 258 seconds]
User458764 has joined #ruby
pawnbox has joined #ruby
MrBusiness2 has joined #ruby
workmad3 has quit [Ping timeout: 244 seconds]
reverberations has quit [Ping timeout: 258 seconds]
x0f has quit [Ping timeout: 246 seconds]
Derperperd has joined #ruby
konsolebox has joined #ruby
nikivi has quit [Quit: irc]
omphe has joined #ruby
alan_w has quit [Quit: WeeChat 1.4]
tmtwd has joined #ruby
nikivi has joined #ruby
x0f has joined #ruby
antoniobeyah has quit [Quit: antoniobeyah]
reverberations has joined #ruby
alan_w has joined #ruby
tomios has joined #ruby
jgnagy has joined #ruby
claudiuinberlin has quit [Remote host closed the connection]
claudiuinberlin has joined #ruby
psychicist__ has quit [Ping timeout: 260 seconds]
cdg_ has quit [Remote host closed the connection]
marsjaninzmarsa has quit [Quit: ZNC 1.7.x-git-487-cbf5c38 - http://znc.in]
tokleng has joined #ruby
ascarter has joined #ruby
jaguarmagenta has joined #ruby
jgnagy has quit [Ping timeout: 246 seconds]
marsjaninzmarsa has joined #ruby
tokleng has left #ruby [#ruby]
claudiuinberlin has quit [Ping timeout: 250 seconds]
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
x0f has quit [Remote host closed the connection]
cdg has joined #ruby
lenwood has quit [Ping timeout: 240 seconds]
yardenbar has quit [Ping timeout: 256 seconds]
futilegames has joined #ruby
tmtwd has quit [Ping timeout: 246 seconds]
blackbombay has quit [Ping timeout: 256 seconds]
psychicist__ has joined #ruby
jaguarmagenta has quit [Remote host closed the connection]
jgnagy has joined #ruby
nikivi has quit [Quit: irc]
redpants has joined #ruby
SteenJobs has quit [Quit: SteenJobs]
ascarter has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Channel6 has joined #ruby
ruid has joined #ruby
jaguarmagenta has joined #ruby
agit0 has joined #ruby
xall_ has quit [Ping timeout: 240 seconds]
enterprisey has joined #ruby
blackbombay has joined #ruby
nankyokusei has joined #ruby
claudiuinberlin has joined #ruby
domgetter has joined #ruby
beilabs has joined #ruby
nankyokusei has quit [Ping timeout: 258 seconds]
JoshS has quit [Quit: Leaving]
xtsee has joined #ruby
beilabs has quit [Remote host closed the connection]
beilabs has joined #ruby
ruid has quit [Ping timeout: 240 seconds]
jaguarmagenta has quit [Remote host closed the connection]
jaguarmagenta has joined #ruby
nikivi has joined #ruby
blackbombay has quit [Ping timeout: 258 seconds]
armyriad has quit [Quit: Leaving]
tomios has quit [Ping timeout: 250 seconds]
beilabs has quit [Ping timeout: 256 seconds]
vuoto has quit [Read error: Connection reset by peer]
Salih has quit [Quit: Leaving]
tectonic has joined #ruby
JeanCarloMachado has joined #ruby
enterprisey has quit [Remote host closed the connection]
GodFather has quit [Ping timeout: 260 seconds]
ramfjord has joined #ruby
JeanCarloMachado has quit [Ping timeout: 240 seconds]
ramfjord_ has joined #ruby
blackbombay has joined #ruby
Devalo has joined #ruby
JeanCarloMachado has joined #ruby
hahuang61 has joined #ruby
bmurt has joined #ruby
enterprisey has joined #ruby
Devalo has quit [Ping timeout: 246 seconds]
lenwood has joined #ruby
enterprisey has quit [Remote host closed the connection]
harai_ has joined #ruby
jgnagy has quit [Remote host closed the connection]
nikivi has quit [Quit: irc]
Devalo has joined #ruby
function has joined #ruby
jcao219 has quit [Ping timeout: 256 seconds]
Ebok has joined #ruby
chouhoulis has joined #ruby
x77686d has joined #ruby
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
lenwood has quit [Ping timeout: 246 seconds]
chouhoulis has quit [Ping timeout: 260 seconds]
grh has quit [Ping timeout: 268 seconds]
cisco has joined #ruby
enterprisey has joined #ruby
kareelee_ has joined #ruby
JeanCarloMachado has quit [Remote host closed the connection]
kareelee has quit [Ping timeout: 250 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jaguarmagenta has quit [Remote host closed the connection]
<apeiros>
Samos: 👍🏻
Rodya_ has joined #ruby
function is now known as trout
ResidentBiscuit has joined #ruby
scootaloo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ramfjord has quit [Ping timeout: 248 seconds]
ResidentBiscuit has quit [Remote host closed the connection]
ramfjord_ has quit [Ping timeout: 256 seconds]
ResidentBiscuit has joined #ruby
nankyokusei has joined #ruby
fnux has quit [Ping timeout: 250 seconds]
nankyokusei has quit [Ping timeout: 248 seconds]
muelleme has quit [Ping timeout: 265 seconds]
rdavila_ has joined #ruby
fnux has joined #ruby
kbdkode has joined #ruby
futilegames has quit [Quit: futilegames]
solocshaw has quit [Ping timeout: 246 seconds]
codfection has joined #ruby
_2easy has quit [Quit: leaving]
rdavila_ has quit [Ping timeout: 250 seconds]
LoneHerm_ has joined #ruby
skweek has joined #ruby
kareelee_ has quit []
JeanCarloMachado has joined #ruby
tau has quit [Remote host closed the connection]
scootaloo has joined #ruby
scootaloo is now known as Guest83905
_2easy has joined #ruby
_2easy has quit [Changing host]
_2easy has joined #ruby
Guest83905 has quit [Changing host]
Guest83905 has joined #ruby
Guest83905 is now known as scootaloo
fnux has quit [Quit: Grumpf.]
fnux has joined #ruby
AnoHito has quit [Ping timeout: 244 seconds]
x77686d has quit [Quit: x77686d]
LoneHerm_ has quit [Remote host closed the connection]
hahuang61 has joined #ruby
muelleme has joined #ruby
SpiffTR has joined #ruby
AnoHito has joined #ruby
djellemah_ has joined #ruby
rdavila has joined #ruby
Sammichmaker has joined #ruby
AnoHito has quit [Ping timeout: 244 seconds]
AnoHito has joined #ruby
<b0nn>
in ruby, if I have a module with class variables (eg. @@my_conf) and that variable is populated by reading from a yaml file, how do I ensure that that variable is populated
enterprisey has quit [Remote host closed the connection]
<b0nn>
I mean, how do I make the module read the file, once, for the entire lifetime of the application
<b0nn>
I guess I am asking how to instantiate the module, once for this part, and only once
<centrx>
It sounds like you want a CONSTANT not a @@class_variable
<centrx>
If you put the variable in the module outside of a method, it will be populated when the module is loaded
<b0nn>
ok, yeah, I think that's right
zeroDi has joined #ruby
<b0nn>
hm, so I think I have the definitions a bit mixed up in my head, a Constant is accessible to all instances of the class/module?
Ishido has quit [Read error: Connection reset by peer]
ruid has joined #ruby
ruid has joined #ruby
ruid has quit [Changing host]
<centrx>
b0nn: yes
<baweaver>
Same with a class var
<centrx>
b0nn: also generally avoid @@ class variables, they usually cause confusion
<baweaver>
a constant is just something that is, well, constant
<centrx>
yes
<centrx>
Use .freeze to enforce it being constant
<centrx>
CAPITAL_LETTERS is a convention for indicating constants, but does not enforce the unchanging nature of a constant
<centrx>
(although does produce a warning)
<b0nn>
ok, thanks
Ishido has joined #ruby
Madplatypus has joined #ruby
d0nn1e has quit [Ping timeout: 248 seconds]
Devalo has quit [Remote host closed the connection]
d0nn1e has joined #ruby
Devalo has joined #ruby
alexherbo2 has quit [Quit: WeeChat 1.6]
tomios has joined #ruby
Devalo has quit [Ping timeout: 246 seconds]
tomios has left #ruby [#ruby]
redpants has quit [Ping timeout: 260 seconds]
tectonic has quit [Ping timeout: 246 seconds]
tectonic has joined #ruby
tomios has joined #ruby
tectonic has quit [Client Quit]
muelleme has quit [Ping timeout: 244 seconds]
william3 has quit [Remote host closed the connection]
tristanp_ has quit [Remote host closed the connection]
tristanp has joined #ruby
johnzorn has quit [Ping timeout: 250 seconds]
johnzorn has joined #ruby
bmurt has joined #ruby
NeverTired has quit [Quit: Connection closed for inactivity]
djellemah_ has quit [Quit: Leaving]
tristanp has quit [Ping timeout: 258 seconds]
skweek has quit [Ping timeout: 265 seconds]
skweek has joined #ruby
tpendragon has quit [Ping timeout: 240 seconds]
cdg has quit [Remote host closed the connection]
rdavila has quit [Ping timeout: 245 seconds]
nankyokusei has joined #ruby
jgnagy has joined #ruby
nankyokusei has quit [Ping timeout: 246 seconds]
konsolebox has quit [Quit: Leaving]
jgnagy has quit [Ping timeout: 260 seconds]
Derperperd has quit [Ping timeout: 240 seconds]
Samos has quit [Quit: Page closed]
redpants has joined #ruby
ruid has quit [Ping timeout: 248 seconds]
Derperperd has joined #ruby
aidalgol has joined #ruby
SpiffTR has quit [Quit: WeeChat 1.5]
NeverTired has joined #ruby
bocaneri has quit [Read error: Connection reset by peer]
JeanCarloMachado has quit [Ping timeout: 260 seconds]
muelleme has joined #ruby
JeanCarloMachado has joined #ruby
tomios has quit [Ping timeout: 260 seconds]
tau has joined #ruby
SkrubLord has quit [Quit: Connection closed for inactivity]
chouhoulis has joined #ruby
Vile` has joined #ruby
baweaver is now known as baweaver_away
Gandalf has joined #ruby
jaguarmagenta has joined #ruby
Immune has joined #ruby
Gandalf has quit []
skweek has quit [Ping timeout: 258 seconds]
tomios has joined #ruby
govg has quit [Ping timeout: 260 seconds]
Rodya_ has quit [Remote host closed the connection]
jaguarmagenta has quit [Ping timeout: 250 seconds]
Rodya_ has joined #ruby
cisco has quit [Quit: Leaving.]
Devalo has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
SteenJobs has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
shashin has joined #ruby
enterprisey has joined #ruby
vuoto has joined #ruby
pragmaticus has quit [Ping timeout: 245 seconds]
Rodya_ has quit [Remote host closed the connection]
JeanCarloMachado has quit [Ping timeout: 260 seconds]
antoniobeyah has joined #ruby
lenwood has quit [Ping timeout: 265 seconds]
konsolebox has joined #ruby
tomios has quit [Ping timeout: 250 seconds]
blackbombay has quit [Ping timeout: 245 seconds]
moei has quit [Quit: Leaving...]
maattdd has quit [Ping timeout: 256 seconds]
atmosx has joined #ruby
Devalo has quit [Remote host closed the connection]
Devalo has joined #ruby
blackbombay has joined #ruby
rwb has quit [Ping timeout: 240 seconds]
grh has joined #ruby
nankyokusei has joined #ruby
william3 has joined #ruby
johnzorn has quit [Quit: Ciao]
<b0nn>
hmm, I have a loop in one method that runs.. forever on one thread
Devalo has quit [Ping timeout: 246 seconds]
<b0nn>
I want to stop it
<lupine>
so send it a notification of some sort
<apeiros>
while @should_run; …
<apeiros>
then set @should_run accordingly
<lupine>
hooray for shared mutable state :p
<b0nn>
ok, that will give me what I want (an opportunity to close things gracefully)
<b0nn>
wait, that's not working in my mind
brent__ has joined #ruby
<b0nn>
if the instance of a class on one thread has @do_run
<b0nn>
how do I change its state?
nankyokusei has quit [Ping timeout: 244 seconds]
<b0nn>
foo_thread.class_name::var = False?
<toretore>
b0nn: how about gisting some code
<brent__>
so i'm trying to integrate s3 into a rails/react app, so the user can upload and store/retrieve files. THis is my first time looking into s3, anybody have any tips on how to approach this?
<apeiros>
b0nn: instance variables are not per-thread.
sdwrage_ has joined #ruby
<apeiros>
they're shared across all threads.
<apeiros>
that's why we have stuff like Mutex
<b0nn>
ok
<b0nn>
my model is, I have a set of threads, and each thread has instantiated an object
<b0nn>
and one of those threads I want to stop a loop
<b0nn>
but only one
chouhoulis has quit [Remote host closed the connection]
<apeiros>
then do that
Jackneill has quit [Remote host closed the connection]
<lupine>
freeze acts on the value of the constant, not the constant
<antoniobeyah>
for local dev, take a look at https://www.minio.io/ , it can emulate the s3 apis
vikaton has joined #ruby
agit0 has quit [Quit: zzzZZZ….]
<brent__>
cool, I'll look through these
claudiuinberlin has quit []
<atmosx>
antoniobeyah: I had no idea about minio.io that's awesome
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<antoniobeyah>
yeah its super cool, have implemented it for ci and localdev and it works well
TomyLobo has quit [Ping timeout: 246 seconds]
<atmosx>
I could use for CI too, come to think of it. I use a half-baked CI testing for my side projects using my local proliant server as with gitlab runners
raul782 has joined #ruby
tomphp has joined #ruby
william3 has quit [Remote host closed the connection]
vuoto has quit [Remote host closed the connection]
Rodya_ has joined #ruby
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
workmad3 has joined #ruby
JeanCarloMachado has joined #ruby
threh has joined #ruby
<b0nn>
ok, clearly I'm a lot more rusty with threads than I though
marsjaninzmarsa has quit [Ping timeout: 240 seconds]
marsjaninzmarsa has joined #ruby
x77686d has joined #ruby
workmad3 has quit [Ping timeout: 250 seconds]
marsjaninzmarsa has quit [Excess Flood]
marsjaninzmarsa has joined #ruby
<apeiros>
b0nn: yes, that code doesn't have the broken part in it
<apeiros>
(it does have a race condition, though)
Ishido has quit [Quit: Roads? Where We're Going We Don't Need Roads.]
tectonic has joined #ruby
<b0nn>
apeiros: actually, I don't understand, my code was raising exceptions
<b0nn>
I justw asn't understanding them
<b0nn>
oh, I guess it wasn't
<apeiros>
well, in that case you had/have even more bugs
<apeiros>
I only spotted those in threads, and they'd just silently crash the threads.
vuoto has joined #ruby
tau has quit [Remote host closed the connection]
ponga has quit []
<b0nn>
ok, and the race condition is the producer/consumer issue, in that the queue could have been accessed by the consumer thread(s) whilst being empty?
<apeiros>
no, the race condition is by using puts without synchronisation. chances are low that you'll see an effect. but iirc the appended newline is scheduled separately. so it can happen that you get multiple lines clogged together followed by multiple newlines.
<b0nn>
oh I see
<apeiros>
try `200.times do Thread.new do puts "hello "*20 end end`
<apeiros>
that's enough contention on my machine for it to happen
tristanp has quit [Remote host closed the connection]
<b0nn>
heh, I was just sitting here thinking, why haven't they made appending the newline atomic
<apeiros>
because tradeoffs
<apeiros>
nothing is ever free.
CloCkWeRX has joined #ruby
x77686d has quit [Quit: x77686d]
<blackbombay>
except free stuff
<b0nn>
I guess
<b0nn>
it's just, that's such a subtle error
<apeiros>
blackbombay: show me some free stuff and I show you how it's not free :)
<apeiros>
b0nn: yes. with threads, the devil's in the details.
<apeiros>
and it's often very hard to spot.
raul782 has quit [Remote host closed the connection]
ascarter has joined #ruby
tummy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nankyokusei has joined #ruby
ResidentBiscuit has quit [Remote host closed the connection]
ResidentBiscuit has joined #ruby
blackbom1 has joined #ruby
xrlk has quit [Ping timeout: 268 seconds]
blackbombay has quit [Ping timeout: 260 seconds]
nankyokusei has quit [Ping timeout: 268 seconds]
ResidentBiscuit has quit [Ping timeout: 258 seconds]
threh has quit [Read error: Connection reset by peer]
<scootaloo>
apeiros: want a free virtual hug?
<apeiros>
hah
<apeiros>
yeah, sure, why not
* scootaloo
hugs
<apeiros>
thanks ;-)
<scootaloo>
I'm waiting to see how it's not free ;)
jaguarmagenta has joined #ruby
firstdayonthejob has quit [Ping timeout: 268 seconds]
<apeiros>
no. in exchange for giving me a free hug, I'll spare you of that :D
redpants has quit [Ping timeout: 250 seconds]
toretore has quit [Ping timeout: 265 seconds]
Dimik has joined #ruby
jaguarmagenta has quit [Ping timeout: 250 seconds]
rwb has quit [Ping timeout: 265 seconds]
xrlk has joined #ruby
charliesome has joined #ruby
pawnbox has quit [Remote host closed the connection]
moei has joined #ruby
Madplatypus has quit [Quit: Connection closed for inactivity]
vuoto has quit [Remote host closed the connection]
edwardly has quit [Quit: ??????????]
centrx has quit []
GodFather has joined #ruby
montanonic has quit [Ping timeout: 258 seconds]
edwardly has joined #ruby
edwardly has quit [Changing host]
edwardly has joined #ruby
chouhoulis has quit [Remote host closed the connection]