jhass changed the topic of #ruby to: Rules & more: https://ruby-community.com || Ruby 2.3.1; 2.2.5; 2.1.9: https://ruby-lang.org || Paste >3 lines of text on https://gist.github.com || logs @ http://irclog.whitequark.org/ruby/
ReK2 has joined #ruby
ghr has joined #ruby
ReK2 has quit [Remote host closed the connection]
<wedgie> hello, i'm working with chef and frequently see loops of the form 'something.each do |foo, bar|' in examples. I can't for the life of me find the documentation for what the 'bar' actually means. Can anyone provide a link? I'm just failing at finding it somehow
ReK2 has joined #ruby
ReK2 has joined #ruby
ReK2 has quit [Changing host]
preyalone has quit [Quit: Connection closed for inactivity]
ReK2 has quit [Remote host closed the connection]
<wrkrcoop> how do i create a class with a class variable?
ReK2 has joined #ruby
ReK2 has joined #ruby
ReK2 has quit [Changing host]
<Mirubiri> wrkrcoop: Constant = Class.new
mdw has quit [Ping timeout: 276 seconds]
mdw has joined #ruby
flashpoint9 has quit [Remote host closed the connection]
<Mirubiri> wedgie: what do you mean? don't you know what the word 'bar' means, or what it should contain?
flashpoint9 has joined #ruby
<wedgie> Mirubiri: what it should contain.
<Mirubiri> wedgie: it depends on the 'something'
<Mirubiri> on what something yields
rcvalle has quit [Quit: rcvalle]
Danny_ has quit []
RegulationD has quit [Remote host closed the connection]
<wedgie> Mirubiri: i'm looking at this https://www.linode.com/docs/applications/chef/creating-your-first-chef-cookbook#configure-virtual-hosts Step 8 has th snippet i'm trying to understand
macsteps has quit [Remote host closed the connection]
<Mirubiri> oh wedgie
<Mirubiri> sitename and data
flashpoint9 has quit [Ping timeout: 250 seconds]
<Mirubiri> sitename i guess is the url of the site, and 'data' is a hash containing some information about that site
<Mirubiri> like the 'port'
flashpoint9 has joined #ruby
<Mirubiri> node yields sitename and data, and that's the way to extract that info
<wedgie> ... i think i'm being unclear in my question. From the context i can kinda see what's happening, but i'm unsure of the semantics of the ruby syntax. I'd like to understand better what ruby is actually doing. I see .each do |foo| all over the place, but no docs for when there is a second item inside the pipes e.g., |foo, bar|
<Mirubiri> is the same
<Mirubiri> ok wait
<Mirubiri> read the section about the yield statement
<wedgie> ok, reading. Thanks
<Mirubiri> it is only a methods which yields two variables instead of one
<Mirubiri> it is essentialy the same
ghr has quit [Ping timeout: 240 seconds]
marxarelli has quit [Quit: Textual IRC Client: www.textualapp.com]
cyphase has quit [Ping timeout: 272 seconds]
ReK2 has quit [Ping timeout: 240 seconds]
ghr has joined #ruby
<wedgie> Mirubiri: ok, so check my understanding: the .each in this case is returning a hash and the key is being put into sitename, and the value (which appens to be an array(?)) is put into data?
ReK2 has joined #ruby
ReK2 has quit [Changing host]
ReK2 has joined #ruby
flashpoint9 has quit [Remote host closed the connection]
flashpoint9 has joined #ruby
<Mirubiri> wedgie: nope, it is returning two variables, an url and a hash
cyphase has joined #ruby
<Mirubiri> that's the each method for a hash
<Mirubiri> if node is a hash, then maybe
<wedgie> i apologize if this is getting chef-specific, but what kind of structure is being defined here: default["lamp-stack"]["sites"]["example.com"] = { "port" => 80, "servername" => "example.com", "serveradmin" => "webmaster@example.com" }
<wedgie> cause it looks like it's treating "example.com" as sitename, and then port, servername, etc as some sort of hash in "data"
<Mirubiri> wedgie: in this case default looks like a hash of hashes
zacts has joined #ruby
zacstewart has quit [Ping timeout: 260 seconds]
flashpoint9 has quit [Ping timeout: 250 seconds]
<Mirubiri> default = { 'lamp-stack:{ "sites:{ "example":{} }}}
<zacts> hi rubyists
<Mirubiri> so you are assigning {port.....} to "example":{---}
<Mirubiri> inside all of that structure
<wedgie> ok, i think that makes sense
ghr has quit [Ping timeout: 240 seconds]
<wedgie> Mirubiri: thanks for taking the time to explain this stuf to me. I really appreciate it :)
<Mirubiri> it allows you to do the same for lots of urls
<Mirubiri> you're very welcome!
<wedgie> in case it wasn't painfully obvious i had no prior ruby experience until i started playing with chef last week
<Mirubiri> well i have no experience in chef..
<Mirubiri> lol
ElFerna has joined #ruby
<Mirubiri> wedgie: invest some time learning about ruby basics it helps a lot
<Mirubiri> not difficult
<wedgie> alright, well i think that gets me started. Just trying to take the "magic" out of the examples i've been using. Thanks again.
<Mirubiri> ;)
<wedgie> and will-do. Learning a new language is never bad
<Mirubiri> good luck!
replay has quit []
mikeiniowa has joined #ruby
ghr has joined #ruby
blackmesa has joined #ruby
mattwashere has quit [Remote host closed the connection]
<ICantCook> depends on the language ;)
ElFerna has quit [Ping timeout: 252 seconds]
<Mirubiri> lol
<MOgolid> MS-DOS
<Mirubiri> programming languaje wars begin
<Mirubiri> hey, i learned ms-dos
<Mirubiri> gwbasic
<Mirubiri> it was my first programming languaje
<MOgolid> n1
<ICantCook> I had to learn and work with xslt for a while
ghr has quit [Ping timeout: 240 seconds]
<Mirubiri> sorry
zacstewart has joined #ruby
<MOgolid> c++ is my weapon
SilverKey has joined #ruby
<Mirubiri> mmm
blackmesa has quit [Ping timeout: 258 seconds]
<Mirubiri> someday i will learn it
tvw has quit [Ping timeout: 264 seconds]
ekinmur has joined #ruby
sshbio has quit [Remote host closed the connection]
<Mirubiri> but i don't know what to do
<Mirubiri> C or C++ thats the...
mdw has quit [Ping timeout: 250 seconds]
djbkd has quit [Remote host closed the connection]
<MOgolid> c#
<Mirubiri> c# ?
<MOgolid> thats the shit
<Mirubiri> why?
djbkd has joined #ruby
<MOgolid> "Google is your friend"
<Mirubiri> Google is a compulsive liar many times
<MOgolid> duckduckgo
<MOgolid> disconnect(darkweb
<MOgolid> whatevr
<MOgolid> Use your search engine
ghr has joined #ruby
<Mirubiri> Google was only a foo var in that statement lol
<MOgolid> Mirubiri: use FTp
<MOgolid> best
<MOgolid> ftp / pastebin
hxegon_afk is now known as hxegon
<Mirubiri> telnet
ekinmur has quit [Ping timeout: 240 seconds]
<Mirubiri> i think that's the way to go
ElFerna has joined #ruby
<hxegon> Thinking about using forwardable to extend a class with OpenStruct methods, thoughts?
djbkd has quit [Ping timeout: 260 seconds]
<Mirubiri> no, seriously. For parallel processing I think that C will do better than C#
minimalism has quit [Quit: minimalism]
<hxegon> OpenStruct.new(hash) that is
<MOgolid> bash
buddhabrot_ has quit [Quit: Connection closed for inactivity]
cd-rum_ has quit [Quit: Textual IRC Client: www.textualapp.com]
wrkrcoop has quit [Quit: wrkrcoop]
sneakers has quit [Ping timeout: 240 seconds]
rodfersou has joined #ruby
<MOgolid> need ircop? Qme
minimalism has joined #ruby
zacts has quit [Ping timeout: 258 seconds]
cd-rum has joined #ruby
jaguarmagenta has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
AndrewIsHere has quit [Remote host closed the connection]
AndrewIsHere has joined #ruby
cd-rum_ has joined #ruby
antgel has joined #ruby
cd-rum has quit [Ping timeout: 272 seconds]
ghr has joined #ruby
User458764 has quit [Ping timeout: 260 seconds]
xall_ has quit [Read error: Connection reset by peer]
xall_ has joined #ruby
AndrewIsHere has quit [Ping timeout: 250 seconds]
flashpoint9 has joined #ruby
SilverKey has quit [Quit: Halted.]
ghr has quit [Ping timeout: 240 seconds]
enterprisey has joined #ruby
cyphase has quit [Ping timeout: 240 seconds]
CloCkWeRX has joined #ruby
User458764 has joined #ruby
ghr has joined #ruby
antgel has quit [Ping timeout: 258 seconds]
zeroDi has quit [Quit: WeeChat 1.5]
RegulationD has joined #ruby
cyphase has joined #ruby
saneax is now known as saneax_AFK
zacstewart has quit [Ping timeout: 250 seconds]
karapetyan has joined #ruby
zacts has joined #ruby
blackgoat has quit [Ping timeout: 244 seconds]
RegulationD has quit [Ping timeout: 272 seconds]
karapetyan has quit [Ping timeout: 240 seconds]
ghr has quit [Ping timeout: 240 seconds]
moeabdol3 has joined #ruby
<Radar> ?offtopic MOgolid
<ruby[bot]> MOgolid: this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
A_Drone has joined #ruby
ghr has joined #ruby
nankyokusei has joined #ruby
Bira has quit [Quit: Leaving]
moeabdol3 has quit [Ping timeout: 240 seconds]
rodorgas has joined #ruby
iceden has quit [Ping timeout: 276 seconds]
ghr has quit [Ping timeout: 240 seconds]
nankyokusei has quit [Ping timeout: 240 seconds]
jenrzzz has quit [Ping timeout: 272 seconds]
Walter-4 has quit [Remote host closed the connection]
A_Drone has quit [Remote host closed the connection]
hellcode has joined #ruby
ghr has joined #ruby
arescorpio has joined #ruby
memorasus has quit [Ping timeout: 258 seconds]
jaguarmagenta has quit [Remote host closed the connection]
jaguarmagenta has joined #ruby
A_Drone has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
cdg has quit [Remote host closed the connection]
cdg has joined #ruby
blackmesa has joined #ruby
jaguarmagenta has quit [Ping timeout: 240 seconds]
hutch34 has joined #ruby
coyo has quit [Read error: Connection reset by peer]
ghr has joined #ruby
cdg has quit [Ping timeout: 276 seconds]
singalaut has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
flashpoint9 has quit [Remote host closed the connection]
roamingdog has quit [Read error: Connection reset by peer]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
MOgolid has quit [Quit: Leaving]
jsdfkl has joined #ruby
SilverKey has joined #ruby
jsdfkl is now known as NorstaR
ghr has quit [Ping timeout: 240 seconds]
xall_ has quit [Ping timeout: 272 seconds]
roamingdog has joined #ruby
techietrash has quit [Quit: Bye! <(^_^<)]
techietrash has joined #ruby
underplank has joined #ruby
sdothum has joined #ruby
paradisaeidae_ has joined #ruby
ghr has joined #ruby
A_Drone has quit [Ping timeout: 272 seconds]
nettoweb has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
A_Drone has joined #ruby
xall_ has joined #ruby
ekinmur has joined #ruby
underplank has quit [Quit: underplank]
AndrewIsHere has joined #ruby
GNUYawk has quit [Quit: GNUYawk]
A_Drone_ has joined #ruby
A_Drone has quit [Ping timeout: 240 seconds]
SilverKey has quit [Quit: Halted.]
hellcode has quit [Ping timeout: 240 seconds]
ghr has quit [Ping timeout: 240 seconds]
A_Drone_ has quit [Read error: Connection reset by peer]
AndrewIsHere has quit [Ping timeout: 250 seconds]
A_Drone has joined #ruby
JeanCarloMachado has quit [Ping timeout: 276 seconds]
zacstewart has joined #ruby
ghr has joined #ruby
hellcode has joined #ruby
c355e3b has quit [Quit: Connection closed for inactivity]
ghr has quit [Ping timeout: 240 seconds]
zacstewart has quit [Ping timeout: 276 seconds]
xall_ has quit [Read error: Connection reset by peer]
safetypin has quit [Quit: Textual IRC Client: www.textualapp.com]
ekinmur has quit [Quit: Textual IRC Client: www.textualapp.com]
xall_ has joined #ruby
mattwashere has joined #ruby
ghr has joined #ruby
leea has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jackjackdripper has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
A_Drone has quit [Remote host closed the connection]
A_Drone has joined #ruby
hellcode has quit [Ping timeout: 240 seconds]
ekinmur has joined #ruby
drtwo has joined #ruby
weaksauce has joined #ruby
ellistaa has joined #ruby
Dimik has quit [Ping timeout: 260 seconds]
NorstaR has quit [Remote host closed the connection]
NorstaR has joined #ruby
xall_ has quit [Ping timeout: 240 seconds]
ghr has joined #ruby
nando293921 has joined #ruby
phredus has quit [Read error: No route to host]
ellistaa has left #ruby [#ruby]
GNUYawk has joined #ruby
nando293921 has quit [Read error: Connection reset by peer]
nando294021 has joined #ruby
phredus has joined #ruby
hdlbrkr has joined #ruby
NorstaR has quit [Ping timeout: 240 seconds]
enterprisey has quit [Ping timeout: 250 seconds]
aries_liuxueyang has quit [Ping timeout: 244 seconds]
jameswatling has joined #ruby
hxegon is now known as hxegon_afk
ghr has quit [Ping timeout: 240 seconds]
tmtwd has joined #ruby
A_Drone_ has joined #ruby
A_Drone has quit [Ping timeout: 252 seconds]
nettoweb has joined #ruby
blackmesa has joined #ruby
enterprisey has joined #ruby
ghr has joined #ruby
blackmesa has quit [Ping timeout: 252 seconds]
A_Drone_ has quit [Ping timeout: 252 seconds]
edwinvdgraaf has joined #ruby
A_Drone has joined #ruby
benlieb has joined #ruby
cd-rum_ has quit [Ping timeout: 240 seconds]
Sashimi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zacstewart has joined #ruby
nando294021 has quit [Ping timeout: 240 seconds]
dkam has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
GodFather has quit [Ping timeout: 264 seconds]
edwinvdg_ has quit [Ping timeout: 276 seconds]
roamingdog has quit [Remote host closed the connection]
ghr has joined #ruby
astrobun_ has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
nettoweb has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
A_Drone has joined #ruby
araujo__ has joined #ruby
zacts has quit [Read error: Connection reset by peer]
ekinmur has quit [Ping timeout: 244 seconds]
hinbody has quit [Quit: leaving]
ekinmur has joined #ruby
CodingWolf has joined #ruby
araujo_ has quit [Ping timeout: 244 seconds]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
hinbody has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
cd-rum has joined #ruby
craigp has quit [Ping timeout: 264 seconds]
A_Drone has quit [Remote host closed the connection]
A_Drone has joined #ruby
aries_liuxueyang has joined #ruby
ghr has joined #ruby
braincras has quit [Quit: bye bye]
bokayio has quit [Read error: Connection reset by peer]
leea has joined #ruby
<leea> Anyone know of OS projects that need support?
pawnbox has quit [Ping timeout: 272 seconds]
ghr has quit [Ping timeout: 240 seconds]
voodoofish4301 has joined #ruby
pawnbox has joined #ruby
bokayio has joined #ruby
dkam has quit [Quit: Be back later ...]
hdlbrkr has quit [Quit: leaving]
pawnbox has quit [Remote host closed the connection]
voodoofish4302 has quit [Ping timeout: 260 seconds]
mattwashere has quit [Remote host closed the connection]
pawnbox has joined #ruby
ramfjord has quit [Ping timeout: 272 seconds]
voodoofish4302 has joined #ruby
voodoofish4301 has quit [Ping timeout: 264 seconds]
ghr has joined #ruby
braincrash has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
shinnya has quit [Ping timeout: 240 seconds]
benlieb has quit [Quit: benlieb]
CodingWolf has quit [Ping timeout: 240 seconds]
zacts has joined #ruby
<shevy> OS? with ruby or independent of ruby?
pabs has quit [Ping timeout: 240 seconds]
k3rn31 has joined #ruby
jaguarmagenta has joined #ruby
jishankai has joined #ruby
treaki__ has joined #ruby
zacstewart has quit [Ping timeout: 250 seconds]
pabs has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
hutch34 has quit [Ping timeout: 250 seconds]
nankyokusei has joined #ruby
treaki_ has quit [Ping timeout: 272 seconds]
A_Drone has quit [Ping timeout: 276 seconds]
A_Drone_ has joined #ruby
ghr has joined #ruby
nankyokusei has quit [Ping timeout: 258 seconds]
<leea> ruby OS projects
jackjackdripper has quit [Quit: Leaving.]
<shevy> hmm
A_Drone has joined #ruby
<shevy> there used to be heretix
A_Drone_ has quit [Read error: Connection reset by peer]
<shevy> perhaps via mruby there may be some new interest in a ruby OS again
<shevy> until then I guess the best, simplest and most sustainable way would be to write as much ruby code as possible and enable whatever may be useful in a modular, lego-brick like fashion
saneax_AFK is now known as saneax
<leea> oh i meant open source, not operating system
<shevy> aha
<shevy> now that will have a lot more projects that may need help
<shevy> this one may need help https://github.com/jordansissel/fpm
<shevy> lots of open issues and only one main dev in his spare time
<leea> I'll take a look after finishing dinner :D, thanks
hutch34 has joined #ruby
<shevy> I just found another one perhaps by epitron :D
<shevy> reminds me a bit of the old facets gem
zacts has quit [Quit: WeeChat 1.4]
<shevy> perhaps some more ruby games
zacts has joined #ruby
<shevy> leea btw if you can not find any project to add code to, it may also be useful if you will test some promising projects and supply feedback to the author - that one of course depends on an author willing to listen too, before you can do so, otherwise it may be wasted effort
bokayio has quit [Read error: Connection reset by peer]
Madplatypus has quit [Quit: Connection closed for inactivity]
<leea> is there an index of these projects?
<shevy> hmmm
<shevy> I don't think so in the sense of an index or a page where you can see which projects may need help
<shevy> perhaps scanning on https://www.ruby-toolbox.com/ may be useful, in particular for when projects are semi-popular and semi-active or more than that
blackmesa has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
bokayio has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
saneax is now known as saneax_AFK
AndrewIsHere has joined #ruby
LoneHermit has joined #ruby
blackmesa has quit [Ping timeout: 252 seconds]
A_Drone has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
astrobun_ has quit [Remote host closed the connection]
alfiemax has quit [Ping timeout: 272 seconds]
astrobun_ has joined #ruby
ghr has joined #ruby
LoneHermit has quit [Ping timeout: 252 seconds]
Es0teric has quit [Quit: Computer has gone to sleep.]
enterprisey has quit [Ping timeout: 250 seconds]
AndrewIsHere has quit [Remote host closed the connection]
ghr has quit [Ping timeout: 240 seconds]
gix has quit [Ping timeout: 264 seconds]
pdoherty has quit [Ping timeout: 276 seconds]
chequers has joined #ruby
gix has joined #ruby
<chequers> hi all, I'm working with the AWS API and I find myself writing multiple levels of looping to access the data I want, like this https://gist.github.com/alexjurkiewicz/94676d3e8b39969dce6e30f8fe7dc187 . Is there a better way which requires less indentation?
mattwashere has joined #ruby
Guest60828 has quit [Ping timeout: 276 seconds]
enterprisey has joined #ruby
ghr has joined #ruby
<shevy> I don't know the data structure and objects used there, but perhaps via .select
rodfersou has quit [Quit: leaving]
Guest60828 has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mattwashere has quit [Ping timeout: 260 seconds]
vdamewood has quit [Quit: Life beckons.]
ghr has quit [Ping timeout: 240 seconds]
connor_goodwolf has quit [Ping timeout: 244 seconds]
skweek has joined #ruby
drtwo has left #ruby [#ruby]
connor_goodwolf has joined #ruby
CloCkWeRX has quit [Remote host closed the connection]
CloCkWeRX has joined #ruby
arescorpio has quit [Quit: Leaving.]
ghr has joined #ruby
yadobujo has joined #ruby
hk238 has joined #ruby
daffy_duck_2 has joined #ruby
djbkd has joined #ruby
RegulationD has joined #ruby
daffy_duck has quit [Ping timeout: 240 seconds]
ghr has quit [Ping timeout: 240 seconds]
wald0 has quit [Ping timeout: 250 seconds]
skweek has quit [Ping timeout: 252 seconds]
ewilliam has joined #ruby
RegulationD has quit [Ping timeout: 250 seconds]
xall_ has joined #ruby
ghr has joined #ruby
zacstewart has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
rumia has joined #ruby
araujo__ has quit [Quit: Leaving]
devbug has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
postmodern has quit [Quit: Leaving]
zacstewart has quit [Ping timeout: 272 seconds]
chequers has left #ruby [#ruby]
whathappens has joined #ruby
Hyuk has joined #ruby
astrobu__ has joined #ruby
saneax_AFK is now known as saneax
tmtwd has quit [Ping timeout: 258 seconds]
ElFerna has quit [Ping timeout: 244 seconds]
ghr has joined #ruby
astrobun_ has quit [Ping timeout: 276 seconds]
pabs has quit [Ping timeout: 258 seconds]
dkam has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
tmtwd has joined #ruby
A_Drone has joined #ruby
Mia has quit [Read error: Connection reset by peer]
skweek has joined #ruby
ReK2GnULinuX has joined #ruby
ReK2 has quit [Ping timeout: 276 seconds]
pabs has joined #ruby
ghr has joined #ruby
vuoto has joined #ruby
devbug has quit [Quit: ZZZzzz…]
rann has joined #ruby
blackmesa has joined #ruby
devbug has joined #ruby
aries_liuxueyang has quit [Ping timeout: 252 seconds]
ghr has quit [Ping timeout: 240 seconds]
aries_liuxueyang has joined #ruby
blackmesa has quit [Ping timeout: 252 seconds]
LoneHermit has joined #ruby
shinnya has joined #ruby
ghr has joined #ruby
nerium has quit [Read error: Connection reset by peer]
isberg has quit [Read error: Connection reset by peer]
nerium has joined #ruby
HammyJammy has joined #ruby
l4v2 has quit [Quit: l4v2]
LoneHermit has quit [Ping timeout: 252 seconds]
JammyHammy has quit [Ping timeout: 258 seconds]
AndrewIsHere has joined #ruby
dminuoso has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
AndrewIsHere has quit [Ping timeout: 250 seconds]
Hyuk has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ghr has joined #ruby
Hyuk has joined #ruby
<leea> shevy I'm looking into fpm, do you use it?
Es0teric has joined #ruby
ur5us has quit []
hutch34 has quit [Ping timeout: 276 seconds]
harfangk has joined #ruby
skweek has quit [Ping timeout: 240 seconds]
ghr has quit [Ping timeout: 240 seconds]
HammyJammy has quit [Ping timeout: 240 seconds]
Hyuk has quit [Client Quit]
strongcode has quit [Ping timeout: 244 seconds]
Hyuk has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
yfeldblum has quit [Remote host closed the connection]
Silthias has joined #ruby
ghr has joined #ruby
armyriad has quit [Read error: Connection reset by peer]
armyriad has joined #ruby
alfiemax has joined #ruby
Beverage has joined #ruby
yadobujo has quit [Remote host closed the connection]
Hyuk has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dminuoso has quit [Ping timeout: 240 seconds]
enterprisey has quit [Quit: Leaving]
Sucks has joined #ruby
roamingdog has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
Wsewolod has quit [Ping timeout: 258 seconds]
Silthias1 has joined #ruby
Silthias has quit [Ping timeout: 240 seconds]
whathappens has quit [Remote host closed the connection]
whathappens has joined #ruby
skweek has joined #ruby
ghr has joined #ruby
craigp has joined #ruby
A_Drone has joined #ruby
Hyuk has joined #ruby
Technodrome has joined #ruby
wald0 has joined #ruby
vuoto has quit [Remote host closed the connection]
whathappens has quit [Ping timeout: 250 seconds]
nankyokusei has joined #ruby
Hyuk has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ghr has quit [Ping timeout: 240 seconds]
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
wrkrcoop has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
<wrkrcoop> how can i go about getting audio from a user using ruby?
<wrkrcoop> i want to write a function that turns on the mic and lets the user record something
nankyokusei has quit [Ping timeout: 258 seconds]
ghr has joined #ruby
Sashimi has joined #ruby
Mon_Ouie has quit [Ping timeout: 264 seconds]
yeticry has quit [Quit: leaving]
yeticry has joined #ruby
wrkrcoop has quit [Quit: wrkrcoop]
lxsameer has joined #ruby
Mirubiri has quit [Quit: Mirubiri]
futilegames has joined #ruby
futilegames has quit [Client Quit]
A_Drone has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
Sashimi has quit [Client Quit]
nerium has quit [Ping timeout: 240 seconds]
Sashimi has joined #ruby
futilegames has joined #ruby
djbkd has quit [Quit: My people need me...]
aupadhye has joined #ruby
Sashimi has quit [Client Quit]
futilegames has quit [Client Quit]
Hyuk has joined #ruby
Sashimi has joined #ruby
ghr has joined #ruby
A_Drone has quit [Ping timeout: 260 seconds]
nerium has joined #ruby
blackmesa has joined #ruby
edwinvdgraaf has quit [Remote host closed the connection]
Sashimi has quit [Client Quit]
ninjaaron has joined #ruby
Sashimi has joined #ruby
davedev2_ has joined #ruby
Hyuk has quit [Client Quit]
futilegames has joined #ruby
futilegames has left #ruby [#ruby]
fredolinhares has quit [Quit: WeeChat 1.5]
ghr has quit [Ping timeout: 240 seconds]
tmtwd has quit [Ping timeout: 240 seconds]
<ninjaaron> Quick question about the ruby data model: Is it like Python, where every name is just a reference to an anonymous object, or is it more like Perl, where variables are bound more closely to the object unless they are explicitely made to be references?
davedev24 has quit [Ping timeout: 258 seconds]
Sashimi has quit [Client Quit]
blackmesa has quit [Ping timeout: 244 seconds]
<ninjaaron> (i.e. can you do the same shenanigans with mutible objects as in python)
dminuoso has joined #ruby
A_Drone has joined #ruby
Sashimi has joined #ruby
dionysus69 has joined #ruby
leea has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
govg has quit [Ping timeout: 276 seconds]
Hyuk has joined #ruby
<ninjaaron> I have hardly any experience with Ruby, but my gut says it's more like everything is a reference to an anonymous object.
Sashimi has quit [Client Quit]
xall_ has quit [Ping timeout: 272 seconds]
govg has joined #ruby
<ninjaaron> but my google-foo is bad with regards to this topic.
yadobujo has joined #ruby
<harfangk> see if this discussion answers your uery
Sashimi has joined #ruby
ghr has joined #ruby
JammyHammy has joined #ruby
jameswatling has quit []
Sashimi has quit [Client Quit]
A_Drone_ has joined #ruby
Sashimi has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
Cohedrin has joined #ruby
shinnya has quit [Ping timeout: 258 seconds]
ghr has quit [Ping timeout: 240 seconds]
<ninjaaron> harfangk: Yes. looks like Ruby is the same as Python in this regard. The more I learn Ruby, the more I feel like it's... the same as Python; I mean, with blocks instead of comprehensions and regex literals, and more emphasis on OO design patterns.
<ninjaaron> But a lot the same.
Dimik-- has joined #ruby
<harfangk> haha yeah hence they're often discussed in the same context
<harfangk> they have slightly different philosphies tho
<harfangk> my favorite analogy is this:
xall_ has joined #ruby
c0mrad3 has quit [Quit: Connection closed for inactivity]
ericsupreme has joined #ruby
<harfangk> if you like playing with lego, go with python; if you like playing with clay or playdough, go with ruby
<dminuoso> As pretty as that analogy may be, it is also utterly useless.
Macaveli has joined #ruby
Mon_Ouie has joined #ruby
<dminuoso> ninjaaron: Can you elaborate on your initial question?
blaxter has joined #ruby
<ninjaaron> I feel like the main philosophical difference is that python focuses on readability, where ruby focuses on writeablility (though, there is a lot of overlap in those two goals)
<ninjaaron> dminuoso: I think I understand now.
<ninjaaron> I was just wondering if everything in Ruby is like a pointer, or more like a real value.
yfeldblum has joined #ruby
<ninjaaron> Sounds like they are more like pointers.
<dminuoso> ninjaaron: The word "reference" majorly sucks though, because its meaning depends on the context. (Java for example uses the term reference on opposite terms from C++ perspective)
<dminuoso> It's probably better to say all variables/parameters/constants behave like pointers.
<ninjaaron> dminuoso: yeah.
xall_ has quit [Read error: Connection reset by peer]
ghr has joined #ruby
<ninjaaron> dminuoso: I assume that goes for class and function names as well?
<dminuoso> ninjaaron: classes are just objects like anything else.
A_Drone_ has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
<dminuoso> The fact that you (usually) use upper case names for them, just makes it a constant holding a class object
<dminuoso> ninjaaron: and methods (ruby has no "functions") are a bit tricky, in a nutshell invoking a method is just object.send(:method)
yfeldblum has quit [Ping timeout: 250 seconds]
<dminuoso> (A feat inherited from Smalltalk I believe)
ghr has quit [Ping timeout: 240 seconds]
amclain has quit [Quit: Leaving]
<dminuoso> Methods in Ruby are not first-class functions.
<ninjaaron> I see.
<ninjaaron> Are there first-class functions?
pawnbox_ has joined #ruby
<dminuoso> ninjaaron: Generally you mean?
<ninjaaron> Uh, yes?
roamingdog has quit [Remote host closed the connection]
<ninjaaron> Like, there must be a way to write a closure.
<ninjaaron> I'm sure I read about it somewhere.
<dminuoso> ninjaaron: Sure, either you use a Proc or you can build a Method from an actual method
<dminuoso> (That last bit shows that you can actually turn Ruby methods into first-class citizens after all)
woodruffw has quit [Ping timeout: 276 seconds]
<dminuoso> In short: There is 3 things that are not immediate objects. Variables, blocks and methods.
pawnbox has quit [Ping timeout: 260 seconds]
<ninjaaron> Ok, so it is a bit different from Python in that way.
mistermocha has joined #ruby
<ninjaaron> (Sorry for thinking about everything in terms of Python)
<dminuoso> ninjaaron: Though the Ruby way uses blocks generally for closures - which is its trademark.
moeabdol has joined #ruby
<dminuoso> for example: array.map { |e| e * 2 }
ghr has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
RegulationD has joined #ruby
<ninjaaron> I see. Blocks are something I'm still figuring out. I know some cases where you use them, but I wouldn't say I grok them. Probably needs more practice.
<dminuoso> ninjaaron: Once you get the hang out of them they become quite natural. It's a fairly elegant solution at inline lambdas basically.
<dminuoso> One that is readable, writeable and chainable!
A_Drone has joined #ruby
<havenwood> ninjaaron: Here are a few examples of differences between blocks, procs and lambdas in Ruby: https://gist.github.com/havenwood/f80308141c8460e3d181
<dminuoso> ninjaaron: A Proc is just an objectified Block - so they are the same except you can treat a Proc as an actual object. ;-)
<dminuoso> (And a Lambda is a kind of Proc with some subtle difference in how it behaves)
<dminuoso> Though havenwood's gist nicely shows that.
jishankai has quit [Ping timeout: 276 seconds]
<havenwood> ninjaaron: Or a bit of lambda calculus fun (great talk in the link): https://gist.github.com/havenwood/fd96e63ec60c15e07af85fc2f76f8ed7
<ninjaaron> I do have a penchant for chainable code structures. I'm all into shell pipes, and I sort of wish everything worked that way. Streem looks like a very exciting concept to me.
RegulationD has quit [Ping timeout: 264 seconds]
<havenwood> |> \o/
<dminuoso> >> [1,2,3,4,5,6,7,8,8].select { |e| e % 2 == 0 }.map { |e| e * 2 }.any? { |e| e > 10 }
<ruby[bot]> dminuoso: # => true (https://eval.in/607540)
<dminuoso> You can chain them all day long. :)
roamingdog has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
* ninjaaron gives thumbs-up
<dminuoso> Gotta blaze, later.
KnownSyntax_ has joined #ruby
KnownSyntax_ has quit [Changing host]
KnownSyntax_ has joined #ruby
<ninjaaron> bye, and thanks.
A_Drone has quit [Read error: Connection reset by peer]
KnownSyntax has quit [Ping timeout: 272 seconds]
aryaching has quit [Ping timeout: 250 seconds]
zacstewart has joined #ruby
UserInNeed has joined #ruby
dminuoso_ has joined #ruby
<dminuoso_> Still have to get used to having so much free WiFi on trains. :-)
woodruffw has joined #ruby
woodruffw has quit [Excess Flood]
firstdayonthejob has joined #ruby
woodruffw has joined #ruby
ninjaaron has quit [Quit: WeeChat 1.5]
ghr has joined #ruby
dminuoso has quit [Ping timeout: 260 seconds]
<dminuoso_> ninjaaron: The way that Ruby works with blocks and other things also easily allows for DSLs to be implemented, if that is your sort of things.
yfeldblum has joined #ruby
conta has joined #ruby
Sashimi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zacstewart has quit [Ping timeout: 260 seconds]
A_Drone has joined #ruby
Sashimi has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
NorstaR has joined #ruby
mistermocha has quit [Remote host closed the connection]
mistermocha has joined #ruby
Sashimi has quit [Client Quit]
Sashimi has joined #ruby
dionysus69 has quit [Ping timeout: 250 seconds]
blackgoat has joined #ruby
PaulCapestany has quit [Read error: Connection reset by peer]
Sashimi has quit [Client Quit]
mistermocha has quit [Ping timeout: 250 seconds]
NorstaR has quit [Ping timeout: 272 seconds]
ghr has joined #ruby
Sashimi has joined #ruby
ur5us has joined #ruby
PaulCapestany has joined #ruby
Sashimi has quit [Client Quit]
roamingdog has quit []
Guest95553 has quit [Ping timeout: 276 seconds]
Sashimi has joined #ruby
dionysus69 has joined #ruby
nuck has joined #ruby
firstdayonthejob has quit [Ping timeout: 272 seconds]
mark_66 has joined #ruby
nuck is now known as Guest39581
Sucks has quit [Ping timeout: 264 seconds]
AlexJakeGreen has joined #ruby
MikeIon has joined #ruby
Sashimi has quit [Client Quit]
Sashimi has joined #ruby
jishankai has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
Sashimi has quit [Client Quit]
TomyWork has joined #ruby
blackmesa has joined #ruby
Sashimi has joined #ruby
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
dminuoso_ has quit [Remote host closed the connection]
paradisaeidae_ has left #ruby [#ruby]
thoraxe has quit [Ping timeout: 240 seconds]
Sashimi has quit [Client Quit]
nerium has quit [Ping timeout: 264 seconds]
Sashimi has joined #ruby
LoneHermit has joined #ruby
AlexJakeGreen has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
skweek has quit [Ping timeout: 240 seconds]
ghr has joined #ruby
Sashimi has quit [Client Quit]
atom_ has joined #ruby
Sashimi has joined #ruby
miskatonic has joined #ruby
LoneHermit has quit [Ping timeout: 250 seconds]
edwinvdgraaf has joined #ruby
anisha has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
Sashimi has quit [Client Quit]
AndrewIsHere has joined #ruby
Sashimi has joined #ruby
LoneHerm_ has joined #ruby
livcd has joined #ruby
dminuoso has joined #ruby
ur5us has quit [Remote host closed the connection]
<livcd> Hi guys. Why do you think Rubymotion is not more popular ?
finnnnnnnnnnn has joined #ruby
finnnnnnnnnnn has quit [Client Quit]
c0mrad3 has joined #ruby
ejnahc has quit [Ping timeout: 264 seconds]
Sashimi has quit [Client Quit]
ejnahc has joined #ruby
A_Drone_ has joined #ruby
ghr has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
<ICantCook> does that use Ruboto?
AndrewIsHere has quit [Ping timeout: 250 seconds]
sarlalian_ has quit [Ping timeout: 272 seconds]
Hounddog has joined #ruby
<ICantCook> I played around with Ruboto last year. Seemed clunky having to install the Ruboto app on the phone to get my app to work
watersoul_ has quit [Remote host closed the connection]
anisha has quit [Quit: This computer has gone to sleep]
watersoul has joined #ruby
<dminuoso> livcd: There is a long list of things that don't make it ideal, to buggy even.
Sashimi has joined #ruby
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sarlalian has joined #ruby
<ICantCook> yeah, unfortunately; Ruby seems to be getting niche
<dminuoso> livcd: Debugging RubyMotion applications is tricky and there are no tools to really help you, there are unfixed bugs where objects are GCed too early, etc.
<ICantCook> with the lack of support in AWS Lambda, lack of ML and polished mobile support
<shevy> sounds like a buggy software
aganov has joined #ruby
Madplatypus has joined #ruby
<dminuoso> livcd: Another thing, it cant hide things like Cocoa from you.
<dminuoso> For other things than quickly prototyping example software, I do not see RubyMotion to have a serious use in production apps.
A_Drone_ has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
Technodrome has quit [Ping timeout: 276 seconds]
vdamewood has joined #ruby
anisha has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
raeoks has joined #ruby
A_Drone_ has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
anisha has quit [Client Quit]
<dminuoso> jhass: Okay, I'm sold. Crystal is sexy.
anisha has joined #ruby
<dminuoso> Overloading is what convinced me to try out Crystal now. :)
xall_ has joined #ruby
Devalo has quit [Ping timeout: 276 seconds]
ghr has joined #ruby
jaguarmagenta has quit [Remote host closed the connection]
thoraxe has joined #ruby
Mon_Ouie has quit [Ping timeout: 244 seconds]
blackmesa has joined #ruby
LoneHerm_ has quit [Remote host closed the connection]
ghr has quit [Ping timeout: 240 seconds]
<livcd> dminuoso: Is it really that clunky ?
<dminuoso> livcd: Id say just give it a try. There is nothing wrong with it immediately.
<jhass> dminuoso: <3
<dminuoso> livcd: It took Trolltech and others over 25 years to produce a cross-platform framework that works reliably and feels right. RubyMotion is extremely new, so I guess I should be careful to judge it too early.
<dminuoso> (Qt)
ghr has joined #ruby
zacstewart has joined #ruby
solars has joined #ruby
A_Drone has joined #ruby
pawnbox_ has quit [Remote host closed the connection]
A_Drone_ has quit [Ping timeout: 252 seconds]
pawnbox has joined #ruby
antgel has joined #ruby
pawnbox has quit [Remote host closed the connection]
nankyokusei has joined #ruby
pawnbox has joined #ruby
zacstewart has quit [Ping timeout: 252 seconds]
A_Drone_ has joined #ruby
Mon_Ouie has joined #ruby
vdamewood has quit [Quit: Life beckons.]
tvw has joined #ruby
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
drewo has quit [Ping timeout: 272 seconds]
A_Drone has quit [Read error: Connection reset by peer]
Devalo has joined #ruby
nankyokusei has quit [Ping timeout: 258 seconds]
A_Drone_ has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
cyphase has quit [Ping timeout: 272 seconds]
cd-rum has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ghr has quit [Ping timeout: 240 seconds]
troulouliou_div2 has joined #ruby
cyphase has joined #ruby
AlexJakeGreen has joined #ruby
ghr has joined #ruby
A_Drone has quit [Ping timeout: 252 seconds]
ericlee has joined #ruby
A_Drone has joined #ruby
k3rn31 has quit [Quit: Computer has gone to sleep.]
ponga has joined #ruby
<ericlee> Hi, in Line #17 it is always failed and I'm sure the var "match" it will be 1. But why the statement is failed? https://paste.fedoraproject.org/392380/46891414/
ponga has quit [Client Quit]
<al2o3-cr> ericlee: match against string not integer
<ericlee> al2o3-cr, so how can I fix that?
CloCkWeRX has quit [Quit: Leaving.]
<al2o3-cr> if match == "1"
troulouliou_div2 has quit [Remote host closed the connection]
<ericlee> oh this I have tried, does not work/
<al2o3-cr> well then the match is not what you think it is
miskatonic has quit [Quit: miskatonic]
<ericlee> al2o3-cr, let me show u
ghr has quit [Ping timeout: 240 seconds]
<al2o3-cr> ok
<hanmac> ericlee: you need to strip it first before you compare it with "1"
k3rn31 has joined #ruby
<ericlee> hanmac, oh damn, the '\n'
<al2o3-cr> hanmac: good call
<hanmac> hm or use Integer() to transform it, but that might be not safe from crashs
iMadper has joined #ruby
multi_io has quit [Ping timeout: 272 seconds]
<dminuoso> ericlee: Here is a tip: Install pry, and then drop in a binding.pry at a code position where you are getting an error or unexpected behavior from.
<dminuoso> You can then interactively inspect the environment and related objects and try out what might be wrong with it.
<dminuoso> (You could also do this with plain irb if you wanted)
<shevy> like a doctor fixing patients!
multi_io has joined #ruby
blackgoat has quit [Ping timeout: 250 seconds]
ghr has joined #ruby
<peteretep> Are there other common ways - other than `rake test` to run a test suite made up of say RSpec and Test::Unit tests?
the_drow has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
troulouliou_div2 has joined #ruby
hk238 has quit [Quit: http://www.kvirc.net/ 4.9.1 Aria]
troulouliou_divn has joined #ruby
yfeldblum has quit [Ping timeout: 250 seconds]
A_Drone has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
<manveru> peteretep: you mean both at the same time?
<peteretep> Sure
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
<manveru> that's gonna be a bit difficult :)
<peteretep> Why?
<manveru> can you look at the test task?
troulouliou_div2 has quit [Ping timeout: 276 seconds]
armyriad has quit [Ping timeout: 240 seconds]
<peteretep> I guess my question really is: "Do people always rely on `rake` to run their test suites" and the answer seems to mostly be yes
edwinvdg_ has joined #ruby
<dminuoso> peteretep: I just use the rspec binstub, being completely ignorant about what it does.
<peteretep> Do you do that in Jenkins, too?
<peteretep> eg shell out to that as part of your build?
haxrbyte has quit [Read error: Connection reset by peer]
<dminuoso> I don't do Jenkins.
biberu has joined #ruby
haxrbyte has joined #ruby
ericsupreme has quit [Quit: Leaving]
moei has quit [Quit: Leaving...]
edwinvdgraaf has quit [Ping timeout: 240 seconds]
armyriad has joined #ruby
<peteretep> Man, Ruby is weird
<dminuoso> peteretep: You have no idea.
* peteretep is writing a comparative piece about Ruby/Python/Perl testing
<dminuoso> peteretep: Most of the quirks and weirdnesses are not very apparent though.
<dminuoso> My biggest headache came from a simple bug, where I accidentally used super instead of super().
<peteretep> I think there's this heirachy of Python -> Perl -> Ruby, where people think "there are some cool features in that language, but it's being used by KIDS"
<peteretep> Python is dull as all shit, but largely sensible
<peteretep> Perl has some cool features but encourages people to be less sensible
<peteretep> Ruby has some cooler features still, but WTF.
haxrbyte_ has joined #ruby
<dminuoso> What WTF are you getting from Ruby?
roshanavand has joined #ruby
<peteretep> Well the fact that there are 4 or 5 completely uninteroperable testing libraries
<dminuoso> Most of the quirks that I have seen are contributed to historical reasons and a tendency to keep backwards compatiblity high.
<peteretep> Python and Perl testing libraries put a large focus on interoperability
<dminuoso> peteretep: interoperability between what?
<peteretep> At its most basic level, let's say you've written a testing assertion that looks at - say - Levenstein distance between two strings
<peteretep> And you can say "If differences are > 5 then fail"
<peteretep> But you've also written some sensible debug stuff for it
<peteretep> In Ruby, you then have to integrate that assertion differently in to each testing library
<dminuoso> Different frameworks are used differently. I don't know what your point is.
<peteretep> in Perl, you'd get Test::Differences::Levenstein and Perl's Cucumber library would be able to use it, Perl's Capybara equivalent would be able to use it, Perl's RSpec library would be able to use it, Perl's xUnit library would be able to use it
<dminuoso> Would you try compiling Qt with Gtk header directories as your include directories? Probably not.
weaksauce has quit [Excess Flood]
<peteretep> You could run a test suite using the whole thing with the single unified test runner, and get the output as JUnit or HTML or anything else
<peteretep> Python is almost the same
haxrbyte has quit [Ping timeout: 276 seconds]
<peteretep> That's what I mean by interoperable
<dminuoso> peteretep: Im not sure how you see 4 or 5 testing libraries though.
kedare has joined #ruby
<dminuoso> Realistically there is only 2 (well 3 if you count test-unit) frameworks.
<peteretep> What do you think the 2 are?
<dminuoso> rspec and minitest?
<peteretep> Why wouldn't you include test-unit?
<dminuoso> It's not widely used.
frozengeek has joined #ruby
RegulationD has joined #ruby
frozengeek has quit [Remote host closed the connection]
yeticry has quit [Read error: Connection reset by peer]
<dminuoso> From the top off my head I can come up with only one well known project that uses it.
<manveru> all my projects use either rspec or bacon :)
<peteretep> Is bacon compatible with other RSpec tools?
<manveru> no
tmtwd has joined #ruby
<dminuoso> peteretep: bacon is a mini rspec clone.
<peteretep> I know
<manveru> you can make them compatible usually without much effort though
jaruga___ has joined #ruby
<peteretep> Let's say you've written a nice test summary tool that outputs HTML
jaruga___ is now known as jaruga____
<peteretep> If you want to use it with bacon, you have to write a special adaptor
DoubleMalt has joined #ruby
<manveru> of course
<peteretep> You say "of course", but that's not true for Python and Perl
<peteretep> Which is my point :-)
A_Drone has quit [Read error: Connection reset by peer]
<manveru> like you'd have to do if you want to use it with minitest, test::unit, or spinach...
<dminuoso> peteretep: If you feel like this could be a useful thing, then go write some adaptor library that lets you interface with any supported framework the way you like
<peteretep> manveru: yep
<manveru> for the web there's rack, but no such thing exists for testing
pandaant has joined #ruby
<peteretep> dminuoso: I suspect that ship has sailed, and there's too much code written to make it feasible
<manveru> which is sad, but not something i've spent more than a few hours on in the past years
Dimik-- has quit [Ping timeout: 260 seconds]
LoneHerm_ has joined #ruby
edwinvdg_ has quit [Remote host closed the connection]
<peteretep> Anyway, that's the Ruby WTF I had in mind :)
<manveru> hehe
RegulationD has quit [Ping timeout: 260 seconds]
<peteretep> What I have discovered is across all three languages, most developers don't really know how their testing tools work
<peteretep> And also don't have any visibility of how the testing tools in other languages work
<manveru> that's kinda sad indeed :|
Devalo has quit [Remote host closed the connection]
<peteretep> Which makes this a great basis for my MSc project :D
<manveru> maybe take a look at go and elixir testing too
<dminuoso> peteretep: That is not a Ruby WTF.
<manveru> they're kinda cool
<dminuoso> peteretep: That is a library WTF.
<dminuoso> peteretep: So place the blame where it belongs.
Couch has joined #ruby
<peteretep> The core team who added and removed test-unit like 10 times in the last 10 years? :D
yeticry has joined #ruby
<manveru> ?
<manveru> it's been in stdlib for as long as i can remember
<peteretep> Perhaps it's wrong
LoneHerm_ has quit [Ping timeout: 252 seconds]
zacstewart has joined #ruby
<peteretep> the source I gave claims it was then removed again
<manveru> that's not actually Test::Unit though, just the first time it was used inside ruby itself, afaik
<peteretep> but whatever
Terens has quit [Disconnected by services]
yeticry has quit [Remote host closed the connection]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
yeticry has joined #ruby
A_Drone has joined #ruby
<manveru> hmm
k3rn31 has quit [Quit: Computer has gone to sleep.]
<manveru> maybe that was in relation with minitest?
<manveru> pretty sure zenspider would know more
<manveru> i rather write my own testing lib before i'd use test::unit anyway...
zacstewart has quit [Ping timeout: 240 seconds]
Snowy has joined #ruby
devbug has quit [Quit: ZZZzzz…]
senayar has joined #ruby
senayar has quit [Changing host]
senayar has joined #ruby
armyriad has quit [Ping timeout: 240 seconds]
toretore has joined #ruby
ur5us has joined #ruby
matp has quit [Remote host closed the connection]
blackmesa has quit [Ping timeout: 252 seconds]
vondruch has quit [Ping timeout: 244 seconds]
blackgoat has joined #ruby
pawnbox has quit [Remote host closed the connection]
TheHodge has joined #ruby
armyriad has joined #ruby
A_Drone has quit [Remote host closed the connection]
tmtwd has quit [Ping timeout: 250 seconds]
A_Drone has joined #ruby
Mon_Ouie has quit [Ping timeout: 250 seconds]
rumia has left #ruby ["Leaving"]
vondruch has joined #ruby
Hyuk has quit [Quit: Textual IRC Client: www.textualapp.com]
aufi has joined #ruby
blackgoat has quit [Ping timeout: 272 seconds]
A_Drone has quit [Remote host closed the connection]
vondruch_ has joined #ruby
A_Drone has joined #ruby
ixti has joined #ruby
Es0teric has quit [Quit: Computer has gone to sleep.]
ixti has quit [Client Quit]
yfeldblum has joined #ruby
vondruch has quit [Ping timeout: 244 seconds]
saneax is now known as saneax_AFK
Mon_Ouie has joined #ruby
pawnbox has joined #ruby
DaniG2k has joined #ruby
blackgoat has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
moei has joined #ruby
haxrbyte_ has quit [Ping timeout: 272 seconds]
A_Drone_ has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
matp has joined #ruby
haxrbyte has joined #ruby
A_Drone_ has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
haxrbyte has quit [Remote host closed the connection]
haxrbyte has joined #ruby
A_Drone has quit [Read error: Connection reset by peer]
A_Drone has joined #ruby
Dimik has joined #ruby
sindork has quit [Ping timeout: 250 seconds]
blackmesa has joined #ruby
sindork has joined #ruby
wald0 has quit [Ping timeout: 260 seconds]
drewo has joined #ruby
blackgoat has quit [Ping timeout: 240 seconds]
Dimik has quit [Ping timeout: 250 seconds]
drewo has quit [Ping timeout: 250 seconds]
codecop has joined #ruby
blackmesa has quit [Ping timeout: 276 seconds]
blackmesa has joined #ruby
alfiemax has quit [Ping timeout: 258 seconds]
jaguarmagenta has joined #ruby
kedare_ has joined #ruby
haxrbyte has quit [Remote host closed the connection]
LoneHermit has joined #ruby
jaguarmagenta has quit [Ping timeout: 264 seconds]
haxrbyte has joined #ruby
kedare has quit [Ping timeout: 264 seconds]
urtokk has joined #ruby
rodorgas has quit [Quit: rodorgas]
LoneHermit has quit [Ping timeout: 258 seconds]
zacstewart has joined #ruby
A_Drone has quit [Remote host closed the connection]
A_Drone has joined #ruby
alfiemax has joined #ruby
workmad3 has joined #ruby
nankyokusei has joined #ruby
zacstewart has quit [Ping timeout: 258 seconds]
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
Mon_Ouie has quit [Ping timeout: 240 seconds]
A_Drone has quit [Ping timeout: 252 seconds]
G__ is now known as G
hubert has joined #ruby
nankyokusei has quit [Ping timeout: 260 seconds]
hubert is now known as Guest10812
Guest10812 is now known as mr_hubot
saneax_AFK is now known as saneax
blingrang has quit [Quit: WeeChat 1.3]
Mia has joined #ruby
Mia has quit [Changing host]
Mia has joined #ruby
tamole has joined #ruby
codecop has quit [Remote host closed the connection]
dkam has quit [Quit: Lingo: www.lingoirc.com]
<masterkorp> hello
iMadper has quit [Remote host closed the connection]
<al2o3-cr> o/
daffy_duck_3 has joined #ruby
AlexJakeGreen has joined #ruby
daffy_duck_2 has quit [Ping timeout: 252 seconds]
c0mrad3 has quit [Quit: Connection closed for inactivity]
A_Drone has joined #ruby
tris has quit [Ping timeout: 252 seconds]
tris has joined #ruby
mistermocha has joined #ruby
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
Mon_Ouie has joined #ruby
mistermocha has quit [Ping timeout: 244 seconds]
A_Drone has quit [Ping timeout: 252 seconds]
elaptics`away is now known as elaptics
drewo has joined #ruby
webus has joined #ruby
webus has quit [Client Quit]
webus has joined #ruby
sdothum has joined #ruby
A_Drone has joined #ruby
blackmesa has quit [Ping timeout: 272 seconds]
bnjf has quit [Ping timeout: 252 seconds]
drewo has quit [Ping timeout: 276 seconds]
mikecmpbll has joined #ruby
A_Drone has quit [Ping timeout: 244 seconds]
cgfbee has quit [Quit: cgfbee]
harfangk has quit [Quit: Textual IRC Client: www.textualapp.com]
A_Drone has joined #ruby
A_Drone has quit [Remote host closed the connection]
xall_ has quit [Ping timeout: 258 seconds]
tvw has quit [Ping timeout: 264 seconds]
A_Drone has joined #ruby
RegulationD has joined #ruby
k3dare has joined #ruby
troulouliou_divn has quit [Quit: Leaving]
blackmesa has joined #ruby
cgfbee has joined #ruby
A_Drone has quit [Ping timeout: 264 seconds]
kedare_ has quit [Ping timeout: 264 seconds]
RegulationD has quit [Ping timeout: 240 seconds]
LoneHermit has joined #ruby
flashpoint9 has joined #ruby
HashNuke___ is now known as HashNuke
blackmesa has quit [Ping timeout: 258 seconds]
xall_ has joined #ruby
LoneHermit has quit [Ping timeout: 240 seconds]
zacstewart has joined #ruby
mistermocha has joined #ruby
zacstewart has quit [Ping timeout: 252 seconds]
chosen1 has joined #ruby
Silthias has joined #ruby
mistermocha has quit [Ping timeout: 264 seconds]
chosen1x has quit [Ping timeout: 258 seconds]
andikr has joined #ruby
Silthias1 has quit [Ping timeout: 250 seconds]
Wildfyr has joined #ruby
Wildfyr has quit [Changing host]
Wildfyr has joined #ruby
My_Hearing has joined #ruby
Mon_Ouie has quit [Disconnected by services]
My_Hearing is now known as Mon_Ouie
vdamewood has joined #ruby
aazsdk has joined #ruby
aazsdk has quit [Remote host closed the connection]
Guest___ has joined #ruby
k3rn31 has joined #ruby
astrobu__ has quit [Remote host closed the connection]
k3dare is now known as kedare
dionysus69 has quit [Ping timeout: 240 seconds]
johnmilton has joined #ruby
marr has joined #ruby
chosen1_ has joined #ruby
mdw has joined #ruby
aazsdk has joined #ruby
Jet4Fire has joined #ruby
skade has joined #ruby
chosen1 has quit [Ping timeout: 250 seconds]
Juanchito has joined #ruby
Guest___ has quit [Quit: Textual IRC Client: www.textualapp.com]
anisha has quit [Ping timeout: 258 seconds]
drewo has joined #ruby
rodfersou has joined #ruby
kermal has joined #ruby
<kermal> Hi, when trying to call "Hash.new" I run into a NPE (ailure/Error: Unable to find org.jruby.ir.operands.CurrentScope.retrieve(CurrentScope.java to read failed line
<kermal> Java::JavaLang::NullPointerException)"
<shevy> is this a jruby problem, in this case you should try on #jruby possibly so
AndrewIsHere has joined #ruby
<kermal> alright, thanks
DaniG2k has quit [Quit: leaving]
drewo has quit [Ping timeout: 240 seconds]
GodFather has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
AndrewIsHere has quit [Ping timeout: 250 seconds]
blackgoat has joined #ruby
anisha has joined #ruby
dstarh has joined #ruby
stardiviner has joined #ruby
edwinvdgraaf has joined #ruby
yfeldblum has quit [Ping timeout: 250 seconds]
yfeldblum has joined #ruby
dstarh has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
AlexJakeGreen has joined #ruby
stardiviner has left #ruby [#ruby]
AlexJakeGreen has quit [Client Quit]
dionysus69 has joined #ruby
jaguarmagenta has joined #ruby
kermal has quit [Quit: Leaving]
Snowy has quit [Quit: ragequit]
JeanCarloMachado has joined #ruby
mistermocha has joined #ruby
jaguarmagenta has quit [Ping timeout: 260 seconds]
blackmesa has joined #ruby
mistermocha has quit [Ping timeout: 240 seconds]
zacstewart has joined #ruby
hanmac has quit [Ping timeout: 258 seconds]
blackmesa has quit [Ping timeout: 276 seconds]
nankyokusei has joined #ruby
ur5us has quit [Remote host closed the connection]
zacstewart has quit [Ping timeout: 276 seconds]
nankyokusei has quit [Ping timeout: 250 seconds]
madgen has joined #ruby
LoneHerm_ has joined #ruby
codecop has joined #ruby
ldnunes has joined #ruby
nettoweb has joined #ruby
xall_ has quit [Ping timeout: 264 seconds]
hanmac has joined #ruby
karapetyan has joined #ruby
mdw has quit [Quit: Sleeping Zzzzz]
drewo has joined #ruby
hk238 has joined #ruby
LoneHerm_ has quit [Remote host closed the connection]
karapetyan has quit [Ping timeout: 258 seconds]
webus has quit [Quit: goodbye]
AngryBuzzy has joined #ruby
k3rn31 has quit [Quit: Computer has gone to sleep.]
ghr has quit [Ping timeout: 240 seconds]
drewo has quit [Ping timeout: 264 seconds]
umdstu has joined #ruby
ghr has joined #ruby
conta1 has joined #ruby
conta has quit [Ping timeout: 252 seconds]
conta1 is now known as conta
nando293921 has joined #ruby
AlexJakeGreen has joined #ruby
pdoherty has joined #ruby
AlexJakeGreen has quit [Client Quit]
karapetyan has joined #ruby
eizua has joined #ruby
nando293921 has quit [Ping timeout: 250 seconds]
nando293921 has joined #ruby
nando293921 has quit [Client Quit]
karapety_ has joined #ruby
AlexJakeGreen has joined #ruby
karapetyan has quit [Ping timeout: 258 seconds]
jmignault has joined #ruby
nando293921 has joined #ruby
ixti has joined #ruby
karapety_ has quit [Remote host closed the connection]
ixti has quit [Client Quit]
yfeldblum has quit [Ping timeout: 250 seconds]
karapetyan has joined #ruby
ponga has joined #ruby
synthroid has joined #ruby
AngryBuzzy has quit [Quit: This computer has gone to sleep]
RegulationD has joined #ruby
raeoks has quit [Quit: Textual IRC Client: www.textualapp.com]
yfeldblum has joined #ruby
lxsameer has quit [Ping timeout: 276 seconds]
nando293921 has quit [Ping timeout: 272 seconds]
RegulationD has quit [Ping timeout: 276 seconds]
blackmesa has joined #ruby
Snowy has joined #ruby
lxsameer has joined #ruby
GNUYawk has quit [Ping timeout: 264 seconds]
ElFerna has joined #ruby
blackmesa has quit [Ping timeout: 250 seconds]
skade has joined #ruby
ziyan_ has joined #ruby
skade has quit [Client Quit]
<ziyan_> Hi there. I am wondering if there is a way to assign in an if condition and use it in as a return. Ex: `a = { 'new' => 10, 'used' => 0 }; %w(new used).map{ |i| val if (val = a[i]) > 0 }`
c355e3b has joined #ruby
<shevy> hmm
<shevy> I have not tested it but this should work right ziyan_?
<jhass> ziyan_: should work, weird way to write .values.select {|v| v > 0 } though
<dminuoso> jhass: Well, it's almost the same. This will leave nil for the elements less than 0.
<dminuoso> But I just assume that your solution is what he actually wanted.
<ziyan_> shevy: jhass: i get this error 'undefined local variable or method `val' for main:Object' (just tried it in the console)
<dminuoso> ziyan_: yes, that is a result of how variables are implemented in Ruby.
<dminuoso> ziyan_: A variable is only a variable if an assignment to it appears lexigraphically first.
<jhass> ah, right
<ziyan_> dminuoso: makes sense, thought as much
<ziyan_> thanks a lot
<jhass> ziyan_: does that actually resemble your actual code though? there's likely a nicer way
<ziyan_> jhass: that is not my actual code. i think you are saying about select, goign to give it a try
<chrisseaton> Anyone interested in JRuby+Truffle? Like talk on Graal (the wider ecosystem around it) about to start here https://ventotene.conf.meetecho.com/room2/
flashpoint9 has quit [Remote host closed the connection]
<chrisseaton> Live talk, not like talk
<jhass> ziyan_: well, if you share your actual input(s) and the desired output we might find something nice ;)
<dminuoso> ziyan_: You can use a little trick though by specifying val to be a block parameter.
<dminuoso> i.e. .map { |i, v| v if (v = a[i]) > 0 }
<jhass> .map {|i; v| } rather, the way to declare block locals
<dminuoso> chrisseaton: Expected duration?
hutch34 has joined #ruby
<ziyan_> i was going to test it before i wrote, just was curioud
<ziyan_> dminuoso: jhass: will give it a look, thanks
<ziyan_> works, great!!! thanks guys
pdoherty has quit [Ping timeout: 276 seconds]
swills has quit [Ping timeout: 240 seconds]
drewo has joined #ruby
<chrisseaton> dminuoso: 30 mins I guess
aazsdk has quit [Quit: aazsdk]
<jhass> ziyan_: I still think it's ugly though ;)
<dminuoso> chrisseaton: Fair enough. By the way, we talked about JIT and some project you were working on a while ago.
<dminuoso> How is that going?
<chrisseaton> dminuoso: had some bigger fish to fry for a while, still working on it though
<dminuoso> Very well, Ill stay tuned then. :)
JakFrist has joined #ruby
tamole has quit [Quit: away]
cd-rum has joined #ruby
ElFerna has quit [Ping timeout: 260 seconds]
drewo has quit [Ping timeout: 252 seconds]
blackgoat has quit [Quit: WeeChat 1.5]
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Madplatypus has quit [Quit: Connection closed for inactivity]
cd-rum has quit [Client Quit]
matp has quit [Remote host closed the connection]
jmignault has quit [Read error: Connection reset by peer]
Macaveli has quit [Ping timeout: 240 seconds]
matp has joined #ruby
mattwashere has joined #ruby
alfiemax has quit [Ping timeout: 240 seconds]
karapetyan has quit [Remote host closed the connection]
troulouliou_div2 has joined #ruby
andikr has quit [Remote host closed the connection]
AndrewIsHere has joined #ruby
jishankai has quit [Ping timeout: 258 seconds]
<ziyan_> jhass: ha ha, fortunately i didn't need it, just a `map` and a `compact`.
* jhass still is in the select.map camp
Macaveli has joined #ruby
eljimbo has quit [Quit: This computer has gone to sleep]
<ziyan_> this is what i ended doing... `%w(new used rent).map{ |condition, price| condition if rush.send("#{ condition }_price") > 0 }.compact`. Given an object has methods like 'new_price' 'used_price' etc... I need the 'conditions' (ex: new, used) etc which have a price > 0
<ziyan_> jhass: ^^
<dminuoso> ziyan_: So yes. use .select
AndrewIsHere has quit [Ping timeout: 250 seconds]
tamole has joined #ruby
<jhass> what's with the , price?
xall_ has joined #ruby
<jhass> %w(new used rent).select {|condition| rush.public_send("#{condition}_price") }
<jhass> are new_price, used_price, rent_price implemented manually or backed by a hash or similar?
<ziyan_> jhass: its a product (AR object) record.
<jhass> %w(new used rent).select {|condition| rush["#{condition}_price"] } then
Macaveli has quit [Ping timeout: 244 seconds]
<ziyan_> let me try,
ChiefAlexander has joined #ruby
chip_ has joined #ruby
<dminuoso> ziyan_: It's cleaner to simply use %i(new_price used_price rent_price).select { |c| rush.public_send(c) }
troulouliou_div2 has quit [Ping timeout: 276 seconds]
<jhass> s/public_send/[]/
<dminuoso> Yeah.
karapetyan has joined #ruby
<dminuoso> Either way, this weird string interpolation is unnecessary and makes it less readable.
ramortegui has joined #ruby
ericlee has quit [Ping timeout: 250 seconds]
synthroi_ has joined #ruby
xall_ has quit [Ping timeout: 260 seconds]
synthro__ has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
fmcgeough has joined #ruby
synthroid has quit [Ping timeout: 264 seconds]
<ziyan_> dminuoso: Thanks, looks nice (y), learnt some new stuff today. the fields are defaulted to 0, and 0 is evaluated kind of true so had to do a comparison there. `%i(new_price used_price rent_price).select { |c| rush.public_send(c) > 0 }`
synthroi_ has quit [Ping timeout: 258 seconds]
<dminuoso> ziyan_: Like jhass said, %w(new_price used_price rent_price).select { |c| rush[c] > 0 } is even cleaner.
codecop has quit [Remote host closed the connection]
jaguarmagenta has joined #ruby
speakingcode has joined #ruby
nerium has joined #ruby
isberg has joined #ruby
ekinmur has joined #ruby
yfeldblum has quit [Ping timeout: 250 seconds]
jaguarmagenta has quit [Ping timeout: 276 seconds]
hutch34 has quit [Ping timeout: 240 seconds]
dvinciguerra_ has joined #ruby
troulouliou_div2 has joined #ruby
Wildfyr has quit [Ping timeout: 258 seconds]
conta1 has joined #ruby
yfeldblum has joined #ruby
<dminuoso> chrisseaton: That was a great and informative talk, thank you. Now that I have a rough idea of what graal/truffle is - I am genuinely interested.
blackmesa has joined #ruby
conta has quit [Ping timeout: 240 seconds]
conta1 is now known as conta
aegis3121 has joined #ruby
mikejw has joined #ruby
<mikejw> mailcatcher doens't seem to run properly on port 25
<mikejw> *doesn't
<mikejw> I'm getting /usr/lib/ruby/2.1.0/net/smtp.rb:541:in `initialize': Connection refused - connect(2) for "127.0.0.1" port 1025 (Errno::ECONNREFUSED) from /usr/lib/ruby/2.1.0/net/smtp.rb:541:in `open'
zacstewart has joined #ruby
<jhass> 1025 != 25 ?
<mikejw> even though I'm starting mailcatcher with --smtp-port 25
<mikejw> php is configured to connect to sendmail on port 25
<jhass> what exactly is producing that error message?
<mikejw> and I'm using sendmail_path = /usr/bin/env catchmail -f --smtp-port 25 some@cat.example.org
conta1 has joined #ruby
nankyokusei has joined #ruby
<mikejw> the error is coming through the apache logs
yadobujo has quit [Remote host closed the connection]
bkxd has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
malconis has joined #ruby
aupadhye has quit [Ping timeout: 244 seconds]
<jhass> -f expects an argument
conta has quit [Ping timeout: 264 seconds]
conta1 is now known as conta
malconis has quit [Remote host closed the connection]
chip_ has quit [Ping timeout: 240 seconds]
mostlybadfly has joined #ruby
yadobujo has joined #ruby
skade has joined #ruby
zacstewart has quit [Ping timeout: 252 seconds]
<mikejw> ok it's working
<mikejw> thanks
malconis has joined #ruby
aupadhye has joined #ruby
nankyokusei has quit [Ping timeout: 272 seconds]
rodorgas has joined #ruby
bkxd has quit [Ping timeout: 258 seconds]
vuoto has joined #ruby
ericsupreme has joined #ruby
drewo has joined #ruby
conta1 has joined #ruby
karapetyan has quit [Remote host closed the connection]
zacstewart has joined #ruby
conta has quit [Ping timeout: 260 seconds]
conta1 is now known as conta
A_Drone has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
drewo has quit [Ping timeout: 244 seconds]
karapetyan has joined #ruby
A_Drone has quit [Ping timeout: 264 seconds]
vuoto has quit [Remote host closed the connection]
swills has joined #ruby
SilverKey has joined #ruby
vuoto has joined #ruby
vuoto has quit [Remote host closed the connection]
vuoto has joined #ruby
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
jegarcia has joined #ruby
karapetyan has quit [Remote host closed the connection]
<shevy> ruby ruby rbuy
karapetyan has joined #ruby
<shevy> with typo!
AlexJakeGreen has joined #ruby
howdoi has joined #ruby
isberg has quit [Quit: I'm out]
nerium has quit [Quit: nerium]
Yxhuvud has quit [Read error: Connection reset by peer]
alfiemax has joined #ruby
Yxhuvud has joined #ruby
bnjf has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
l4v2 has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
noregret has joined #ruby
<noregret> how i can index a byte string? e.g. str.index("PK\x01\x02") is failing
floatingpoint has joined #ruby
hutch34 has joined #ruby
xall_ has joined #ruby
nerium has joined #ruby
isberg has joined #ruby
xall_ has quit [Ping timeout: 250 seconds]
ericsupreme has quit [Quit: Leaving]
Bish has quit [Ping timeout: 240 seconds]
nmollerup has joined #ruby
Bish has joined #ruby
GodFather has quit [Ping timeout: 276 seconds]
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
<jhass> failing how?
<jhass> >> "abPK\x01\x02".index("PK\x01\x02")
<ruby[bot]> jhass: # => 2 (https://eval.in/607972)
flashpoint9 has joined #ruby
<noregret> jhass: no implicit conversion of Fixnum into String
isberg has quit [Quit: I'm out]
nmollerup has quit [Quit: Leaving.]
nerium has quit [Quit: nerium]
<jhass> I don't think that error comes from the code you posted
craigp has quit [Ping timeout: 250 seconds]
<noregret> ok, let me check
Bish has quit [Ping timeout: 240 seconds]
aupadhye has quit [Ping timeout: 258 seconds]
karapetyan has quit [Remote host closed the connection]
jhack has joined #ruby
<noregret> oops, nevermind =)
Bish has joined #ruby
isberg has joined #ruby
eljimbo has joined #ruby
shinnya has joined #ruby
flashpoint9 has quit [Ping timeout: 258 seconds]
RegulationD has joined #ruby
AlexJakeGreen has joined #ruby
karapetyan has joined #ruby
whathappens has joined #ruby
the_drow has quit [Quit: Leaving]
dennisvennink has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
AlexJakeGreen has quit [Client Quit]
vuoto has quit [Remote host closed the connection]
vuoto has joined #ruby
ChiefAlexander has quit [Remote host closed the connection]
agent_white has joined #ruby
karapetyan has quit [Remote host closed the connection]
whathappens has quit [Ping timeout: 250 seconds]
RegulationD has quit [Ping timeout: 250 seconds]
pdoherty has joined #ruby
karapetyan has joined #ruby
pdoherty has quit [Max SendQ exceeded]
pdoherty has joined #ruby
pdoherty has quit [Max SendQ exceeded]
pdoherty has joined #ruby
mattwashere has quit [Remote host closed the connection]
pawnbox has quit [Remote host closed the connection]
CodingWolf has joined #ruby
karapetyan has quit [Remote host closed the connection]
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby
blackmesa has joined #ruby
vuoto has quit [Remote host closed the connection]
vuoto has joined #ruby
anisha has quit [Ping timeout: 252 seconds]
anisha has joined #ruby
karapetyan has joined #ruby
Silthias has quit [Ping timeout: 260 seconds]
isberg has quit [Remote host closed the connection]
CodingWolf has quit [Ping timeout: 240 seconds]
zrl has quit [Max SendQ exceeded]
z3uS has quit [Max SendQ exceeded]
kriskropd has quit [Max SendQ exceeded]
zenlot has quit [Max SendQ exceeded]
MissionCritical has quit [Max SendQ exceeded]
johnny56_ has quit [Max SendQ exceeded]
Rabbit__ has quit [Max SendQ exceeded]
olivierjanss has quit [Max SendQ exceeded]
karapetyan has quit [Remote host closed the connection]
braderhart has quit [Max SendQ exceeded]
ifsp has quit [Max SendQ exceeded]
Guest4184_______ has quit [Max SendQ exceeded]
Silthias has joined #ruby
zenlot has joined #ruby
bedouin has quit [Max SendQ exceeded]
dn` has quit [Max SendQ exceeded]
ekinmur has joined #ruby
karapetyan has joined #ruby
karapetyan has quit [Remote host closed the connection]
drewo has joined #ruby
hays has quit [Max SendQ exceeded]
hays has joined #ruby
yadobujo has quit [Remote host closed the connection]
zenlot has quit [Max SendQ exceeded]
e4xit has quit [Max SendQ exceeded]
GodFather has joined #ruby
Es0teric has joined #ruby
johnny56_ has joined #ruby
isberg has joined #ruby
zenlot has joined #ruby
yadobujo has joined #ruby
braderhart has joined #ruby
braderhart has quit [Changing host]
braderhart has joined #ruby
blackmesa has quit [Ping timeout: 260 seconds]
pawnbox has joined #ruby
ifsp has joined #ruby
aryaching has joined #ruby
polysics has joined #ruby
karapetyan has joined #ruby
zrl has joined #ruby
olivierjanss has joined #ruby
Bish has quit [Ping timeout: 276 seconds]
Guest4184_______ has joined #ruby
<agent_white> Mornin folks
dminuoso has quit [Ping timeout: 240 seconds]
dn` has joined #ruby
bedouin has joined #ruby
vuoto_ has joined #ruby
AlexJakeGreen has joined #ruby
Snowy is now known as snory
Bish has joined #ruby
drewo has quit [Ping timeout: 258 seconds]
Rabbit__ has joined #ruby
yadobujo has quit [Ping timeout: 240 seconds]
pawnbox_ has joined #ruby
isberg has quit [Quit: I'm out]
pawnbox has quit [Read error: Connection reset by peer]
z3uS has joined #ruby
dminuoso has joined #ruby
karapetyan has quit [Remote host closed the connection]
underplank has joined #ruby
iceden has joined #ruby
MissionCritical has joined #ruby
<shevy> agent_white! you have come to rescue us
* agent_white puts on cape, hands shevy cape
SilverKey has quit [Quit: Halted.]
<shevy> is this where I open the cape
rippa has joined #ruby
AngryBuzzy has joined #ruby
flashpoint9 has joined #ruby
e4xit has joined #ruby
LvcasX1 has joined #ruby
Guest60828 has quit [Ping timeout: 250 seconds]
dionysus69 has quit [Ping timeout: 244 seconds]
mistermocha has joined #ruby
Terens has joined #ruby
Guest60828 has joined #ruby
flashpoint9 has quit [Ping timeout: 250 seconds]
urtokk has quit [Quit: WeeChat 1.5]
Akuma has joined #ruby
LvcasX1 has quit [Remote host closed the connection]
AngryBuzzy has quit [Quit: This computer has gone to sleep]
rann has quit [Remote host closed the connection]
mistermocha has quit [Ping timeout: 260 seconds]
kab has joined #ruby
underplank has quit [Quit: underplank]
synthro__ has quit [Remote host closed the connection]
speakingcode has quit [Remote host closed the connection]
isberg has joined #ruby
roshanavand has quit [Ping timeout: 258 seconds]
hutch34_ has joined #ruby
hutch34 has quit [Ping timeout: 272 seconds]
dionysus69 has joined #ruby
dminuoso has quit [Remote host closed the connection]
mattwashere has joined #ruby
ChiefAlexander has joined #ruby
Devalo has joined #ruby
`tim` has joined #ruby
madhatter has quit [Ping timeout: 252 seconds]
conta has quit [Ping timeout: 240 seconds]
yadobujo has joined #ruby
polysics has quit []
yadobujo_ has joined #ruby
jtdowney has quit [Quit: ZNC]
jtdowney has joined #ruby
jtdowney has quit [Changing host]
jtdowney has joined #ruby
yadobujo_ is now known as kseftylismenos
dunpeal has joined #ruby
<dunpeal> Is there a syntax like %w() for Sets?
mistermocha has joined #ruby
vuoto has quit [Remote host closed the connection]
vuoto_ has quit [Remote host closed the connection]
vuoto has joined #ruby
<jhass> nope
<jhass> isn't Set even standard library still even, not core?
yadobujo has quit [Ping timeout: 272 seconds]
karapetyan has joined #ruby
huesaurus has joined #ruby
<huesaurus> hello
<jhass> hi
<huesaurus> any one has any experience with sensu plugins ?
<jhass> ?anyone
<ruby[bot]> Just ask your question, if anyone has, is or can, they will respond.
karapetyan has quit [Remote host closed the connection]
giz|work has joined #ruby
<huesaurus> im trying to use the following plugin to pull JSON values https://github.com/sensu-plugins/sensu-plugins-http/blob/master/bin/metrics-http-json.rb and it gives me thef ollowing error Check failed to run: undefined method `each' for nil:NilClass,
Bish has quit [Ping timeout: 272 seconds]
floatingpoint has quit [Quit: Goodnight]
Bish has joined #ruby
polishdub has joined #ruby
mistermocha has quit [Ping timeout: 240 seconds]
RegulationD has joined #ruby
isberg has quit [Remote host closed the connection]
isberg has joined #ruby
<jhass> please gist the full error output
<jhass> ?gist
<ruby[bot]> https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
solars has quit [Ping timeout: 258 seconds]
karapetyan has joined #ruby
RegulationD has quit [Ping timeout: 258 seconds]
skade has joined #ruby
drewo has joined #ruby
flashpoint9 has joined #ruby
edwinvdgraaf has quit [Ping timeout: 276 seconds]
aganov has quit [Quit: Leaving]
yfeldblum has quit [Remote host closed the connection]
synthroid has joined #ruby
<jhass> huesaurus: it looks like config[:root] does not return a valid key for the response at config[:url]
ccooke has quit [Ping timeout: 276 seconds]
ccooke has joined #ruby
yfeldblum has joined #ruby
blackmesa has joined #ruby
<jhass> double check you specified the right root key
mattwashere has quit [Remote host closed the connection]
mattwashere has joined #ruby
kseftylismenos is now known as tapa
drewo has quit [Ping timeout: 264 seconds]
JeanCarloMachado has quit [Remote host closed the connection]
nankyokusei has joined #ruby
ur5us has joined #ruby
singalaut is now known as Guest28417
Guest28417 has quit [Killed (barjavel.freenode.net (Nickname regained by services))]
dminuoso has joined #ruby
singalaut has joined #ruby
<huesaurus> jhass, here's what happens when I specify a root key, it returns the value along with an error https://gist.github.com/anonymous/2d6cce222de679a32fbded82d068e988
tamole has quit [Quit: bye]
<huesaurus> 4 is the correct value, is it because it's a string ?
<jhass> maybe the plugin is not the right one?
rodorgas has quit [Quit: rodorgas]
<jhass> for the structure you have
skade has quit [Quit: Computer has gone to sleep.]
<jhass> it expects something like {"foo": {"keys": "and", "values": "you", "want": "to return"}, "possibly": "other stuff"}
<jhass> there root key would be foo
blackmesa has quit [Ping timeout: 276 seconds]
<huesaurus> oh, I don't have a root key like "foo", just {"keys": "and", "values": "you", "want": "to return"} and when I did a mock test with a root key it also returned with an error
nankyokusei has quit [Ping timeout: 244 seconds]
cdg has joined #ruby
SilverKey has joined #ruby
<jhass> well, it certainly can't work with a flat key
<huesaurus> I see
ur5us has quit [Ping timeout: 272 seconds]
<jhass> in the last line metrics is the parsed json, it unconditionally accesses into that with a root key, "value" if none given
atom_ has quit [Ping timeout: 276 seconds]
amclain has joined #ruby
workmad3_ has joined #ruby
grill has joined #ruby
<huesaurus> makes sense, but I think this one should work with flat key https://github.com/sensu-plugins/sensu-plugins-http/blob/master/bin/metrics-http-json.rb
<huesaurus> it just expects key/values
<jhass> yes, though you have to list all explicitly
<jhass> comma separated
workmad3 has quit [Ping timeout: 250 seconds]
Vingador has joined #ruby
JeanCarloMachado has joined #ruby
isberg has quit [Quit: I'm out]
mattwashere has quit [Remote host closed the connection]
<huesaurus> oh metricname::jsonkey ?
<jhass> yes
troulouliou_div2 has quit [Ping timeout: 276 seconds]
skade has joined #ruby
<huesaurus> weird, it just returns nothing :/
madgen has quit [Ping timeout: 240 seconds]
mattwashere has joined #ruby
<jhass> probably wrong parameters ;)
workmad3_ has quit [Ping timeout: 258 seconds]
<huesaurus> right
tophat has joined #ruby
DaniG2k has joined #ruby
bathtub_shark has quit [Ping timeout: 264 seconds]
<huesaurus> guess it also needs a root key, Check failed to run: undefined method `each' for "3":String,
mostlybadfly has quit [Quit: Connection closed for inactivity]
workmad3 has joined #ruby
<jhass> shouldn't
AndrewIsHere has joined #ruby
<jhass> only if you give object
<jhass> but it's optional
<huesaurus> oh
<jhass> or I guess that was the intention
<jhass> the code is quite terrible tbh
dminuoso has quit [Read error: Connection reset by peer]
<huesaurus> currently that's what i'm passing it for a test /opt/sensu/embedded/bin/metrics-http-json.rb -u 'http://echo.jsontest.com/key/3/one/4' -s hostname.name -m 'ametric::key,one'
<huesaurus> yeah :/
<jhass> I think there's a missing else between line 84 and 85
<huesaurus> lol
xall_ has joined #ruby
[Butch] has joined #ruby
drewo has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
rodorgas has joined #ruby
PostApo has joined #ruby
PostApo has quit [Client Quit]
xall_ has quit [Ping timeout: 272 seconds]
troulouliou_div2 has joined #ruby
postapocallyptic has quit [Ping timeout: 264 seconds]
isberg has joined #ruby
mwlang has quit [Quit: mwlang]
DaniG2k has quit [Quit: leaving]
Es0teric has quit [Ping timeout: 240 seconds]
DaniG2k has joined #ruby
davedev24 has joined #ruby
mistermocha has joined #ruby
davedev24 has quit [Read error: Connection reset by peer]
davedev2_ has quit [Ping timeout: 258 seconds]
bnjf has quit [Ping timeout: 264 seconds]
aep-shoutlet has joined #ruby
davedev24 has joined #ruby
<shevy> saurier always go via if clauses, never via the else clauses
<shevy> that is why they went extinct
Es0teric has joined #ruby
huesaurus has quit [Quit: Ex-Chat]
kedare has quit [Quit: Leaving]
dennisvennink has joined #ruby
karapetyan has quit [Remote host closed the connection]
aryaching has quit [Ping timeout: 240 seconds]
whathapp_ has joined #ruby
whathapp_ has quit [Read error: Connection reset by peer]
AnoHito has quit [Ping timeout: 272 seconds]
karapetyan has joined #ruby
SilverKey has quit [Quit: Halted.]
SilverKey has joined #ruby
whathappens has joined #ruby
karapetyan has quit [Remote host closed the connection]
treaki__ has quit [Ping timeout: 276 seconds]
LoneHermit has joined #ruby
harfangk has joined #ruby
aegis3121 has quit [Ping timeout: 250 seconds]
karapetyan has joined #ruby
Es0teric has quit [Ping timeout: 240 seconds]
karapetyan has quit [Remote host closed the connection]
`tim` has quit [Ping timeout: 276 seconds]
rodfersou is now known as rodfersou|lunch
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
AnoHito has joined #ruby
madgen has joined #ruby
dminuoso has joined #ruby
mark_66 has quit [Quit: Leaving.]
kab has quit [Quit: Leaving]
karapetyan has joined #ruby
DaniG2k has quit [Quit: leaving]
macsteps has joined #ruby
JakFrist has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Es0teric has joined #ruby
omphe has joined #ruby
isberg has quit [Remote host closed the connection]
troulouliou_div2 has quit [Ping timeout: 276 seconds]
Silthias has quit [Quit: Leaving.]
Silthias has joined #ruby
mistermocha has quit [Remote host closed the connection]
iceden has quit [Ping timeout: 258 seconds]
RegulationD has joined #ruby
senayar has quit []
Ishido has joined #ruby
karapetyan has quit [Remote host closed the connection]
rodorgas has quit [Quit: rodorgas]
macsteps has quit [Remote host closed the connection]
iceden has joined #ruby
karapetyan has joined #ruby
astrobunny has quit [Read error: Connection reset by peer]
rodorgas has joined #ruby
astrobunny has joined #ruby
fredolinhares has joined #ruby
xue has quit [Ping timeout: 240 seconds]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
mistermocha has joined #ruby
troulouliou_div2 has joined #ruby
blackmesa has joined #ruby
Cohedrin has joined #ruby
xue has joined #ruby
zacts has quit [Ping timeout: 250 seconds]
SCHAAP137 has joined #ruby
pawnbox_ has quit [Remote host closed the connection]
Couch has quit [Ping timeout: 272 seconds]
Es0teric has quit [Quit: Computer has gone to sleep.]
yfeldblum has quit [Remote host closed the connection]
aryaching has joined #ruby
yfeldblum has joined #ruby
dennisvennink has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rbr has quit [Ping timeout: 252 seconds]
pawnbox has joined #ruby
wald0 has joined #ruby
ramfjord has joined #ruby
roamingdog has joined #ruby
mikecmpbll has quit [Ping timeout: 240 seconds]
aryaching has quit [Ping timeout: 244 seconds]
karapetyan has quit [Remote host closed the connection]
mistermo_ has joined #ruby
mistermocha has quit [Ping timeout: 264 seconds]
snory has quit [Remote host closed the connection]
kriskropd has joined #ruby
mistermo_ has quit [Ping timeout: 250 seconds]
craigp has joined #ruby
LoneHermit has quit [Remote host closed the connection]
rodorgas has quit [Quit: rodorgas]
Diabolik has quit [Ping timeout: 264 seconds]
LoneHerm_ has joined #ruby
LoneHerm_ has quit [Remote host closed the connection]
vuoto has quit [Remote host closed the connection]
SilverKey has quit [Quit: Halted.]
ziyan_ has quit [Ping timeout: 250 seconds]
karapetyan has joined #ruby
spiette has joined #ruby
ziyan_ has joined #ruby
antgel has quit [Ping timeout: 264 seconds]
duoi has quit [Excess Flood]
aryaching has joined #ruby
duoi has joined #ruby
RegulationD has quit [Remote host closed the connection]
drewo has quit [Ping timeout: 260 seconds]
zacts has joined #ruby
dn` has quit [Quit: dn`]
arnonhongklay has joined #ruby
arnonhongklay has quit [Remote host closed the connection]
mistermocha has joined #ruby
karapetyan has quit [Remote host closed the connection]
harfangk has quit [Quit: Textual IRC Client: www.textualapp.com]
tomchapin has joined #ruby
strongcode has joined #ruby
LoneHerm_ has joined #ruby
marxarelli has joined #ruby
macsteps has joined #ruby
mistermo_ has joined #ruby
mattwashere has quit [Remote host closed the connection]
jackjackdripper has joined #ruby
mattwashere has joined #ruby
flashpoint9 has quit [Remote host closed the connection]
mistermocha has quit [Ping timeout: 260 seconds]
harfangk has joined #ruby
Sashimi has quit [Quit: Textual IRC Client: www.textualapp.com]
nennes has joined #ruby
troulouliou_div2 has quit [Ping timeout: 276 seconds]
marxarelli has quit [Quit: Textual IRC Client: www.textualapp.com]
omphe has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
minimalism has quit [Quit: minimalism]
jhack_ has joined #ruby
jhack has quit [Ping timeout: 244 seconds]
jhack_ is now known as jhack
dennisvennink has joined #ruby
elaptics is now known as elaptics`away
ponga has quit [Quit: Connection closed for inactivity]
araujo has joined #ruby
aufi has quit [Ping timeout: 264 seconds]
firstdayonthejob has joined #ruby
jaguarmagenta has joined #ruby
jaguarma_ has joined #ruby
MrBusiness2 has quit [Ping timeout: 240 seconds]
Emmanuel_Chanel has quit [Quit: Leaving]
dionysus69 has quit [Remote host closed the connection]
dionysus69 has joined #ruby
leea has joined #ruby
Wsewolod has joined #ruby
pawnbox has quit [Remote host closed the connection]
jaguarmagenta has quit [Ping timeout: 260 seconds]
ChiefAlexander has quit [Remote host closed the connection]
jaruga____ has quit [Quit: jaruga____]
Beverage has quit [Ping timeout: 276 seconds]
drewo has joined #ruby
SilverKey has joined #ruby
conta has joined #ruby
troulouliou_div2 has joined #ruby
zacts_pi has joined #ruby
rcvalle has joined #ruby
SilverKey has quit [Client Quit]
pawnbox has joined #ruby
zacts has quit [Ping timeout: 244 seconds]
mostlybadfly has joined #ruby
troulouliou_div2 has quit [Remote host closed the connection]
nennes has quit [Quit: Textual IRC Client: www.textualapp.com]
ericsupreme has joined #ruby
zacts_raincity has joined #ruby
kab has joined #ruby
Emmanuel_Chanel has joined #ruby
aegis3121 has joined #ruby
Emmanuel_Chanel has quit [Max SendQ exceeded]
zacts_pi has quit [Ping timeout: 250 seconds]
zacts has joined #ruby
rodorgas has joined #ruby
Emmanuel_Chanel has joined #ruby
kab has quit [Client Quit]
jaguarma_ has quit [Remote host closed the connection]
kab has joined #ruby
mattwashere has quit [Remote host closed the connection]
zacts_raincity has quit [Read error: Connection reset by peer]
Dimik has joined #ruby
zacts_pi has joined #ruby
xall_ has joined #ruby
mattwashere has joined #ruby
flashpoint9 has joined #ruby
pdoherty has quit [Ping timeout: 276 seconds]
TomyWork has quit [Ping timeout: 276 seconds]
hahuang61 has joined #ruby
zacts has quit [Ping timeout: 250 seconds]
HULK_SMASH has joined #ruby
yfeldblum has quit [Ping timeout: 272 seconds]
zacts_pi has quit [Ping timeout: 240 seconds]
spudowiar has joined #ruby
skade has joined #ruby
Silthias1 has joined #ruby
djbkd has joined #ruby
Silthias has quit [Ping timeout: 258 seconds]
nhhc has joined #ruby
kavanagh has joined #ruby
dennisvennink has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nerium has joined #ruby
sepp2k has joined #ruby
blaxter has quit [Quit: foo]
Vingador has quit [Remote host closed the connection]
CharlesN has quit [Quit: Ex-Chat]
weaksauce has joined #ruby
bathtub_shark has joined #ruby
karapetyan has joined #ruby
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Cohedrin has quit [Ping timeout: 240 seconds]
malconis has joined #ruby
johnmilton has quit [Remote host closed the connection]
jackjackdripper has quit [Quit: Leaving.]
cyphase has quit [Ping timeout: 264 seconds]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
Cohedrin has joined #ruby
wald0 has quit [Ping timeout: 276 seconds]
macsteps has quit [Remote host closed the connection]
zacts has joined #ruby
cyphase has joined #ruby
RegulationD has joined #ruby
roamingdog has quit [Remote host closed the connection]
kirun has joined #ruby
ramfjord_ has joined #ruby
roamingdog has joined #ruby
zacts has quit [Read error: Connection reset by peer]
speakingcode has joined #ruby
ramfjord has quit [Ping timeout: 240 seconds]
zacts has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
codecop has joined #ruby
ekinmur has joined #ruby
irregular has joined #ruby
ramfjord_ has quit [Ping timeout: 264 seconds]
<irregular> Hi guys, I have a class API with @cached_ids instance variable, is there a way to access the instance variable outside the class? i.e. API.cached_ids (this doesn't work though) or do I have to add a getter method
mistermo_ has quit [Remote host closed the connection]
rodfersou|lunch is now known as rodfersou
mistermocha has joined #ruby
mistermocha has quit [Remote host closed the connection]
mistermocha has joined #ruby
aegis3121 has quit [Ping timeout: 258 seconds]
leea has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zacts has quit [Quit: WeeChat 1.4]
zacts has joined #ruby
aegis3121 has joined #ruby
<shevy> irregular have you tried .instance_variable_get() yet?
ericsupreme has quit [Quit: Leaving]
devbug has joined #ruby
<jhass> irregular: if you consider it public API to read the variable you should add a getter
harfangk has quit [Quit: Textual IRC Client: www.textualapp.com]
<zacts> lo
<shevy> zacts is in the house
<shevy> reading his 35th ruby book
<zacts> yo yo
<zacts> indeed
<zacts> :-D
<zacts> I'm working on RSpec right now, but via the pluralsight tutorials and not the outdated book
<irregular> shevy:just tried it, thank you!!
<shevy> \o/
<zacts> (dude, I even know ruby books so well now to know that the RSpec book is officially outdated by pragmatic)
<zacts> I'm the channel ruby bibliophile
<irregular> jhass:it will only be used in one place so for now I will just use instance variable get
<jhass> irregular: bad reason
xall_ has quit [Ping timeout: 240 seconds]
<shevy> high quality books are awesome but most books I found are sorta average or just slightly above average. I liked the original pickaxe in 2005 or so. Did not like any books afterwards really. The worst was a rails book ... how to build a webshop, it was so boring that I did not make it to page 100
<zacts> shevy: which rails book was it?
<zacts> was it by hartl?
<zacts> I'm making a list of books I don't like to save other's time too
<shevy> zacts I don't even remember the name
<shevy> I think it was... from 2007 or 2008 or so
<ineb> shevy: i know what book youre talking about. and the same happened to me there. dont know exactly were i stopped, but it was definitely below page 100
<ineb> alas i forgot the title aswell
Bish has quit [Ping timeout: 252 seconds]
anisha has quit [Quit: This computer has gone to sleep]
hk238 has quit [Quit: http://www.kvirc.net/ 4.9.1 Aria]
<zacts> shevy: sounds like hartl. yeah
<zacts> I think eventually it gets to a point to where you just read official doc rather than books
<shevy> precisely!
<shevy> or, no more docs reading and just wild tinkering
<zacts> shevy: eventually just pure perfect coding the 1st time, and no bugs. (as linus claims he can do...)
<zacts> (don't quote me on it though)
<ineb> using ed as editor.
Bish has joined #ruby
brianpWins has joined #ruby
rodferso1 has joined #ruby
Hounddog has quit [Ping timeout: 272 seconds]
astrobunny has quit [Read error: Connection reset by peer]
astrobunny has joined #ruby
rodfersou has quit [Ping timeout: 252 seconds]
moeabdol has quit [Ping timeout: 260 seconds]
pdoherty has joined #ruby
dionysus69 has quit [Remote host closed the connection]
dionysus69 has joined #ruby
CodeAleks has joined #ruby
et09 has joined #ruby
conta has quit [Quit: conta]
mdw has joined #ruby
<et09> im having a really weird problem, i define a proc and then do myarray.map{|x| myproc.call(x)} - and every item in the result array is based on the last item in the source array
finnnnnnnnnnn has joined #ruby
<jhass> ?code
<ruby[bot]> We can't help you without your code, please post it to https://gist.github.com
<hammond> ok I have a array of Threads. why can't I use arr[index].join ? and I'm forced to use arr.each { |t| t.join } instead
<hammond> the arr is an array. right?
tmtwd has joined #ruby
<jhass> how should we know? you never showed its definition
<eam> why is File.exists? deprecated?
<jhass> what do you mean you can't?
<jhass> eam: naming policies, File.exist? shouldn't
<eam> *oh* exist vs exists
<eam> gotcha
xall_ has joined #ruby
<eam> I missed the "s" in casually reading the docs and thought the entire thing was going away
<et09> i can't post the code :( it's proprietary
<et09> but shouldn't that be impossible ??
<eam> et09: no, not at all
<eam> are your items complex structures?
ChiefAlexander has joined #ruby
<et09> they're hashes
<eam> you're probably dealing with a single hash reference inside your proc
<et09> a single hash reference?
r_rios has joined #ruby
<eam> >> a = {}; b = [a, a]; a[1] = 2; b
<eam> well, run that code, look at b - I bet you're doing something similar
<eam> also, you need to be able to simplify your problem into something generic you can share
<eam> it's a good process to go through just purely for the sake of debugging
<et09> it's an array of separate hashes with no circular references
eam has quit [Changing host]
eam has joined #ruby
<eam> what's the object id of each element?
<et09> the object id?
<jhass> &ri Object#object_id
<eam> puts myarray.map(&:object_id)
finnnnnnnnnnn has quit [Quit: finnnnnnnnnnn]
<et09> result.map(&:object_id).uniq.count is the same as result.count
<et09> 8407
<eam> no, I want to know what the object_id of each element is
<eam> oh, but you're saying they differ
<eam> dunno then - post code ;)
skade has quit [Ping timeout: 258 seconds]
<et09> (grinds teeth)
<eam> et09: I deal with code under nda all the time. It's never stopped me from reproducing a generic, isolated test case
<eam> 99% of the time I discover the issue as I construct the test case, fwiw
workmad3 has quit [Ping timeout: 276 seconds]
shinnya has quit [Ping timeout: 252 seconds]
dsea has quit [Read error: Connection reset by peer]
mistermocha has quit [Remote host closed the connection]
LoneHerm_ has quit [Remote host closed the connection]
mistermocha has joined #ruby
spider-mario has joined #ruby
r_rios has quit [Remote host closed the connection]
LoneHermit has joined #ruby
Silthias1 has quit [Quit: Leaving.]
grill has quit [Quit: yolo.swag]
kavanagh has quit [Quit: That's all folks!]
skade has joined #ruby
dn` has joined #ruby
<jhass> yeah, I do that for code I can share too, it prevents the question more often than not
<et09> i think i actually hit a bug in ruby
GodFather has quit [Ping timeout: 276 seconds]
<et09> either that or this code really does not work as expected
SilverKey has joined #ruby
LoneHermit has quit [Ping timeout: 240 seconds]
mistermocha has quit [Remote host closed the connection]
KnownSyntax_ has quit [Ping timeout: 272 seconds]
KnownSyntax has joined #ruby
KnownSyntax has quit [Changing host]
KnownSyntax has joined #ruby
mistermocha has joined #ruby
cyphase has quit [Ping timeout: 250 seconds]
nerium_ has joined #ruby
macsteps has joined #ruby
tophat has quit [Quit: Page closed]
karapetyan has quit [Remote host closed the connection]
<et09> like if i do
eizua has quit [Remote host closed the connection]
<et09> result_array = result.map{|x| myproc.call(x)}
<et09> i actually get a different result than
<jhass> ?nda
<ruby[bot]> If you cannot share your code, we cannot help you. Create a complete, executable example that you can share and that reproduces your issue, or hire a consultant.
<et09> result_array = []; result.each{|x| result_array << myproc.call(x)}
<jhass> period.
nerium has quit [Ping timeout: 272 seconds]
nerium_ is now known as nerium
finnnnnnnnnnn has joined #ruby
<et09> thanks
mistermocha has quit [Ping timeout: 260 seconds]
cyphase has joined #ruby
macsteps has quit [Ping timeout: 240 seconds]
Azure has quit [Ping timeout: 264 seconds]
marr has quit [Ping timeout: 276 seconds]
KnownSyntax_ has joined #ruby
KnownSyntax_ has quit [Changing host]
KnownSyntax_ has joined #ruby
KnownSyntax has quit [Ping timeout: 260 seconds]
madgen has quit [Ping timeout: 244 seconds]
SilverKey has quit [Quit: Halted.]
TheHodge has quit [Quit: Connection closed for inactivity]
aegis3121 has quit [Ping timeout: 264 seconds]
chosen1 has joined #ruby
pandaant has quit [Quit: Lost terminal]
dionysus69 has quit [Remote host closed the connection]
dionysus69 has joined #ruby
zeroDi has joined #ruby
chosen1_ has quit [Ping timeout: 258 seconds]
dunpeal has quit [Ping timeout: 240 seconds]
ElFerna has joined #ruby
smathy has joined #ruby
ElFerna has quit [Client Quit]
mistermocha has joined #ruby
SilverKey has joined #ruby
karapetyan has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
jenrzzz has joined #ruby
jackjackdripper has joined #ruby
mistermocha has quit [Ping timeout: 260 seconds]
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ziyan_ has quit [Remote host closed the connection]
banisterfiend has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dikaio has joined #ruby
Beverage has joined #ruby
banisterfiend has joined #ruby
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
Beverage has quit [Client Quit]
roamingdog has quit [Read error: Connection reset by peer]
kappy has quit [Quit: Lost terminal]
roamingdog has joined #ruby
<irregular> for @array[:variable], how can do that but with variable actually being a variable (with different values)?
Wsewolod has quit [Ping timeout: 258 seconds]
<irregular> I can do @array[variable] but the resulting array is slightly different than I want
Mirubiri has joined #ruby
<elomatreb> If you're absolutely sure it's what you want, you can do [variable.to_sym]
* jhass has a dejavu
<elomatreb> Ah, it's a array, I'm an idiot
<jhass> irregular: what do you get, what do you expect?
djbkd has quit [Ping timeout: 252 seconds]
aegis3121 has joined #ruby
<irregular> jhass:actually I'm not sure if this is the problem but each time I do @array[:id] = someid then that same thing again, it doesn't override the previous :id like a map, but appends to it hmm
Es0teric has joined #ruby
Es0teric has quit [Max SendQ exceeded]
<jhass> {this: is, a: hash}, [this, is, an, array]
<jhass> what do you have?
Es0teric has joined #ruby
<jhass> what's p @array.class ?
Es0teric has quit [Max SendQ exceeded]
tmtwd has quit [Ping timeout: 264 seconds]
<elomatreb> If you're doing @var[:something] = ... and it doesn't error, you likely have a Hash
Es0teric has joined #ruby
Es0teric has quit [Max SendQ exceeded]
fmcgeough has quit [Quit: fmcgeough]
<irregular> when I print it out it looks like {"startDate"=>"2016-06-01", "startTime"=>"10:00", "durationMinutes"=>60, :startDate=>"2016-7-19", :startTime=>"15:19", :durationMinutes=>1}
Mirubiri has quit [Quit: Mirubiri]
zacts has quit [Read error: Connection reset by peer]
fmcgeough has joined #ruby
Es0teric has joined #ruby
<jhass> that's ah hash
<elomatreb> That's a Hash, not an Array
<jhass> but please answer my question
Mirubiri has joined #ruby
<jhass> what's p @array.class ?
ekinmur has joined #ruby
<jhass> oh I think I see
<irregular> h/o let me print that out
<jhass> do you expect @whatever[:startDate] = whatever to overwrite "startDate"=>"2016-06-01" ?
<jhass> >> "startDate" == :startDate
tomchapin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<ruby[bot]> jhass: # => false (https://eval.in/608163)
<irregular> I want one to override the other, either one is fine
<jhass> no, you don't
<jhass> just use @whatever["startDate"] = whatever
ekinmur has quit [Client Quit]
tomchapin has joined #ruby
<irregular> jhass:how would I have it the other way around? overriding the :key
<jhass> there's no :key, you add it by doing @whatever[:startDate] = whatever
<jhass> so no need to overwrite it
<elomatreb> :startDate is a symbol, a data type basically like a string, but slightly different
ekinmur has joined #ruby
<irregular> the key is passed in as a variable to a function then @array[key] is done, how would I turn that key into a :key?
astrobunny has quit [Read error: Connection reset by peer]
<jhass> its usecases are largely orthogonal to strings, comparison to it just confuses people who didn't understand symbols yet IME
<eam> irregular: to_sym
<jhass> wrong direction.
astrobunny has joined #ruby
<jhass> if you do indeed get passed a symbol and _cannot change that_, call .to_s
<elomatreb> jhass: Are you sure? I found symbols to be very confusing, until I understood that they're basically lighter strings
<irregular> jhass:we're using factory girl and there's already code utilizing :keyorsymbol so I think i'll try the to_sym to fit into that
swills has quit [Remote host closed the connection]
<jhass> elomatreb: yes, comparing it to enums works better IME
<jhass> or magic numbers/values
postmodern has joined #ruby
<jhass> because that's what they are, named magic numbers
banisterfiend has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jhass> and that's what they're best used for
<jhass> if people start to think of them as strings, they end up doing string operations on them
<elomatreb> I guess if you have previous programming experience, you're right. I got into Ruby just knowing how to write HTML and CSS
<eam> ENUM, really
banisterfiend has joined #ruby
<elomatreb> If you don't have that experience, I doubt I'd understand why magic numbers warrant a special data type
astrobunny has quit [Read error: Connection reset by peer]
mdw has quit [Quit: Sleeping Zzzzz]
xall_ has quit [Read error: Connection reset by peer]
astrobunny has joined #ruby
xall_ has joined #ruby
moeabdol has joined #ruby
kavanagh has joined #ruby
leea has joined #ruby
karapetyan has quit [Remote host closed the connection]
[Butch] has quit [Quit: I'm out . . .]
<irregular> actually it was the other way around, the keys were "key" already but newly added (overlapping keys) were being put in as :key. I had to do @array["#{key}"] to properly override the "key" value
<irregular> there mustve been some implicit conversion or something idk
Tempesta has quit [Ping timeout: 250 seconds]
jaguarmagenta has joined #ruby
karapetyan has joined #ruby
jaguarmagenta has quit [Remote host closed the connection]
<jhass> irregular: just .to_s
karapetyan has quit [Remote host closed the connection]
<jhass> "#{key}" -> key.to_s
Dimik has quit [Ping timeout: 276 seconds]
LoneHermit has joined #ruby
tomaz_b has joined #ruby
dionysus69 has quit [Ping timeout: 244 seconds]
<irregular> thanks!
dionysus69 has joined #ruby
mistermocha has joined #ruby
ChiefAlexander has quit [Remote host closed the connection]
<irregular> would you know if there's a method to turn all the keys to string keys from symbol keys?
pwnd_nsfw has quit [Ping timeout: 258 seconds]
LoneHermit has quit [Remote host closed the connection]
LoneHerm_ has joined #ruby
mistermocha has quit [Remote host closed the connection]
mistermocha has joined #ruby
dionysus69 has quit [Remote host closed the connection]
dionysus69 has joined #ruby
karapetyan has joined #ruby
<havenwood> irregular: Is Rails involved or are you otherwise using ActiveSupport?
<havenwood> irregular: {'aim' => true}.map { |k, v| [k.to_sym, v] }.to_h
pwnd_nsfw has joined #ruby
djbkd has joined #ruby
<havenwood> irregular: {'aim' => true}.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
ChiefAlexander has joined #ruby
cyphase has quit [Ping timeout: 240 seconds]
<havenwood> irregular: with ActiveSupport: {'aim' => true}.symbolize_keys
ecnalyr has joined #ruby
crystal77 has joined #ruby
djbkd has quit [Remote host closed the connection]
GodFather has joined #ruby
djbkd has joined #ruby
ur5us has joined #ruby
madgen has joined #ruby
macsteps has joined #ruby
<finnnnnnnnnnn> good evening all, anyone have any advice on best pracise then filtering models? I have a series of select boxes listing my model IDs and I want to submit them with a GET to a controller that reads the IDs and then returns the filtered set of models. I’m wondering how to contruct the form. I’m using check_box_tag but I’ve read it’s not best practise to pass an array in params using check_box_tag/
<irregular> actually it may be better if I change this yml file. the initial array values are loaded from YAML.load_file("path/to/file"), the file looks like startDate: "2016-06-01", and a few more key value pairs, is there a way to modify the yml file so that the resulting array looks like :startDate=>"2016-06-01" instead of "startDate"=>"2016-06-01"
solars has joined #ruby
Es0teric has quit [Quit: Computer has gone to sleep.]
moeabdol has quit [Ping timeout: 260 seconds]
tomchapin has quit [Quit: Textual IRC Client: www.textualapp.com]
cyphase has joined #ruby
karapetyan has quit [Remote host closed the connection]
jenrzzz has quit [Ping timeout: 264 seconds]
hahuang61 has quit [Quit: WeeChat 1.5]
kitikonti has joined #ruby
macsteps has quit [Ping timeout: 240 seconds]
vuoto has joined #ruby
mattwashere has quit [Remote host closed the connection]
griffindy has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
aegis3121 has quit [Read error: Connection reset by peer]
mostlybadfly has quit [Quit: Connection closed for inactivity]
lxsameer has quit [Quit: WeeChat 1.5]
aegis3121 has joined #ruby
mattwashere has joined #ruby
madgen has quit [Ping timeout: 276 seconds]
<havenwood> finnnnnnnnnnn: You might have better luck with Rails-specific questions in the #RubyOnRails channel.
roshanavand has joined #ruby
xall_ has quit [Read error: Connection reset by peer]
<kitikonti> in middleman i define string translations in a yml file. if i want to use this strings in my template i need to write <%= t(:apple) %>
<kitikonti> in my case i want to use multiple levels in the yml file
pwnd_nsfw` has joined #ruby
<kitikonti> if i now write <%= t(:apple) %> i get a array like this {:color=>"red", :size=>"big"}
<kitikonti> what do i have to write to get the color?
<finnnnnnnnnnn> havenwood: ooops, thought I was in the rails room. thanks!
troulouliou_div2 has joined #ruby
<havenwood> kitikonti: That looks like a Hash not an Array
<kitikonti> <%= t(:apple:color) %> dont work
<kitikonti> ok
<irregular> nvm i found symbolize_keys() did the job
<kitikonti> havenwood but how do i get the color out of this?
roamingdog has quit [Remote host closed the connection]
ramfjord has joined #ruby
<havenwood> >> {:color=>"red", :size=>"big"}[:color] # kitikonti
<ruby[bot]> havenwood: # => "red" (https://eval.in/608188)
pwnd_nsfw has quit [Ping timeout: 272 seconds]
<kitikonti> havenwood ahhh again, yesterday i have made the same mistake
<kitikonti> i always write the idetifier inside the function call (function parameter)
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
ghr has joined #ruby
nerium has quit [Quit: nerium]
jackjackdripper has quit [Quit: Leaving.]
codecop has quit [Remote host closed the connection]
jackjackdripper has joined #ruby
mikecmpbll has joined #ruby
jaguarmagenta has joined #ruby
pwnd_nsfw has joined #ruby
blackgoat has joined #ruby
pwnd_nsfw` has quit [Ping timeout: 250 seconds]
swills has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
madgen has joined #ruby
ramfjord has quit [Ping timeout: 240 seconds]
pwnd_nsfw` has joined #ruby
ramfjord has joined #ruby
pwnd_nsfw has quit [Ping timeout: 250 seconds]
jaguarmagenta has quit [Remote host closed the connection]
mr_hubot has quit [Quit: Leaving]
LoneHerm_ has quit [Remote host closed the connection]
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
kavanagh has quit [Quit: That's all folks!]
karapetyan has joined #ruby
ekinmur has joined #ruby
fmcgeough has quit [Quit: fmcgeough]
karapetyan has quit [Remote host closed the connection]
jaguarmagenta has joined #ruby
karapetyan has joined #ruby
fmcgeough has joined #ruby
solars has quit [Ping timeout: 258 seconds]
AndrewIsHere has quit []
devbug has quit [Quit: ZZZzzz…]
devbug has joined #ruby
howdoi has quit [Quit: Connection closed for inactivity]
leea has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ecnalyr has quit []
ramfjord has quit [Ping timeout: 240 seconds]
synthroid has quit []
ramfjord has joined #ruby
maloik has quit [Remote host closed the connection]
maloik has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
jenrzzz has joined #ruby
jaguarmagenta has quit [Remote host closed the connection]
bmurt has joined #ruby
aegis3121 has quit [Ping timeout: 240 seconds]
ChiefAlexander has quit [Remote host closed the connection]
solars has joined #ruby
<smathy> kitikonti, t("apple.color") will also work.
finnnnnnnnnnn has quit [Quit: finnnnnnnnnnn]
<et09> eam: i figured out the problem
<et09> the proc generator was not instantiating a new object for its assignments each time, it was using the same one
<et09> 3 hours down the drain, just needed to add a ".dup" ;____;
<kitikonti> smathy thx, this looks a bit nicer
<smathy> kitikonti, it's more idiomatic for the I18n stuff.
jaguarmagenta has joined #ruby
nadir has quit [Quit: Connection closed for inactivity]
jenrzzz has quit [Ping timeout: 276 seconds]
safetypin has joined #ruby
vuoto has quit [Remote host closed the connection]
flashpoint9 has quit [Ping timeout: 250 seconds]
AngryBuzzy has joined #ruby
fmcgeough has quit [Quit: fmcgeough]
marr has joined #ruby
roshanavand has quit [Quit: This computer has gone to sleep]
dunpeal has joined #ruby
whathappens has quit [Remote host closed the connection]
hipertracker has joined #ruby
whathappens has joined #ruby
spudowiar1 has joined #ruby
spudowiar has quit [Ping timeout: 244 seconds]
edwinvdgraaf has joined #ruby
jaguarmagenta has quit [Remote host closed the connection]
Xiti has quit [Quit: Xiti]
yfeldblum has joined #ruby
spudowiar2 has joined #ruby
whathappens has quit [Ping timeout: 276 seconds]
leea has joined #ruby
Guest60828 has quit [Ping timeout: 250 seconds]
finnnnnnnnnnn has joined #ruby
Guest60828 has joined #ruby
johnmilton has joined #ruby
crystal77 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
spudowiar1 has quit [Ping timeout: 272 seconds]
roshanavand has joined #ruby
finisherr has joined #ruby
ChiefAlexander has joined #ruby
ldnunes has quit [Quit: Leaving]
aegis3121 has joined #ruby
jhack has quit [Quit: jhack]
workmad3 has joined #ruby
AngryBuzzy has quit [Quit: This computer has gone to sleep]
johnmilton has quit [Ping timeout: 260 seconds]
johnmilton has joined #ruby
dunpeal has quit [Ping timeout: 250 seconds]
GNUYawk has joined #ruby
whathappens has joined #ruby
Madplatypus has joined #ruby
solars has quit [Ping timeout: 240 seconds]
dvinciguerra_ has quit [Ping timeout: 272 seconds]
rodferso1 has quit [Quit: leaving]
Ishido has quit [Quit: Roads? Where We're Going We Don't Need Roads.]
araujo has quit [Ping timeout: 244 seconds]
blackgoat has quit [Quit: WeeChat 1.5]
ChiefAlexander has quit [Quit: Leaving...]
Xeago has quit [Ping timeout: 264 seconds]
<eam> et09: figured it was the same reference ;)
spudowiar2 has quit [Ping timeout: 272 seconds]
<et09> it was deceptive because the proc instantiation itself was creating that object which the reference went to
ruby-lang795 has joined #ruby
ekinmur has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ramortegui has quit [Quit: Ex-Chat]
spudowiar has joined #ruby
<ruby-lang795> Does anyone know the best way to convert a string into a hash? Given this string: "{\"test\"=>nil, \"test2\"=>nil, \"test3\"=>nil}"
<ruby-lang795> The best method I can come up with is using eval(string)
<et09> it was deceptive because the proc instantiation itself was creating that object which the reference went to
araujo has joined #ruby
eljimbo has quit [Quit: This computer has gone to sleep]
CodeAleks has quit [Remote host closed the connection]
<havenwood> >> eval "{\"test\"=>nil, \"test2\"=>nil, \"test3\"=>nil}" # ruby-lang795
<ruby[bot]> havenwood: # => {"test"=>nil, "test2"=>nil, "test3"=>nil} (https://eval.in/608232)
<et09> ruby-lang795: is it a one dimensional hash
<ruby-lang795> Yeah, just a one dimensional hash
<et09> then split by comma
<et09> etc.
<ruby-lang795> Isn't it pretty taboo to use Eval?
Guest60828 has quit [Ping timeout: 250 seconds]
LoneHerm_ has joined #ruby
<et09> yeah it's unsafe
<Mon_Ouie> ruby-lang795: Where does that string come from?
Guest60828 has joined #ruby
istrasci has joined #ruby
<ruby-lang795> It comes from a database text field using ActiveRecord::Base
<ruby-lang795> The app isn't using Rails though so I don't think serialize is an option
<Mon_Ouie> Why are you storing a hash like that in a database?
dunpeal has joined #ruby
<ruby-lang795> Good question, wish I could have asked the guy myself :/
ses1984 has joined #ruby
Xiti has joined #ruby
<istrasci> Using ruby 2.3.1, why is
<istrasci> > {'a': 1} == {'a' => 1}
<istrasci> => false
<Mon_Ouie> istrasci: The first one has a symbol as a key, the second one uses a string.
<et09> is it a ruby hash to begin with?
<istrasci> So using the : syntax in a Hash forces the key to be a symbol?
<et09> or a json hash perhaps?
LoneHerm_ has quit [Remote host closed the connection]
<ruby-lang795> I believe it's a ruby hash to begin with
<et09> n/m i see nil, not null
<istrasci> Ruby
LoneHerm_ has joined #ruby
jaguarmagenta has joined #ruby
<Mon_Ouie> ruby-lang795: The real solution would be to use a more suitable way to encode your data, but if you have to deal with this encoding, there are no safe built-in methods to read Ruby literals
finnnnnnnnnnn has quit [Quit: finnnnnnnnnnn]
<ruby-lang795> Ah ok, that's what I was afraid of. Thank you for the help! I'll probably start some refactoring haha
<Mon_Ouie> You could build a parser that only parses some literals without running dangerous code, but that's quite a bit of work (not sure if there are gems doing this)
kirun has quit [Remote host closed the connection]
<et09> how many records are you dealing with
JeanCarloMachado has quit [Quit: Lost terminal]
<ruby-lang795> only a few 100 for now
<et09> then change the code dealing with their format asap
Xeago has joined #ruby
<et09> if you're using postgresql you can use json/jsonb types
<havenwood> ruby-lang795: which db?
<et09> automatically (de)serialized to activerecord and vice versa
<ruby-lang795> mysql :/
<et09> they have it too now
<et09> as of 5.7.8
devbug has quit [Quit: ZZZzzz…]
<ruby-lang795> Nice! shouldn't be too difficult to get it switched and migrated then
aryaching has quit [Remote host closed the connection]
<et09> yeah
<et09> since you can visually inspect the data set, you can easily run eval against it during the migration, if you determine it's safe (which god knows it prob is)
replay has joined #ruby
Puffball has joined #ruby
aryaching has joined #ruby
<havenwood> Mon_Ouie: there's literal_parser: https://github.com/apeiros/literal_parser
JesseH has quit [Ping timeout: 258 seconds]
phredus_ has joined #ruby
aep-shoutlet has quit [Quit: Connection closed for inactivity]
phredus_ has quit [Remote host closed the connection]
finnnnnnnnnnn has joined #ruby
postmodern has quit [Ping timeout: 250 seconds]
finnnnnnnnnnn has quit [Client Quit]
ruby-lang795 has quit [Quit: Page closed]
malconis has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
flashpoint9 has joined #ruby
freeman1337 has joined #ruby
ruby-lang834 has joined #ruby
karapetyan has quit [Remote host closed the connection]
ruby-lang834 has left #ruby [#ruby]
devbug has joined #ruby
pdoherty has quit [Ping timeout: 250 seconds]
leea has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
freeman1337 has quit [Client Quit]
Bish has quit [Ping timeout: 244 seconds]
Bish has joined #ruby
Trynemjoel has quit [Ping timeout: 264 seconds]
leea has joined #ruby
omphe has joined #ruby
<shevy> this is for how apeiros becomes famous
em0ral has joined #ruby
<shevy> that - and halsbe
crystal77 has joined #ruby
cd-rum has joined #ruby
omphe has quit [Client Quit]
karapetyan has joined #ruby
JesseH has joined #ruby
iceden has quit [Ping timeout: 252 seconds]
cd-rum_ has joined #ruby
troulouliou_div2 has quit [Quit: Leaving]
postmodern has joined #ruby
Trynemjoel has joined #ruby
cd-rum_ has quit [Max SendQ exceeded]
banisterfiend has quit [Quit: Textual IRC Client: www.textualapp.com]
tomaz_b has quit [Ping timeout: 240 seconds]
cd-rum has quit [Ping timeout: 252 seconds]
workmad3 has quit [Ping timeout: 272 seconds]
toretore has quit [Ping timeout: 264 seconds]
dfockler has joined #ruby
hutch34_ has quit [Ping timeout: 252 seconds]
blackgoat has joined #ruby
postmodern has quit [Ping timeout: 250 seconds]
cyphase has quit [Ping timeout: 250 seconds]
SilverKey has quit [Quit: Halted.]
dionysus69 has quit [Ping timeout: 244 seconds]
jaguarmagenta has quit [Remote host closed the connection]
flashpoint9 has quit [Remote host closed the connection]
SilverKey has joined #ruby
tapa has quit [Read error: Connection reset by peer]
flashpoint9 has joined #ruby
cyphase has joined #ruby
cd-rum has joined #ruby
shinnya has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
jenrzzz has joined #ruby
symm- has quit [Ping timeout: 276 seconds]
hutch34_ has joined #ruby
irregular has quit [Ping timeout: 240 seconds]
flashpoint9 has quit [Ping timeout: 250 seconds]
Azure has joined #ruby
banisterfiend has joined #ruby
postmodern has joined #ruby
davedev24 has quit [Remote host closed the connection]
spudowiar has quit [Quit: zzzzzzz]
dennisvennink has joined #ruby
shinnya has quit [Ping timeout: 276 seconds]
nando293921 has joined #ruby
mattwashere has quit [Remote host closed the connection]
mattwashere has joined #ruby
reaVer has quit [Ping timeout: 244 seconds]
reaVer has joined #ruby
SilverKey has quit [Quit: Halted.]
mattwashere has quit [Ping timeout: 250 seconds]
Xeago has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
aegis3121 has quit [Ping timeout: 240 seconds]
l4v2 has quit [Quit: l4v2]
istrasci has left #ruby [#ruby]
nando293921 has quit [Quit: Lost terminal]
nando293921 has joined #ruby
troulouliou_div2 has joined #ruby
elifoster has joined #ruby
chipotle has joined #ruby
jenrzzz_ has joined #ruby
pawnbox has quit [Ping timeout: 244 seconds]
bmurt has quit [Quit: Textual IRC Client: www.textualapp.com]
jenrzzz has quit [Ping timeout: 260 seconds]
LoneHerm_ has quit [Read error: Connection reset by peer]
LoneHerm_ has joined #ruby
troulouliou_div2 has quit [Quit: Leaving]
smathy is now known as smathy_afk
nando293921 has quit [Ping timeout: 276 seconds]
dennisvennink has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
crystal77 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
firstdayonthejob has quit [Ping timeout: 258 seconds]
crystal77 has joined #ruby
macsteps has joined #ruby
polishdub has quit [Quit: Leaving]
dminuoso has quit [Quit: Lost terminal]
dminuoso has joined #ruby
banisterfiend has quit [Ping timeout: 276 seconds]
eljimbo has joined #ruby
macsteps has quit [Remote host closed the connection]
chipotle has quit [Quit: cheerio]
spider-mario has quit [Remote host closed the connection]
edwinvdgraaf has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
fmcgeough has joined #ruby
fmcgeough has quit [Client Quit]
steve has quit [Ping timeout: 250 seconds]
l4v2 has joined #ruby
DeltaHeavy has joined #ruby
<DeltaHeavy> I have a Jekyll project and I'm wondering if the things in my Gemfile will be installed system wide. If so do I want this? Generally things should be for the specific repo no?
et09 has quit [Quit: leaving]
edwinvdgraaf has joined #ruby
<DeltaHeavy> Ah, --path
finisherr has quit [Quit: finisherr]
<havenwood> DeltaHeavy: or set BUNDLE_PATH or use --deployment for ./vendor/bundle
<havenwood> DeltaHeavy: But the Bundle will ensure you're using the correct versions even if they're installed in GEM_PATH.
<DeltaHeavy> havenwood Is using --path not enough?
isberg has joined #ruby
smathy_afk is now known as smathy
dennisvennink has joined #ruby
<havenwood> DeltaHeavy: --path should do the trick - just remember it's a "remembered" setting so it'll end up in your bundler conf file
crystal77 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
MrBusiness2 has joined #ruby
<havenwood> so just omitting --path won't go back to system, but maybe that's what you want
<havenwood> bundle config path
<DeltaHeavy> havenwood Got it, I figured it's best to have all my gems specific to this project local as I do with other platforms. If that's different for Ruby let me konw.
blackmesa has quit [Ping timeout: 276 seconds]
<havenwood> DeltaHeavy: Some folk just use the gem install location since Bundler will still select the exact gems and versions from the Gemfile.lock.
<havenwood> DeltaHeavy: It's perfectly fine to install the gems locally to the project as well though.
davedev24 has joined #ruby
<leea> shevy do you have any advice on how to get used to a codebase of such size like fpm?
smathy has quit [Ping timeout: 250 seconds]
Bish has quit [Ping timeout: 240 seconds]
SCHAAP137 has quit [Quit: Leaving]
giz|work has quit [Ping timeout: 272 seconds]
devster31 has quit [Ping timeout: 264 seconds]
Bish has joined #ruby
davedev24 has quit [Ping timeout: 250 seconds]
sepp2k has quit [Read error: Connection reset by peer]
dennisvennink has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
edwinvdgraaf has quit [Remote host closed the connection]
dennisvennink has joined #ruby
edwinvdgraaf has joined #ruby
Vingador has joined #ruby
<shevy> leea haha :)
<shevy> I struggle with that myself... it's on my todo list
<shevy> leea in the past I tried to adapt the style to my style
<shevy> but that requires a lot of time to invest so that is not good
biberu has quit [Read error: Connection reset by peer]
mistermocha has quit [Remote host closed the connection]
<leea> I mean there are a lot of moving parts
<shevy> yep
mistermocha has joined #ruby
<leea> hmm do you have any thoughts on a better workflow than
<shevy> not really, I struggle with this on my big projects too
<leea> nvm
<shevy> for small projects this is usually simple
<leea> do you have any tools you like to use for debug?
<shevy> like "do one thing and do it well"
<shevy> I am like tenderlove here! let me fetch the post he wrote about debugging...
edwinvdgraaf has quit [Ping timeout: 264 seconds]
<elomatreb> Not strictly a debug tool, but I really enjoy occasionally running my apps through stackprof
<shevy> I tend to use pp though, and colourize the problem + output the line and class of what is going awry. And I try to have code so dumb that I never have to guess what it does
<drbrain> ↑ good techniques here
<elomatreb> Also, a "real" debugger like byebug is a blessing, imo
<shevy> oh actually, he also outputs a spacer, from the blog:
<shevy> puts "#" * 90
<shevy> :)
<shevy> I never got into that breakpoints-business of debugging
<elomatreb> Neither did I in other languages, I just use byebug like a much more convenient print statement
LoneHerm_ has quit [Read error: Connection reset by peer]
mistermocha has quit [Ping timeout: 240 seconds]
<leea> not sure if i should ask here on on #fpm, but how would i run this thing? since it's a gem
<leea> or it builds into a gem
aries_liuxueyang has quit [Ping timeout: 252 seconds]
<DeltaHeavy> Is Jekyll kinda dead?
<elomatreb> Jekyll is one of those OS projects that you could almost call "finished"
JammyHammy has quit [Read error: Connection reset by peer]
kitikonti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
LoneHerm_ has joined #ruby
rodorgas has quit [Quit: rodorgas]
SuperLag has quit [Ping timeout: 240 seconds]
macsteps has joined #ruby
SuperLag has joined #ruby
hutch34_ has quit [Ping timeout: 260 seconds]
mikecmpbll has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Mirubiri has quit [Quit: Mirubiri]
Bish has quit [Ping timeout: 250 seconds]
Bish has joined #ruby
rodorgas has joined #ruby
<shevy> leea if it is a gem, "gem install fpm" should work
<shevy> leea https://rubygems.org/gems/fpm - you can also try the updated github source, "download as zip", extract it... then, well, you can install it as a gem if you build it or you can use setup.rb - I personally use setup.rb, it is not as clean, since you have to do a manual removal but this I can do easily... I go into the site dir of ruby and remove fpm/ and fpm.rb
<shevy> but it was just one example, perhaps you can find smaller projects
Mirubiri has joined #ruby
<leea> I'll make at least 1 PR :)
pdoherty has joined #ruby
<shevy> I mentioned it largely because being able to generate .deb .rpm etc... is on my todo list... so I would either have to do it on my own from scratch or make use of something that already exists
rcvalle has quit [Quit: rcvalle]
SuperLag has quit [Ping timeout: 264 seconds]
SuperLag_ has joined #ruby
<leea> I mean I'll probably deal with this in industry right? learning new big code bases
dminuoso has quit [Ping timeout: 250 seconds]
cZk is now known as czk
<shevy> yeah, not a lot of fun IMO :\
<shevy> actually
vdamewood has quit [Quit: Life beckons.]
<shevy> if your goal is heavily inspired by industry, you may try to get good at testing
drewo has quit [Ping timeout: 260 seconds]
<leea> what do you mean by testing? like rspec and that?
<shevy> I remember perhaps 3 years ago or so, for a ruby job in milano, it was pointed out that writing specs/tests was mandatory
<shevy> yeah
rodorgas has quit [Quit: rodorgas]
<shevy> it still was a niche area though, related to bioinformatics. there is evidently more going on in the www/rails world
KnownSyntax has joined #ruby
KnownSyntax has quit [Changing host]
KnownSyntax has joined #ruby