havenwood changed the topic of #ruby to: Rules & more: https://ruby-community.com || Ruby 2.4.0, 2.3.3 & 2.2.6: https://www.ruby-lang.org || Paste >3 lines of text to: https://gist.github.com || Rails questions? Ask in: #RubyOnRails || Logs: https://irclog.whitequark.org/ruby
sepp2k has quit [Quit: Leaving.]
Raticide has joined #ruby
milardovich has joined #ruby
<Raticide> Hi. So I've installed rbenv and used it to install ruby 2.4.0. `rbenv global 2.4.0` ran and 2.4.0 is returned by `rbenv global` but I still get: "bash: ruby: command not found" when running ruby. Any ideas what I might be missing?
<Raticide> Do I need to add something to PATH?
OMSQ has quit [Read error: Connection reset by peer]
akkad has quit [Ping timeout: 240 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mhenrixon has quit [Ping timeout: 258 seconds]
workmad3 has quit [Ping timeout: 252 seconds]
bmurt has joined #ruby
<Radar> Raticide: yes you do.
<Radar> Raticide: echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile
<Raticide> I have that
<Radar> seen*
<Raticide> rbenv is found, it's ruby/gem/irb that aren't found
<Radar> Raticide: What OS are you on?
<Raticide> ubuntu 16.04
<Raticide> oh, seems I need to add $HOME/.rbenv/shims to my PATH
<Radar> Raticide: Did you see the note in the README which says that you need to add the above line to ~/.bashrc instead of ~/.bash_profile?
<Radar> How about the step underneath that which says...
<Radar> Run ~/.rbenv/bin/rbenv init for shell-specific instructions on how to initialize rbenv to enable shims and autocompletion.
<Raticide> seems to work now I added shims to the path
<Radar> Great :)
<Raticide> ta
jackjackdripper has joined #ruby
acalycine has quit [Quit: bye]
griffindy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
brendan- has joined #ruby
gloscombe has quit [Quit: gloscombe]
nowhere_man has quit [Read error: Connection reset by peer]
nowhereman has joined #ruby
brendan- has quit [Read error: Connection reset by peer]
brendan- has joined #ruby
Fernando-Basso has quit [Quit: WeeChat 1.7]
UnknownSoldier has quit [Remote host closed the connection]
jackjackdripper has quit [Quit: Leaving.]
kazlock has joined #ruby
akkad has joined #ruby
blackwind_123 has quit [Ping timeout: 260 seconds]
kazlock has quit [Read error: Connection reset by peer]
griffindy has joined #ruby
gix- has joined #ruby
gix has quit [Disconnected by services]
devgiant has joined #ruby
devgiant has quit [Client Quit]
username_ has quit [Ping timeout: 245 seconds]
_aeris_ has quit [Ping timeout: 240 seconds]
Devalo has joined #ruby
JeanCarloMachado has quit [Ping timeout: 240 seconds]
kazlock has joined #ruby
Derperperd has quit [Ping timeout: 240 seconds]
griffindy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Devalo has quit [Ping timeout: 264 seconds]
minimalism has joined #ruby
duckpupp1 has joined #ruby
benlieb has joined #ruby
duckpupp1 has quit [Ping timeout: 240 seconds]
milardovich has quit [Remote host closed the connection]
<soahccc> I wrote a tool that processes access logs (with 5+(1+n) threads) and detects malicious patterns in realtime, it ran for 1w3d, processed 18mil log entries and still runs at 77MB RSS despite several spools (DB access) and timed queues (delayed assessment). Ask me nothing, I'm going to bed.
rprimus has joined #ruby
gix- has quit [Ping timeout: 256 seconds]
nankyokusei has joined #ruby
_aeris_ has joined #ruby
nankyokusei has quit [Ping timeout: 260 seconds]
gix has joined #ruby
segmond has joined #ruby
youch has joined #ruby
youch has quit [Ping timeout: 240 seconds]
sid_fules has quit [Remote host closed the connection]
ResidentBiscuit has joined #ruby
chouhoulis has joined #ruby
Julianee has joined #ruby
milardovich has joined #ruby
chouhoulis has quit [Ping timeout: 240 seconds]
ResidentBiscuit has quit [Ping timeout: 255 seconds]
UnknownSoldier has joined #ruby
Julianee has quit [Ping timeout: 255 seconds]
milardovich has quit [Ping timeout: 264 seconds]
Ropeney has joined #ruby
Azure has quit [Remote host closed the connection]
kht has joined #ruby
Derperperd has joined #ruby
spider-mario has quit [Ping timeout: 240 seconds]
Azure has joined #ruby
Derperperd has quit [Ping timeout: 240 seconds]
tectonic has joined #ruby
Xentil has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
milardovich has joined #ruby
arescorpio has joined #ruby
gix has quit [Ping timeout: 264 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
libastral has quit [Ping timeout: 240 seconds]
ledestin has joined #ruby
milardovich has quit [Ping timeout: 256 seconds]
duckpupp1 has joined #ruby
gix has joined #ruby
libastral has joined #ruby
duckpupp1 has quit [Ping timeout: 240 seconds]
milardovich has joined #ruby
kazlock has quit [Quit: This computer has gone to sleep]
`tim` has joined #ruby
kazlock has joined #ruby
milardovich has quit [Ping timeout: 255 seconds]
last_staff has quit [Quit: last_staff]
`tim` has quit [Ping timeout: 255 seconds]
d^sh has quit [Ping timeout: 240 seconds]
nankyokusei has joined #ruby
d^sh has joined #ruby
milardovich has joined #ruby
xlegoman has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nankyokusei has quit [Ping timeout: 240 seconds]
postmodern has joined #ruby
msmith has joined #ruby
nettoweb1 has joined #ruby
_geoff has quit [Ping timeout: 252 seconds]
milardovich has quit [Ping timeout: 256 seconds]
ecuanaso has joined #ruby
Julianee has joined #ruby
n|993|r has joined #ruby
dc4 has quit [Ping timeout: 276 seconds]
Log1x has quit [Quit: Quit]
Log1x_ has left #ruby ["Leaving"]
Log1x has joined #ruby
banisterfiend has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
_geoff has joined #ruby
<RickHull> i'd think 1k rows per sec should be easily doable. 3.6 mil / hr
<RickHull> so for 18 mil to take take 10 days, hopefully your thing was mostly blocked / sleeping
<RickHull> waiting for log entries to process
<nofxx> our app processes ~15M month, xmas 30M.... can't say it never corrupts ram (but you should not sidekiq!) ... 3x 4gb servers VM's iirc
<nofxx> key is indempodent, may fail and redo everytime thingies
<RickHull> is 1k/sec a reasonable ballpark rate for processing a log entry?
rmandev has joined #ruby
<nofxx> RickHull, pretty high.. that will be what? 3M day?
kazlock has quit [Quit: This computer has gone to sleep]
<RickHull> ignore if you actually receive that much traffic
<nofxx> 100M month
jeffreylevesque_ has quit [Ping timeout: 276 seconds]
<RickHull> just isolate the problem to, i have a big file available and need to consume it
dc4 has joined #ruby
<n|993|r> what is the rails cap for traffic anyways?
<n|993|r> like before it gets all slow and stuff
duckpupp1 has joined #ruby
__Yiota has joined #ruby
<nofxx> n|993|r, cap is your db, rails you can span 10 million VM's and load balance 'em
<n|993|r> whoa
<n|993|r> how does it do that?
<nofxx> it's not a only rails thing, neither new... look for "vertical vs horizontal scale scaling"
<lupine> lol
<n|993|r> oh
<lupine> yeah, with rails, you're going to need a few million VMs ^^
Log1x has quit [Quit: Quit]
<n|993|r> but if i have a large db wouldn't speed be the main factor?
<n|993|r> i mean algorithm efficiency*
zeroDi has quit [Quit: WeeChat 1.6]
<nofxx> the rule is, if you get a billion requests, you can pay 10 guys to write it in C for you
<nofxx> I don't get this worry about performance with frameworks
duckpupp1 has quit [Ping timeout: 240 seconds]
<nofxx> so 10 million become 10 thousand servers* heh
<lupine> if your answer is "rewrite it", you probably did it wrong
<nofxx> lupine, nope, you rewrite parts to save processing power, pretty common
<lupine> bit and pieces, sure
<lupine> not the whole thing
<n|993|r> this is why they just need to make frameworks in c
harai_ has joined #ruby
<n|993|r> and have other programming languages be simply templating languages that compile to c
<lupine> there is a pretty weird web application framework in C++
<lupine> Wt?
<nofxx> one case I've worked on: 100+ crud models, and sensor tracking. So it's 100 tables with ~ 20 entries and 1 with 50 million. Result: 99 controllers were rails, 1 was an erlang server writing to DB
<lupine> I'm not a fan
houhoulis has joined #ruby
blackbombay has joined #ruby
<Radar> !ban n|993|r
n|993|r was kicked from #ruby by ruby[bot] [bannable offense, see http://ruby-community.com/pages/user_rules]
Derperperd has joined #ruby
<nofxx> dunno now, but twitter did exactly that some years ago, rails was all the cruds, my info and whatnots. And the pushing and pulling tweets in scala
<Radar> Bad name.
<nofxx> I didn't get it =/
<Radar> nofxx: Convert the numbers to letters.
<nofxx> Radar, yeah, I did but I'm not versed... what's the 9?
<adam12> Trippy. Took me a while to figure it out too
<Radar> nofxx: G.
<nofxx> haha... k, so clear after you know
Devalo has joined #ruby
facest has quit [Ping timeout: 248 seconds]
Derperperd has quit [Ping timeout: 240 seconds]
Julianee has quit [Ping timeout: 255 seconds]
faces has joined #ruby
aryaching has quit [Ping timeout: 240 seconds]
<Radar> Been a while since I've seen one of them.
Devalo has quit [Ping timeout: 264 seconds]
aryaching has joined #ruby
harfangk has joined #ruby
gix has quit [Ping timeout: 240 seconds]
d^sh has quit [Ping timeout: 256 seconds]
kinduff has joined #ruby
d^sh has joined #ruby
bruce_lee has quit [Read error: Connection reset by peer]
toretore has quit [Ping timeout: 240 seconds]
kinduff is now known as nomames
nomames is now known as nomms
gix has joined #ruby
nettoweb1 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
blackmesa has quit [Ping timeout: 276 seconds]
c355e3b has quit [Quit: Connection closed for inactivity]
ur5us has joined #ruby
UnknownSoldier has quit [Remote host closed the connection]
nomms has quit [Quit: Textual IRC Client: www.textualapp.com]
libastral has quit [Ping timeout: 240 seconds]
libastral has joined #ruby
harai_ has quit [Ping timeout: 240 seconds]
xall has joined #ruby
tectonic has quit []
xall has quit [Ping timeout: 260 seconds]
mikecmpbll has quit [Quit: inabit. zz.]
milardovich has joined #ruby
nankyokusei has joined #ruby
dviola has quit [Quit: WeeChat 1.7]
kazlock has joined #ruby
milardovich has quit [Ping timeout: 258 seconds]
montanonic has quit [Ping timeout: 260 seconds]
nankyokusei has quit [Ping timeout: 260 seconds]
shakes has joined #ruby
jeffreylevesque has joined #ruby
armyriad has quit [Ping timeout: 258 seconds]
armyriad has joined #ruby
cstrahan has quit [Quit: Connection closed for inactivity]
milardovich has joined #ruby
Coldblackice has quit []
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
milardovich has quit [Ping timeout: 276 seconds]
pilne has quit [Quit: Quitting!]
ur5us has quit [Ping timeout: 255 seconds]
montanonic has joined #ruby
surfr1 has quit [Quit: Page closed]
Derperperd has joined #ruby
armyriad has quit [Ping timeout: 240 seconds]
Roa has quit [Ping timeout: 245 seconds]
armyriad has joined #ruby
Derperperd has quit [Ping timeout: 248 seconds]
Devalo has joined #ruby
Roa has joined #ruby
Trynemjoel has quit [Ping timeout: 264 seconds]
Devalo has quit [Ping timeout: 264 seconds]
skweek has quit [Remote host closed the connection]
milardovich has joined #ruby
djbkd_ has joined #ruby
rory_mckinley has quit [Ping timeout: 240 seconds]
xall has joined #ruby
milardovich has quit [Ping timeout: 240 seconds]
Derperperd has joined #ruby
houhoulis has quit [Ping timeout: 240 seconds]
JoshS has quit [Quit: Leaving]
Trynemjoel has joined #ruby
kht has quit [Ping timeout: 240 seconds]
nankyokusei has joined #ruby
shakes has quit [Quit: Leaving]
kazlock has quit [Quit: This computer has gone to sleep]
OTORelic has joined #ruby
rory_mckinley has joined #ruby
nankyokusei has quit [Ping timeout: 260 seconds]
anisha has joined #ruby
last_staff has joined #ruby
milardovich has joined #ruby
charliesome has joined #ruby
Phenix has joined #ruby
maloik has quit [Remote host closed the connection]
maloik has joined #ruby
skweek has joined #ruby
milardovich has quit [Ping timeout: 245 seconds]
jessiepuls has joined #ruby
brybeecher has quit [Ping timeout: 255 seconds]
LiquidInsect has quit [Read error: Connection reset by peer]
ruby303 has joined #ruby
LiquidInsect has joined #ruby
ruby303 has quit [Client Quit]
rory_mckinley has quit [Quit: Leaving]
xall has quit [Ping timeout: 240 seconds]
laphoriag75 has quit [Remote host closed the connection]
RickHull has quit [Quit: Leaving]
msmith has quit [Remote host closed the connection]
msmith has joined #ruby
msmith has quit [Remote host closed the connection]
gix has quit [Ping timeout: 255 seconds]
msmith has joined #ruby
msmith has quit [Remote host closed the connection]
msmith has joined #ruby
msmith has quit [Remote host closed the connection]
Channel6 has quit [Quit: Leaving]
gix has joined #ruby
OTORelic has quit [Ping timeout: 255 seconds]
immune has joined #ruby
blackwind_123 has joined #ruby
howdoi has joined #ruby
youch has joined #ruby
youch has quit [Ping timeout: 255 seconds]
ResidentBiscuit has joined #ruby
chouhoulis has joined #ruby
milardovich has joined #ruby
ResidentBiscuit has quit [Ping timeout: 255 seconds]
chouhoulis has quit [Ping timeout: 258 seconds]
Cohedrin_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
milardovich has quit [Ping timeout: 255 seconds]
brandon_ has joined #ruby
weerasak has joined #ruby
aryaching_ has joined #ruby
nankyokusei has joined #ruby
UnknownSoldier has joined #ruby
_geoff has quit [Ping timeout: 264 seconds]
aryaching has quit [Ping timeout: 255 seconds]
arescorpio has quit [Quit: Leaving.]
danguita has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
kazlock has joined #ruby
saneax-_-|AFK is now known as saneax
skweek has quit [Remote host closed the connection]
acalycine has joined #ruby
cyphase has quit [Ping timeout: 264 seconds]
acalycine has quit [Client Quit]
browndawg has joined #ruby
JoshS has joined #ruby
Cohedrin_ has joined #ruby
nofxxx has joined #ruby
jshjsh has joined #ruby
nofxx has quit [Ping timeout: 245 seconds]
acalycine has joined #ruby
JoshS has quit [Ping timeout: 258 seconds]
jshjsh is now known as JoshS
weerasak has quit [Ping timeout: 240 seconds]
Devalo has joined #ruby
djbkd_ has quit []
eizua has joined #ruby
ecuanaso has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ponga has joined #ruby
renchan has joined #ruby
RickHull has joined #ruby
Devalo has quit [Ping timeout: 264 seconds]
tlahtoani has quit [Quit: Connection closed for inactivity]
Imightbestupid12 has joined #ruby
msmith has joined #ruby
dc4 has quit [Ping timeout: 264 seconds]
Imightbestupid12 has quit [Ping timeout: 260 seconds]
_geoff has joined #ruby
Elytra is now known as TheThief
TheThief is now known as Elytra
aryaching_ has quit [Ping timeout: 240 seconds]
grh has joined #ruby
milardovich has joined #ruby
kazlock has quit [Remote host closed the connection]
kazlock has joined #ruby
kazlock_ has joined #ruby
danielpclark has joined #ruby
lxsameer has joined #ruby
<acalycine> i don't understand that ^ herwin
electrostat has quit [Ping timeout: 252 seconds]
<herwin> you can add the timezone to the datastring that you want to have parsed
<acalycine> Ah.
<herwin> or you could use things like Time.new, the best way to handle it would depend on your input format
<acalycine> No way to do that seperately, i.e. "timezone=AEDT; Time.parse("2017-01-29 22:00:00", timezone)?
<herwin> Use time.new
nankyokusei has joined #ruby
browndawg has quit [Quit: Leaving]
<acalycine> But it's processed through that code above
nankyokusei has quit [Ping timeout: 255 seconds]
Kug3lis has joined #ruby
aufi has joined #ruby
optiz0r has quit [Ping timeout: 240 seconds]
optiz0r has joined #ruby
grh has joined #ruby
blaxter has joined #ruby
conta has joined #ruby
nowhereman has quit [Ping timeout: 276 seconds]
milardovich has joined #ruby
<acalycine> That requires you to know the offset though, right?
milardovich has quit [Ping timeout: 276 seconds]
nowz has joined #ruby
Devalo has joined #ruby
ReK2GnULinuX has joined #ruby
ReK2GnULinuX has quit [Changing host]
ReK2GnULinuX has joined #ruby
andikr has joined #ruby
ReK2 has quit [Ping timeout: 240 seconds]
Pupeno has joined #ruby
Pupeno has quit [Changing host]
Pupeno has joined #ruby
Devalo has quit [Ping timeout: 264 seconds]
ur5us has joined #ruby
npgm has quit [Quit: Connection closed for inactivity]
govg has joined #ruby
<al2o3-cr> def self.gmt(time_str) time = Time.parse(time_str); (time + time.utc_offset).strftime("%I:%M %p") end # this should it no?
ur5us has quit [Ping timeout: 245 seconds]
<acalycine> Yep, that would work.
<acalycine> Just want to specify the timezone to convert to.
pandaant has joined #ruby
aganov has joined #ruby
Snickers has joined #ruby
danielpclark has quit [Read error: Connection reset by peer]
aryaching_ has joined #ruby
s2013 has joined #ruby
<al2o3-cr> acalycine: then use tzinfo like in the previous method
DoubleMalt has quit [Ping timeout: 240 seconds]
biberu has joined #ruby
<acalycine> Oh, good idea.
ResidentBiscuit has joined #ruby
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
aryaching has joined #ruby
aryaching_ has quit [Ping timeout: 260 seconds]
ResidentBiscuit has quit [Ping timeout: 255 seconds]
<acalycine> Looks good. Why is tz an arg?
<al2o3-cr> acalycine: doesn't have to be
<acalycine> Ah, yeah.
grh has quit [Ping timeout: 240 seconds]
SesMan has joined #ruby
dionysus69 has joined #ruby
dc4 has joined #ruby
antgel has joined #ruby
matp has quit [Remote host closed the connection]
matp has joined #ruby
jshjsh has joined #ruby
blackwind_123 has quit [Ping timeout: 240 seconds]
szulak has joined #ruby
msmith has joined #ruby
nankyokusei has joined #ruby
matcouto has joined #ruby
mark_66 has joined #ruby
JoshS has quit [Ping timeout: 240 seconds]
saneax is now known as saneax-_-|AFK
hrkpbo has joined #ruby
danielpclark has joined #ruby
nofxxx has quit [Ping timeout: 240 seconds]
milardovich has joined #ruby
Burgestrand has joined #ruby
nankyokusei has quit [Ping timeout: 260 seconds]
pandaant has quit [Remote host closed the connection]
grh has joined #ruby
aryaching_ has joined #ruby
milardovich has quit [Ping timeout: 245 seconds]
aryaching has quit [Ping timeout: 245 seconds]
Axy has quit [Read error: Connection reset by peer]
saneax-_-|AFK is now known as saneax
Mia has joined #ruby
Mia has quit [Changing host]
Mia has joined #ruby
Bish has quit [Read error: No route to host]
Pupeno has quit [Remote host closed the connection]
ta has joined #ruby
Pupeno has joined #ruby
montanonic has quit [Ping timeout: 240 seconds]
spider-mario has joined #ruby
djellemah has joined #ruby
aupadhye has joined #ruby
govg has quit [Ping timeout: 258 seconds]
Pupeno has quit [Ping timeout: 240 seconds]
govg has joined #ruby
DoubleMalt has joined #ruby
gigetoo has quit [Ping timeout: 255 seconds]
aryaching has joined #ruby
gigetoo has joined #ruby
troulouliou_div2 has joined #ruby
aryaching_ has quit [Ping timeout: 252 seconds]
Ropeney has quit [Quit: Textual IRC Client: www.textualapp.com]
csk157 has joined #ruby
vondruch has joined #ruby
danguita has quit [Quit: danguita]
msmith has quit [Ping timeout: 255 seconds]
gigetoo has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
saneax is now known as saneax-_-|AFK
danguita has joined #ruby
ocbtec has joined #ruby
charliesome has joined #ruby
sid_fules has joined #ruby
sid_fules has quit [Remote host closed the connection]
jenrzzz has joined #ruby
yaewa has joined #ruby
gigetoo has quit [Ping timeout: 248 seconds]
rileyy has joined #ruby
gigetoo has joined #ruby
saneax-_-|AFK is now known as saneax
jshjsh is now known as JoshS
moei has quit [Ping timeout: 255 seconds]
xall has joined #ruby
Takumo has joined #ruby
Takumo has joined #ruby
Takumo has quit [Changing host]
electrostat has joined #ruby
Ishido has joined #ruby
renchan has quit [Read error: Connection reset by peer]
renchan has joined #ruby
teclator has joined #ruby
saneax is now known as saneax-_-|AFK
DoubleMalt has quit [Ping timeout: 252 seconds]
milardovich has joined #ruby
al2o3-cr has quit [Quit: WeeChat 1.7]
eggshke has joined #ruby
flying has joined #ruby
Cohedrin_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
frozengeek__ has joined #ruby
flying has quit [Remote host closed the connection]
flying has joined #ruby
frozengeek__ has quit [Remote host closed the connection]
flying has quit [Remote host closed the connection]
Phenix has quit [Quit: Connection closed for inactivity]
conta has quit [Ping timeout: 248 seconds]
McSoFake has joined #ruby
nahra has quit [Remote host closed the connection]
gigetoo has quit [Ping timeout: 240 seconds]
nahra has joined #ruby
Silthias1 has joined #ruby
frozengeek__ has joined #ruby
manjaro-kde5-- has joined #ruby
milardovich has quit [Ping timeout: 255 seconds]
gigetoo has joined #ruby
Silthias has quit [Ping timeout: 240 seconds]
weerasak has joined #ruby
nankyokusei has joined #ruby
Kug3lis has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
TomyWork has joined #ruby
conta has joined #ruby
jackjackdripper has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
frozengeek__ has quit [Quit: frozengeek__]
frozengeek__ has joined #ruby
jsrn_ has joined #ruby
csk157_ has joined #ruby
gigetoo has quit [Ping timeout: 245 seconds]
jshjsh has joined #ruby
DoubleMalt has joined #ruby
Beams has joined #ruby
eggshke has quit []
consti has joined #ruby
JeanCarloMachado has joined #ruby
consti has quit [Client Quit]
gigetoo has joined #ruby
consti has joined #ruby
consti has quit [Client Quit]
mikecmpbll has joined #ruby
consti has joined #ruby
csk157 has quit [Ping timeout: 240 seconds]
JoshS has quit [Ping timeout: 256 seconds]
senayar has joined #ruby
senayar has quit [Changing host]
senayar has joined #ruby
nahra has quit [Remote host closed the connection]
csk157_ has quit [Ping timeout: 248 seconds]
milardovich has joined #ruby
milardovich has quit [Remote host closed the connection]
milardovich has joined #ruby
nahra has joined #ruby
xall has quit [Ping timeout: 255 seconds]
larcara has joined #ruby
gigetoo has quit [Ping timeout: 260 seconds]
toretore has joined #ruby
gigetoo has joined #ruby
aryaching_ has joined #ruby
JeanCarloMachado has quit [Remote host closed the connection]
ponga has quit []
lianj has quit [Ping timeout: 248 seconds]
harai_ has joined #ruby
JeanCarloMachado has joined #ruby
Devalo has joined #ruby
aryaching has quit [Ping timeout: 256 seconds]
RickHull has quit [Ping timeout: 255 seconds]
banisterfiend has joined #ruby
duderonomy has quit [Ping timeout: 276 seconds]
OverSpeed301 has joined #ruby
mim1k|work has joined #ruby
eizua has quit [Quit: Leaving]
Devalo has quit [Ping timeout: 276 seconds]
<OverSpeed301> Hello ! I have this nested hash : https://gist.github.com/anonymous/53182e67ad45fddd2438087edacda1d8 and I want to search in this hash if there is any value with, for example "Raw Plastic" and returning the hash if possible. I can't find how to search values in a nested hash. How I can do ? Thanks!
gigetoo has quit [Ping timeout: 240 seconds]
msmith has joined #ruby
gigetoo has joined #ruby
blackmesa has joined #ruby
postmodern has quit [Quit: Leaving]
tomphp has joined #ruby
asperon has joined #ruby
saneax-_-|AFK is now known as saneax
nahra has quit [Ping timeout: 264 seconds]
djbkd_ has joined #ruby
mikolaj9 has joined #ruby
csk157_ has joined #ruby
ferr1 has joined #ruby
<mikolaj9> i have trouble with (mruby) codedump_recur() anybody know what using this function? it is in -lmruby lib?
djbkd_ has quit [Ping timeout: 255 seconds]
gigetoo has quit [Ping timeout: 252 seconds]
asperon has left #ruby [#ruby]
gigetoo has joined #ruby
sid_fules has joined #ruby
csk157_ has quit [Ping timeout: 258 seconds]
sid_fules has quit [Remote host closed the connection]
ledestin has quit [Quit: Textual IRC Client: www.textualapp.com]
youch has joined #ruby
csk157_ has joined #ruby
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tomphp has joined #ruby
<danielpclark> @OverSpeed301 $testHash[:products].detect {|h| h[:productName] == "Raw Plastic" }
kassav has joined #ruby
<danielpclark> @OverSpeed301... also you have an extra comma after each array that needs to be removed
youch has quit [Ping timeout: 240 seconds]
<danielpclark> exit
<danielpclark> oops, wrong window :-)
nahra has joined #ruby
tomphp has quit [Ping timeout: 240 seconds]
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
<Mon_Ouie> It doesn't need to be removed, that's useful because you don't need to worry about adding/removing commas when you add/remove/swap elements at the end of the collection
nankyokusei has joined #ruby
<OverSpeed301> danielpclark "after each array", in composentOf ? :-)
aryaching has joined #ruby
<danielpclark> each product listing, your gist code isn't Ruby compatible with trailing commas on line 18 and 31
<danielpclark> so yes, after composentOf
bigkevmcd has joined #ruby
<herwin> danielpclark: that's perfectly valid
aryaching_ has quit [Ping timeout: 240 seconds]
nankyokusei has quit [Ping timeout: 245 seconds]
govg has quit [Ping timeout: 276 seconds]
<danielpclark> Ah, your right, it is valid. It was that tab indentation that wouldn't paste into irb. My bad
gigetoo has quit [Ping timeout: 258 seconds]
<OverSpeed301> danielpclark: Okay :) just a last question. if detect detects nothing, it triggers "undefined method `detect' for #<String:0[...]". How can I catch it ? (If detects detects something it runs without no problems).
etehtsea has joined #ruby
<OverSpeed301> Exact error is : "test.rb:50:in `block (2 levels) in <main>': undefined method `detect' for #<String:0x007f8cee16cc68> (NoMethodError)" (block is because I have two each before this line)
gigetoo has joined #ruby
msmith has quit [Ping timeout: 255 seconds]
Fernando-Basso has joined #ruby
<danielpclark> @OverSpeed301 The detect method is for collections not a String. The sample you gave says that $testHash[:products] returns an Array
aryaching has quit [Ping timeout: 252 seconds]
<danielpclark> If detect detects nothing it returns nil
mikolaj9 has left #ruby [#ruby]
bkxd has quit [Ping timeout: 240 seconds]
<danielpclark> If you need to make sure the item returned from an outer hash is an Array you can wrap it in Array() ... so Array($testHash[:products]).detect {|h| h[:productName] == "Raw Plastic" }
uranellus has quit [Quit: ZNC 1.6.1 - http://znc.in]
<danielpclark> would guarantee that the hash query of key :products will always have the detect method
weerasak has quit [Remote host closed the connection]
govg has joined #ruby
<danielpclark> But if you're having this issue then the structure isn't consistent and this likely means the code in detect for checking the inner hash will fail.
psychicist__ has joined #ruby
Raticide has left #ruby ["You're just a voice inside my head"]
nettoweb has joined #ruby
psychicist__ has quit [Client Quit]
<danielpclark> (because of that error) The more likely scenario is the way in which you're trying to get the inner data isn't right in the first place.
gigetoo has quit [Ping timeout: 245 seconds]
tvw has joined #ruby
gigetoo has joined #ruby
cyphase_eviltwin has joined #ruby
xen0fon has quit [Ping timeout: 248 seconds]
Pupeno has joined #ruby
<OverSpeed301> In fact I just want to check if this value exists
Pupeno has quit [Changing host]
Pupeno has joined #ruby
eggshke has joined #ruby
manjaro-kde5-- has quit [Read error: Connection reset by peer]
manjaro-kde5-- has joined #ruby
<OverSpeed301> If the value exists (Raw Plastic for example), I just need to append a string in composentOf, if it doesn't exists, I need to create it
blaxter has quit [Quit: foo]
psychicist__ has joined #ruby
nettoweb1 has joined #ruby
nettoweb has quit [Ping timeout: 240 seconds]
mayoral has joined #ruby
Pupeno has quit [Ping timeout: 255 seconds]
ReK2GnULinuX has quit [Ping timeout: 245 seconds]
Ishido has quit [Read error: Connection reset by peer]
<danielpclark> If the first code sample I gave you isn't working then the structure of the data you're working with doesn't match the sample you gave. Otherwise it'll do exactly what you want
<OverSpeed301> Yeap. I'm sorry, it was a typo problem in my code, I was replacing instead of appending to the existing. Sorry :-(
unshadow_ has joined #ruby
manjaro-kde5-- has quit [Ping timeout: 240 seconds]
ponga has joined #ruby
<danielpclark> It's cool. Glad I could be of help
gigetoo has quit [Ping timeout: 248 seconds]
unshadow has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
Fernando-Basso has quit [Quit: WeeChat 1.7]
<OverSpeed301> danielpclark: Works (very) well now. Big thanks ! :-)
blackmesa has quit [Quit: WeeChat 1.6]
nowz has quit [Quit: Leaving]
Julianee has joined #ruby
matcouto has quit [Quit: Textual IRC Client: www.textualapp.com]
blackbom1 has joined #ruby
Julianee has quit [Remote host closed the connection]
Julianee has joined #ruby
banisterfiend has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
gigetoo has quit [Ping timeout: 240 seconds]
BubonicPestilenc has joined #ruby
blackbombay has quit [Ping timeout: 256 seconds]
gigetoo has joined #ruby
Julianee has quit [Ping timeout: 255 seconds]
banisterfiend has joined #ruby
Ishido has joined #ruby
kht has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
frozengeek__ has quit [Read error: Connection reset by peer]
etehtsea has quit [Ping timeout: 240 seconds]
workmad3 has joined #ruby
gigetoo has quit [Ping timeout: 248 seconds]
nankyokusei has joined #ruby
ItTakesTwo has joined #ruby
gigetoo has joined #ruby
SesMan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<ItTakesTwo> hey folks, I have quiet some problems figuring out what's the error on this: server_port = response[0].split(" ", 2)[1].to_i
<ItTakesTwo> with ruby 2.1 I get undefined method `split' for nil:NilClass (NoMethodError)
<ItTakesTwo> already tried to circumvent this with try but get undefined method `try' for nil:NilClass (NoMethodError) as result
hrkpbo has quit [Ping timeout: 264 seconds]
kht has quit [Ping timeout: 260 seconds]
matp has quit [Remote host closed the connection]
nankyokusei has quit [Ping timeout: 252 seconds]
nahra has quit [Remote host closed the connection]
psychicist__ has quit [Ping timeout: 240 seconds]
matp has joined #ruby
jaruga_____ has joined #ruby
alewrb has joined #ruby
jaruga_____ is now known as jaruga______
jaruga______ has quit [Client Quit]
nahra has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
aryaching has joined #ruby
<manveru> ItTakesTwo: well, if response[0] is nil, then you might consider using an if :)
<manveru> server_port = response[0] ? response[0].split(" ", 2)[1].to_i : 0
<manveru> something like that
<manveru> i'm sure there's a better way, but no idea what `response` is
gigetoo has joined #ruby
bkxd has joined #ruby
bkxd has quit [Ping timeout: 240 seconds]
charliesome has joined #ruby
gigetoo has quit [Ping timeout: 255 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Mortomes|Work has joined #ruby
gigetoo has joined #ruby
UserJosh has joined #ruby
<ItTakesTwo> manveru: that fixed it, thank you! :D
<blackbom1> ItTakesTwo: try comes from activesupport btw, but ruby has syntax you can use like that: response[0]&.split(" ", 2)[1].to_i
jshjsh has quit [Ping timeout: 240 seconds]
<blackbom1> heh sorry, i guess &. isn't useful there
<blackbom1> i don't know how it can be used with []
<herwin> blackbom1: "< ItTakesTwo> with ruby 2.1 ..."
diadara has joined #ruby
<blackbom1> yeah. i think that came in 2.2
Devalo has joined #ruby
gigetoo has quit [Ping timeout: 260 seconds]
gigetoo has joined #ruby
dc4 has quit [Ping timeout: 258 seconds]
Devalo has quit [Ping timeout: 264 seconds]
SesMan has joined #ruby
McSoFake has quit [Quit: WeeChat 1.7]
<herwin> 2.3
nfk has joined #ruby
harai_ has quit [Ping timeout: 258 seconds]
rileyy has quit [Read error: Connection reset by peer]
BubonicPestilenc has quit [Quit: Textual IRC Client: www.textualapp.com]
jackjackdripper has quit [Quit: Leaving.]
Guest63 has joined #ruby
Ishido has quit [Read error: Connection reset by peer]
<Guest63> Hey there
eggshke has quit []
Guest63 has quit [Client Quit]
Ishido has joined #ruby
andremaha has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
nankyokusei has joined #ruby
nobitanobi has joined #ruby
jshjsh has joined #ruby
andremaha has quit [Quit: Textual IRC Client: www.textualapp.com]
nankyokusei has quit [Ping timeout: 264 seconds]
<nobitanobi> hello - I have a question. When do you decide whether or not using a constant is a good idea? Say I have a method that looks something like this: https://gist.github.com/novito/c97cc87d63d1eac5694a64f88ded6bb5 - would you put 3 or 0 as constants? Why or why not?
Ishido has quit [Read error: Connection reset by peer]
UserJosh has quit [Ping timeout: 240 seconds]
gigetoo has quit [Ping timeout: 240 seconds]
<danielpclark> I wouldn't use constants for changing values so I wouldn't have them used in if conditions
<danielpclark> but you can if you (really) want to
<danielpclark> I use constants to point to more permanent objects or values
gigetoo has joined #ruby
wralwral has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
jshjsh has quit [Ping timeout: 240 seconds]
wralwral has quit [Client Quit]
nettoweb1 has quit [Ping timeout: 255 seconds]
nettoweb has joined #ruby
acalycine has quit [Quit: bye]
msmith has joined #ruby
bkxd has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
<nobitanobi> @danielpclark thanks
bkxd has quit [Ping timeout: 245 seconds]
Julianee has joined #ruby
<danielpclark> @nobitanobi Version is usually declared as MyProject::VERSION = "0.1.0"
<nobitanobi> @danielpclark it's an inner class, not the project class itself.
<danielpclark> For a class version you can use @@class_version = 10
<danielpclark> Using class variables isn't that common though
<danielpclark> Also that would be best if it's only manually changed by a developer
<blackbom1> class variables are as evil as global variables
Pupeno has joined #ruby
Pupeno has quit [Changing host]
Pupeno has joined #ruby
<danielpclark> Yep. But if they don't change (while the code is running) they're acceptable
gigetoo has quit [Ping timeout: 276 seconds]
tectonic has joined #ruby
DoubleMalt has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
psychicist__ has joined #ruby
<KrzaQ> "%{foo}" % { "foo" => 23 } # <-- this used to work for me, but doesn't anymore with ruby 2.4.0. What gives?
sepp2k has joined #ruby
Pupeno has quit [Ping timeout: 255 seconds]
dopamean_ has joined #ruby
dopamean1 has quit [Ping timeout: 240 seconds]
etehtsea has joined #ruby
<danielpclark> @KrzaQ: it's now "%{foo}" % {:"foo" => 23}
cyphase_eviltwin is now known as cyphase
<manveru> >> "%{foo}" % { foo: 23 }
<ruby[bot]> manveru: # => "23" (https://eval.in/726714)
tectonic has quit []
<KrzaQ> I get the object I want to print from json
<manveru> well, it needs symbol keys now
blaxter has joined #ruby
<KrzaQ> ...
<KrzaQ> Let's interpret it as clever and eloquent expression of my disappointment
<danielpclark> :"foo"
<manveru> :foo == :"foo", no need for the quotes
alewrb has quit [Remote host closed the connection]
senayar has quit []
<danielpclark> I know, I typed it in the wrong window :-/
diadara has quit [Ping timeout: 260 seconds]
Devalo has joined #ruby
etehtsea has quit [Ping timeout: 245 seconds]
xall has joined #ruby
<manveru> KrzaQ: how many dimensions does your hash have?
<KrzaQ> manveru: it's one
gigetoo has quit [Read error: Connection reset by peer]
<KrzaQ> What's the rationale behind this change? Is ruby going to be statically typed next? :P
gigetoo has joined #ruby
<blackbom1> that's v3
<blackbom1> :D
<manveru> well, i hadn't even noticed this change...
nobitanobi has quit [Remote host closed the connection]
<KrzaQ> seriously though, I don't see the upside, but it broke my code
<blackbom1> try find the corresponding commit
Devalo has quit [Ping timeout: 264 seconds]
<blackbom1> or redmine issue
<KrzaQ> I'm not sure how this % thing is called
sdothum has joined #ruby
nankyokusei has joined #ruby
<KrzaQ> string interpolation?
m4rCsi has joined #ruby
<blackbom1> it's a method on String
<blackbom1> yeah string interpolation
msmith has quit [Ping timeout: 255 seconds]
JoshS has joined #ruby
nankyokusei has quit [Ping timeout: 245 seconds]
nettoweb1 has joined #ruby
djellemah has quit [Ping timeout: 252 seconds]
synthroid has joined #ruby
<Burgestrand> KrzaQ didn't work in 2.0 either https://eval.in/726741
nfk has quit [Quit: Try memory.free_dirty_pages=true in about:config]
<Burgestrand> KrzaQ from what I can see it has not been changed, it's been symbols only since 1.9.3
m4rCsi has quit [Ping timeout: 276 seconds]
<Burgestrand> KrzaQ 1.8.7 didn't support %{name}-syntax
Definity has joined #ruby
<Burgestrand> KrzaQ if you want to be clever you could work around it, like this:
<Burgestrand> >> "Hello %{name}" % Hash.new { |_, k| k.to_s.upcase }
<ruby[bot]> Burgestrand: # => "Hello NAME" (https://eval.in/726752)
gigetoo has quit [Ping timeout: 240 seconds]
nettoweb has quit [Ping timeout: 245 seconds]
<Burgestrand> KrzaQ if I were you I'd be more concerned about why it worked in the past but not any more, considering it hasn't changed :)
<herwin> or just use one of the many templating engines instead of string interpolation
m4rCsi has joined #ruby
gigetoo has joined #ruby
ddffg has quit [Ping timeout: 240 seconds]
DaveTaboola has joined #ruby
djuber` has joined #ruby
xall has quit [Ping timeout: 258 seconds]
workmad3 has quit [Ping timeout: 240 seconds]
Mortomes|Work has quit [Ping timeout: 260 seconds]
jeffreylevesque has quit [Ping timeout: 256 seconds]
Cymew has quit [Remote host closed the connection]
alibby has joined #ruby
mark_66 has left #ruby ["PING 1485782006"]
mayoral has quit [Quit: Textual IRC Client: www.textualapp.com]
ruby228 has joined #ruby
djuber` has quit [Ping timeout: 264 seconds]
gigetoo has quit [Read error: Connection reset by peer]
al2o3-cr has joined #ruby
gigetoo has joined #ruby
dopamean_ has quit [Ping timeout: 255 seconds]
<ruby228> Hello I have a planning model which belongs to a Purchase, and I want to do something like @purchases.map(&:planning).map(&:year) but I got the error undefined method `year' for #<Planning::ActiveRecord_Associations_CollectionProxy
<ruby228> do you guys have an idea on how can I solve this?
tvw has quit [Ping timeout: 255 seconds]
rwb has quit [Ping timeout: 260 seconds]
tvw has joined #ruby
sniffer has quit [Ping timeout: 245 seconds]
rikai has quit [Ping timeout: 245 seconds]
gnufied has joined #ruby
blackwind_123 has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
gheegh has joined #ruby
bkxd has joined #ruby
frozengeek__ has joined #ruby
gigetoo has joined #ruby
saneax is now known as saneax-_-|AFK
c355e3b has joined #ruby
<gheegh> hey all.. quick question.. I've got a regex that's working via Rubular.. but when I try to use it in ruby.. its failing.. (in a test, controlled). both escaped simply converted in to a regex.. its produced via a script, so I can't just // it.. any thoughts on what i'm doing wrong?
djellemah has joined #ruby
<Burgestrand> ruby228 reading the limited information you gave us in your error message it appears that Purchase#planning could be a collection of items, and not a single one, is this correct?
<Burgestrand> ?code gheegh
<ruby[bot]> gheegh: We can't help you without your code, please post it to https://gist.github.com
Julianee has quit [Remote host closed the connection]
<gheegh> yep. coming..
tuelz has joined #ruby
jeffreylevesque has joined #ruby
bkxd has quit [Ping timeout: 256 seconds]
<Burgestrand> gheegh it looks like you're double-escaping your regex
<gheegh> yeah, fork without that
Julianee has joined #ruby
<gheegh> same result: https://eval.in/726805
<gheegh> as in no results.. :-)
<gheegh> this works in Rubular
millerti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Burgestrand> gheegh no, I mean, why do you do Regexp.escape over your entire wrapper?
<herwin> Regexp.union does exactly what you want
<herwin> including escapes
<Burgestrand> gheegh i.e. you don't want to escape "\w+"
<gheegh> i'm trying to match the word and the /label.. this is for featureextraction
<gheegh> like a Parts of Speech tagger.. but in this case it's for an Address detector
Derperperd has quit [Ping timeout: 245 seconds]
<gheegh> so the patterns are very controlled.. so i don't need to escape them
lxsameer has quit [Ping timeout: 240 seconds]
saneax-_-|AFK is now known as saneax
jshjsh has joined #ruby
<gheegh> totally unescaped doersn't work either.. and this one shows what the output should be.. and links to a rubular shortcut that shows the working version https://eval.in/726812
gigetoo has quit [Ping timeout: 264 seconds]
ruby228 has quit [Quit: Page closed]
<gheegh> herwin: yeah, the union doesn't work.. because i'm not trying to match the labels.. i'm trying to match the word containing the label... but only in the context where they are in a specific label sequence.
tvw has quit []
gigetoo has joined #ruby
zeroDi has joined #ruby
tvw has joined #ruby
JoshS has quit [Ping timeout: 256 seconds]
Beams has quit [Quit: .]
Julianee has quit [Remote host closed the connection]
kassav has quit [Read error: No route to host]
nankyokusei has joined #ruby
kassav_ has joined #ruby
zeroDi has quit [Read error: Connection reset by peer]
kassav_ is now known as kassav
zeroDi has joined #ruby
rfoust has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Mortomes|Train has joined #ruby
<Burgestrand> gheegh print your regex, see what it looks like, before you use it, e.g. on line 11
brainslug has quit [*.net *.split]
brainslug has joined #ruby
<gheegh> Burgestrand: https://eval.in/726841
<gheegh> ok.. managed to get it: the \w needed to be escaped. https://eval.in/726842
<Burgestrand> gheegh :)
<Burgestrand> gheegh it's the same with your \s by the way
nankyokusei has quit [Ping timeout: 256 seconds]
<Burgestrand> gheegh also, do note you can also use interpolation in //-literals, so you don't need to escape the string
Cymew has joined #ruby
<al2o3-cr> gheegh: key_pattern_regex_string = pattern_array.map { |item| %r{(\w+/#{item})\s+} }.join # try this
<Burgestrand> >> string = "Hello"; /\w#{string}\s/
<ruby[bot]> Burgestrand: # => /\wHello\s/ (https://eval.in/726856)
<gheegh> yep.. got it. Ok.. i didn't know that..
<al2o3-cr> oh nvm then
Cymew has quit [Remote host closed the connection]
Beams has joined #ruby
<gheegh> yeah, if i'm doing them one off.. i'll def do that.. but in this case, i have to build a unique regex for hte pattern
<Burgestrand> gheegh your "/" will make things rough on you however, since Ruby will think the regex ends there, so you either need to escape that or change the regex delimiter
last_staff has quit [Quit: **poof**]
<Burgestrand> >> /Hello \/ Regex/
<ruby[bot]> Burgestrand: # => /Hello \/ Regex/ (https://eval.in/726857)
gigetoo has quit [Ping timeout: 240 seconds]
<gheegh> yeah, thats' a pretty common pattern though in Parts of Speech taggers
<Burgestrand> >> %r"Hello / Regex"
<ruby[bot]> Burgestrand: # => /Hello \/ Regex/ (https://eval.in/726859)
<gheegh> which is why it was used.
anisha has quit [Quit: This computer has gone to sleep]
<gheegh> but i'll consider changing it.
<Burgestrand> gheegh whatever you feel makes more sense to you and any other eyeballs on this :)
Cymew has joined #ruby
<gheegh> its a good point.. if its all going to be done with regex patterns, using the regex delimiter isn't a smart idea. i agree.. :-)
gigetoo has joined #ruby
<Burgestrand> gheegh a final note, if you run into performance issues with this regex it's probably worth trying to turn it into a union regex with the pipe |
<gheegh> we do that to put the labels on
<gheegh> :-) but taking them off requires the specific sequence of patterns, and we don't know the words they'll be attached to..
<gheegh> so, one other question.. on the end.. i'd love to match either a space OR the end of the string.. wihtout matching it as a pattern
<Burgestrand> gheegh couldn't you do a pattern such as: %r"\w+/(ZP|XX|RT)"?
<gheegh> no
<Burgestrand> gheegh alright
<gheegh> i'm looking for the case where the word has the label ZP then the word has the label XX then the word has the label RT in that order..
browndawg has joined #ruby
<gheegh> its that specific sequence, in that particular order..
<Burgestrand> gheegh ah, I see
<Burgestrand> gheegh i.e. if you get ZP, RT, you do not want to match it
<gheegh> yep..
<Burgestrand> gheegh you can use non-capturing groups for that last question btw
<Burgestrand> gheegh (?:A|B)
danguita has quit [Remote host closed the connection]
<Burgestrand> gheegh (?:\s|\z)
<Burgestrand> gheegh (keep in mind \s is not only space, it's also tabs and newlines)
<gheegh> yeah, sorry.. totally worked.. don't exercise my regex muscles enough.
ItTakesTwo has left #ruby [#ruby]
<Burgestrand> gheegh there's a first time for encountering anything, don't feel sorry :)
<gheegh> :-) thanks man.
<gheegh> in the gender neutral sense.. :-)
<Burgestrand> ;)
jessiepuls has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Julianee has joined #ruby
sylario has joined #ruby
DoubleMalt has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
duckpupp1 has joined #ruby
nettoweb1 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
andremaha has joined #ruby
nettoweb has joined #ruby
conta has quit [Quit: conta]
workmad3 has joined #ruby
milardovich has quit [Remote host closed the connection]
conta has joined #ruby
milardovich has joined #ruby
Guest6291 has quit [Ping timeout: 276 seconds]
_geoff has joined #ruby
youch has joined #ruby
msmith has joined #ruby
Julianee has quit [Remote host closed the connection]
nirix has quit [Quit: ZNC - http://znc.in]
SHyx0rmZ has quit [Remote host closed the connection]
tvw has quit []
tvw has joined #ruby
statelesscode has quit [Ping timeout: 240 seconds]
redhedded1 has quit [Quit: Textual IRC Client: www.textualapp.com]
msmith has quit [Remote host closed the connection]
ramortegui has joined #ruby
milardovich has quit [Ping timeout: 276 seconds]
msmith has joined #ruby
aryaching has quit [Ping timeout: 264 seconds]
SHyx0rmZ has joined #ruby
youch has quit [Ping timeout: 245 seconds]
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
pskosinski has joined #ruby
pskosinski is now known as Guest85987
brendan- has quit [Ping timeout: 256 seconds]
kht has joined #ruby
andremaha has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Guest85987 has quit [Ping timeout: 240 seconds]
jhack has joined #ruby
bmurt has joined #ruby
ifctj has joined #ruby
statelesscode has joined #ruby
milardovich has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
andremaha has joined #ruby
Tristan-Speccy has joined #ruby
Tristan-Speccy is now known as Guest37057
Julianee has joined #ruby
gigetoo has joined #ruby
tlaxkit has joined #ruby
jshjsh has quit [Ping timeout: 245 seconds]
malconis has joined #ruby
bkxd has joined #ruby
ifctj has quit [Ping timeout: 240 seconds]
ecuanaso has joined #ruby
milardovich has quit [Ping timeout: 255 seconds]
dionysus70 has joined #ruby
rfoust has joined #ruby
Julianee has quit [Remote host closed the connection]
Julianee has joined #ruby
dionysus69 has quit [Ping timeout: 240 seconds]
dionysus70 is now known as dionysus69
nankyokusei has joined #ruby
bkxd has quit [Ping timeout: 264 seconds]
lmc has joined #ruby
Julianee has quit [Ping timeout: 255 seconds]
polishdub has joined #ruby
__Yiota has joined #ruby
griffindy has joined #ruby
astrobunny has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
grh has quit [Quit: Ex-Chat]
grh has joined #ruby
Snickers has quit [Ping timeout: 240 seconds]
gigetoo has quit [Ping timeout: 258 seconds]
gigetoo has joined #ruby
Ishido has joined #ruby
Mortomes|Train has quit [Ping timeout: 260 seconds]
malconis_ has joined #ruby
DLSteve has joined #ruby
DLSteve has quit [Client Quit]
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
astrobunny has quit [Remote host closed the connection]
astrobunny has joined #ruby
danguita has joined #ruby
koldbrutality has quit [Ping timeout: 240 seconds]
malconis has quit [Ping timeout: 260 seconds]
jrafanie has joined #ruby
dopamean_ has joined #ruby
<KrzaQ> Burgestrand: I stand corrected. But I swear it used to work...
anisha has joined #ruby
Julianee has joined #ruby
spiette has joined #ruby
ta has quit [Remote host closed the connection]
JoshS has joined #ruby
ecuanaso has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
gigetoo has quit [Ping timeout: 255 seconds]
millerti has joined #ruby
pskosinski has joined #ruby
pskosinski is now known as Guest26737
Devalo has joined #ruby
tuelz has quit [Quit: WeeChat 1.7]
gigetoo has joined #ruby
is_null has quit [Quit: github.com/jpic]
anisha has quit [Quit: This computer has gone to sleep]
youch has joined #ruby
DLSteve has joined #ruby
nettoweb has joined #ruby
jshjsh has joined #ruby
JoshS has quit [Ping timeout: 240 seconds]
etehtsea has joined #ruby
Xentil has joined #ruby
milardovich has joined #ruby
Guest26737 has quit [Ping timeout: 240 seconds]
Devalo has quit [Ping timeout: 276 seconds]
tomphp has joined #ruby
jessiepuls has joined #ruby
pskosinski_ has joined #ruby
haylon has joined #ruby
_geoff_ has joined #ruby
milardovich has quit [Ping timeout: 260 seconds]
Toledo has joined #ruby
ifctj has joined #ruby
_geoff has quit [Ping timeout: 260 seconds]
gigetoo has quit [Ping timeout: 240 seconds]
pskosinski_ has quit [Ping timeout: 264 seconds]
gigetoo has joined #ruby
bmurt has quit [Read error: No route to host]
bmurt has joined #ruby
chouhoulis has joined #ruby
brendan- has joined #ruby
grh has quit [Ping timeout: 264 seconds]
Julianee has quit []
browndawg has quit [Quit: Leaving]
UnknownSoldier has joined #ruby
rippa has joined #ruby
troulouliou_div2 has quit [Remote host closed the connection]
hutch34 has quit [Ping timeout: 255 seconds]
youch has quit [Ping timeout: 252 seconds]
cdg_ has joined #ruby
gigetoo has quit [Ping timeout: 256 seconds]
gigetoo has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
kht has quit [Ping timeout: 258 seconds]
troulouliou_div2 has joined #ruby
milardovich has joined #ruby
ferr1 has quit [Quit: WeeChat 1.6]
Snickers has joined #ruby
nankyokusei has joined #ruby
dopamean_ has quit [Quit: WeeChat 1.3]
ifctj has quit [Ping timeout: 240 seconds]
nankyokusei has quit [Ping timeout: 276 seconds]
youch has joined #ruby
msmith has quit [Remote host closed the connection]
agent_white has joined #ruby
agent_white has quit [Changing host]
agent_white has joined #ruby
gigetoo has quit [Ping timeout: 276 seconds]
msmith has joined #ruby
<agent_white> Mornin' folks
gigetoo has joined #ruby
tomphp has quit [Ping timeout: 245 seconds]
msmith has quit [Read error: Connection reset by peer]
msmith has joined #ruby
tuelz has joined #ruby
<tuelz> what kind of error would yall throw in a lib that has a class method and in the class method it's required you set some ivar before you call it?
kht has joined #ruby
<tuelz> so the error in question would be thrown if they haven't set the ivar yet and try to call the method
dionysus69 has quit [Ping timeout: 255 seconds]
bkxd has joined #ruby
<tuelz> i.e. I'm hitting a 3rd party api to get some info and I need to set an address before calling the method that would make a request to the 3rd party api
<tuelz> (just looking to write idiomatic code)
saneax is now known as saneax-_-|AFK
tomphp has joined #ruby
patarr has joined #ruby
<toretore> tuelz: why is this inconsistency allowed to occur in the first place?
bmurt has joined #ruby
szulak has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
gigetoo has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
astrobunny has quit [Read error: Connection reset by peer]
astrobunny has joined #ruby
<tuelz> toretore: well it's a user defined address so I have to throw an error somewhere if they try to use the lib without setting the address
<tuelz> where would you prefer to have them set the address? On obj instantiation?
<apeiros> tuelz: a custom error subclassing from StandardError
<tuelz> apeiros: sounds good, thanks
<apeiros> if you can avoid the inconsistency in the first place, that'd of course be better (re toretore's line of questions)
<tuelz> I'm not sure I'm understanding what yall mean by avoiding the inconsistency in this example
<tuelz> do you mean try and find a way to make address not user defined?
<toretore> tuelz: this error shouldn't happen at all. the problem is that your functionality depends on shared state, and you can remedy this in 2 ways: 1) always require this state to be provided explicitly upon calling a method, or 2) hide the state such that you have complete control of it
<toretore> 1 is `def call_api(url, foo, bar)`; 2 is `class ApiCaller; def initislize(u); @u=u; end; def call(foo, bar); ...; end; end`
<tuelz> gotcha, I get what you're saying now
<tuelz> I think 2 is more in line with what I was trying to achieve
<tuelz> thanks
szulak has joined #ruby
s2013 has joined #ruby
<tuelz> so I'll still use a custom error, just call it on obj init rather than have the user know they need to call a setter method
<toretore> why? if they don't provide the argument, it will raise an error
dionysus69 has joined #ruby
govg has quit [Ping timeout: 276 seconds]
dionysus69 has quit [Client Quit]
astrobunny has quit [Read error: Connection reset by peer]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<toretore> "to instantiate an object of this class you must provide this argument, which is a url"
<toretore> you don't need more than that
bkxd has quit [Ping timeout: 252 seconds]
teclator has quit [Ping timeout: 276 seconds]
chouhoulis has quit [Remote host closed the connection]
<tuelz> toretore: makes sense, thanks
gigetoo has quit [Ping timeout: 256 seconds]
gigetoo has joined #ruby
ldnunes has joined #ruby
harai_ has joined #ruby
choke has joined #ruby
lxsameer has joined #ruby
choke has quit [Ping timeout: 240 seconds]
etehtsea has quit [Quit: Computer has gone to sleep.]
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
kht has quit [Ping timeout: 256 seconds]
tvw has quit []
CloCkWeRX has quit [Quit: Leaving.]
nankyokusei has joined #ruby
kht has joined #ruby
OverSpeed301 has quit [Ping timeout: 240 seconds]
Burgestrand has quit [Quit: Closing time!]
cdg has joined #ruby
tomphp has quit [Ping timeout: 240 seconds]
cdg_ has quit [Ping timeout: 256 seconds]
ddffg has joined #ruby
BitWhisperer has quit [Ping timeout: 258 seconds]
blackwind_123 has quit [Ping timeout: 248 seconds]
Snickers has quit [Quit: Snickers]
cdg_ has joined #ruby
synthroid has quit [Remote host closed the connection]
csk157_ has quit [Ping timeout: 252 seconds]
nankyokusei has quit [Ping timeout: 255 seconds]
BitWhisperer has joined #ruby
cdg has quit [Read error: Connection reset by peer]
cdg has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
aganov has quit [Remote host closed the connection]
d10n-work has joined #ruby
gigetoo has joined #ruby
antgel has quit [Ping timeout: 245 seconds]
cdg__ has joined #ruby
cdg_ has quit [Ping timeout: 240 seconds]
szulak has quit [Quit: Textual IRC Client: www.textualapp.com]
etehtsea has joined #ruby
cdg has quit [Ping timeout: 276 seconds]
Derperperd has joined #ruby
blackwind_123 has joined #ruby
brybeecher has joined #ruby
Takumo has quit [Remote host closed the connection]
gnufied has quit [Remote host closed the connection]
tvw has joined #ruby
aryaching has joined #ruby
brent__ has joined #ruby
gnufied has joined #ruby
sepp2k has quit [Quit: Leaving.]
montanonic has joined #ruby
gigetoo has quit [Ping timeout: 256 seconds]
gigetoo has joined #ruby
Toledo is now known as croberts
antgel has joined #ruby
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
montanonic has quit [Ping timeout: 255 seconds]
teclator has joined #ruby
ocbtec has quit [Quit: leaving]
jrafanie has joined #ruby
shinnya has joined #ruby
johnny56 has joined #ruby
ReK2 has joined #ruby
ReK2 has joined #ruby
ReK2 has quit [Changing host]
gigetoo has quit [Ping timeout: 240 seconds]
agent_white has quit [Quit: brb]
ocbtec has joined #ruby
nowhereman has joined #ruby
LarryWall has joined #ruby
<LarryWall> I love python!
gigetoo has joined #ruby
<leah2> you are one poor troll
jhack has quit [Quit: jhack]
<LarryWall> damn, outed already.
LarryWall is now known as \oren\
cajone has left #ruby [#ruby]
agent_white has joined #ruby
mic_e has quit [Ping timeout: 240 seconds]
\oren\ has left #ruby [#ruby]
conta has quit [Ping timeout: 264 seconds]
mic_e has joined #ruby
bkxd has joined #ruby
cdg__ has quit [Ping timeout: 276 seconds]
milardovich has quit [Remote host closed the connection]
milardovich has joined #ruby
brybeecher has quit [Quit: Ex-Chat]
brybeecher_ has joined #ruby
<apeiros> lol?
d^sh_ has joined #ruby
<apeiros> leah2 got the trolldar :D
<leah2> also i know larry walls real nick :P
nankyokusei has joined #ruby
synthroid has joined #ruby
d^sh has quit [Ping timeout: 252 seconds]
<apeiros> leah2: oh?
<apeiros> well, he's old enough to be on irc since its inception…
<leah2> not sure if he used irc much before #perl6 tbh
<apeiros> leah2: is it rasmuslerdorf? :D
<leah2> :D
jhack has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
bkxd has quit [Ping timeout: 256 seconds]
milardovich has quit [Ping timeout: 245 seconds]
danguita has quit [Remote host closed the connection]
gigetoo has joined #ruby
cpruitt has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
milardovich has joined #ruby
UnknownSoldier has quit [Remote host closed the connection]
username_ has joined #ruby
montanonic has joined #ruby
biox has quit [Quit: brb servers are ded]
Devalo has joined #ruby
biox has joined #ruby
[Butch] has joined #ruby
milardovich has quit [Ping timeout: 248 seconds]
nowhereman has quit [Ping timeout: 258 seconds]
prestorium has joined #ruby
kassav has quit [Ping timeout: 240 seconds]
tdy has quit [Quit: WeeChat 1.7]
montanonic has quit [Ping timeout: 255 seconds]
tdy has joined #ruby
Devalo has quit [Ping timeout: 264 seconds]
chouhoulis has joined #ruby
omphe has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
milardovich has joined #ruby
cloaked1 has quit [Quit: leaving]
amclain has joined #ruby
marxarelli|afk has quit [Quit: Textual IRC Client: www.textualapp.com]
marxarelli has joined #ruby
markholmes has joined #ruby
<sonOfRa> In complicated code with multiple branches, should I make my returns explicit? https://gist.github.com/sonOfRa/84bc10676cfead7173e12097ad750093
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<sonOfRa> It feels odd to put explicit returns into simple code, it feels wrong not to have them in complicated code, but it also feels odd to have mixed explicit and implicit returns throughout the code base
milardovich has quit [Ping timeout: 255 seconds]
<mikecmpbll> sonOfRa : nah
conta has joined #ruby
troulouliou_div2 has quit [Quit: Leaving]
SesMan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Beams has quit [Quit: .]
sepp2k has joined #ruby
cajone has joined #ruby
lizard2010 has joined #ruby
lizard2010 has quit [Remote host closed the connection]
gigetoo has quit [Ping timeout: 260 seconds]
andremaha has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
conta has quit [Ping timeout: 252 seconds]
aryaching has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
milardovich has joined #ruby
tvw has quit [Remote host closed the connection]
aryaching has joined #ruby
milardovich has quit [Ping timeout: 255 seconds]
msmith has quit [Remote host closed the connection]
msmith has joined #ruby
cajone has left #ruby [#ruby]
gigetoo has quit [Read error: Connection reset by peer]
andikr has quit [Remote host closed the connection]
gigetoo has joined #ruby
saneax-_-|AFK is now known as saneax
msmith has quit [Ping timeout: 240 seconds]
milardovich has joined #ruby
cajone has joined #ruby
etehtsea has quit [Quit: Textual IRC Client: www.textualapp.com]
etehtsea has joined #ruby
tlaxkit has quit [Ping timeout: 252 seconds]
raspado has joined #ruby
<raspado> hi all, im trying to append a string to pass into a library to connect to postgres, im getting an error "`<main>': undefined method `+' for nil:NilClass (NoMethodError)" for this http://pastebin.com/LWgcBJGd
<ruby[bot]> raspado: as I told you already, please use https://gist.github.com
<havenwood> raspado: $options[:cloud] #=> nil
nankyokusei has joined #ruby
<raspado> hmmm
<raspado> ok thx havenwood
<raspado> oooo yes
<raspado> thx havenwood :)
milardovich has quit [Ping timeout: 260 seconds]
jsrn_ has quit [Read error: Connection reset by peer]
__Yiota has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
gigetoo has quit [Ping timeout: 240 seconds]
nankyokusei has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
lmc has quit [Remote host closed the connection]
mikecmpbll has quit [Ping timeout: 255 seconds]
genpaku has quit [Ping timeout: 255 seconds]
yokel has quit [Ping timeout: 258 seconds]
aupadhye has quit [Ping timeout: 256 seconds]
lmc has joined #ruby
markholmes has quit [Remote host closed the connection]
tuelz has quit [Quit: WeeChat 1.7]
genpaku has joined #ruby
yokel has joined #ruby
<apeiros> sonOfRa: method extraction - put the connect block into its own method
shinnya has quit [Quit: ZNC - http://znc.in]
blaxter has quit [Quit: foo]
pilne has joined #ruby
aufi has quit [Quit: Leaving]
__Yiota has joined #ruby
mochiyoda has quit [Ping timeout: 255 seconds]
shinnya has joined #ruby
bkxd has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
Kug3lis has joined #ruby
UnknownSoldier has joined #ruby
__Yiota has quit [Ping timeout: 255 seconds]
bkxd has quit [Ping timeout: 255 seconds]
gnufied has quit [Ping timeout: 255 seconds]
tuelz has joined #ruby
montanonic has joined #ruby
jhack has quit [Quit: jhack]
gigetoo has quit [Ping timeout: 240 seconds]
anotherpi has joined #ruby
gigetoo has joined #ruby
jhack has joined #ruby
antgel has quit [Ping timeout: 248 seconds]
<manveru> sonOfRa: well, definitely use `return false unless user.is_a?(User)` at the beginning instead of having if/else :)
milardovich has joined #ruby
haylon has quit [Ping timeout: 240 seconds]
haylon has joined #ruby
montanonic has quit [Ping timeout: 240 seconds]
etehtsea has quit [Quit: Textual IRC Client: www.textualapp.com]
rwb has joined #ruby
milardovich has quit [Ping timeout: 240 seconds]
jhack has quit [Ping timeout: 240 seconds]
jhack has joined #ruby
gnufied has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
whathappens has joined #ruby
nankyokusei has joined #ruby
msmith has joined #ruby
gusrub has joined #ruby
nankyokusei has quit [Ping timeout: 258 seconds]
xen0fon has joined #ruby
matp has quit [Remote host closed the connection]
youch has quit [Ping timeout: 240 seconds]
montanonic has joined #ruby
hfp_work has quit [Quit: bye]
xall has joined #ruby
matp has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
frozengeek__ has quit [Quit: frozengeek__]
youch has joined #ruby
ruby463 has joined #ruby
montanonic has quit [Ping timeout: 256 seconds]
devon21 has joined #ruby
kht has quit [Ping timeout: 256 seconds]
Fernando-Basso has joined #ruby
__Yiota has joined #ruby
mistym has quit [Remote host closed the connection]
renchan has quit [Quit: Leaving...]
nobitanobi has joined #ruby
Sauvin has quit [Read error: Connection reset by peer]
Sammichmaker has joined #ruby
gigetoo has quit [Ping timeout: 245 seconds]
TomyWork has quit [Ping timeout: 240 seconds]
nanoz has joined #ruby
nanoz has joined #ruby
nanoz has quit [Changing host]
balazs has joined #ruby
gigetoo has joined #ruby
Kug3lis has quit [Quit: Textual IRC Client: www.textualapp.com]
DoubleMalt has quit [Ping timeout: 240 seconds]
hutch34 has joined #ruby
xall has quit [Ping timeout: 240 seconds]
saneax is now known as saneax-_-|AFK
Burgestrand has joined #ruby
montanonic has joined #ruby
marxarelli has quit [Quit: Textual IRC Client: www.textualapp.com]
nobitanobi has quit [Remote host closed the connection]
UnknownSoldier has quit [Remote host closed the connection]
Cohedrin_ has joined #ruby
Cohedrin_ has quit [Client Quit]
Guest37057 has quit [Remote host closed the connection]
Cohedrin_ has joined #ruby
ecuanaso has joined #ruby
akahn has joined #ruby
montanonic has quit [Ping timeout: 255 seconds]
gigetoo has quit [Ping timeout: 240 seconds]
haylon has quit [Ping timeout: 240 seconds]
marxarelli has joined #ruby
marxarelli is now known as marxarelli|afk
gigetoo has joined #ruby
haylon has joined #ruby
marxarelli|afk is now known as marxarelli
jackjackdripper has joined #ruby
xall has joined #ruby
elementaru has joined #ruby
hahuang65 has joined #ruby
csk157_ has joined #ruby
nankyokusei has joined #ruby
duderonomy has joined #ruby
UnknownSoldier has joined #ruby
nowhereman has joined #ruby
TomyLobo has joined #ruby
bkxd has joined #ruby
d5sx43 has joined #ruby
ruby463 has quit [Ping timeout: 260 seconds]
GodFather has joined #ruby
d5sx43 has quit [Client Quit]
croberts has quit [Ping timeout: 276 seconds]
Snickers has joined #ruby
nankyokusei has quit [Ping timeout: 240 seconds]
csk157_ has quit [Ping timeout: 264 seconds]
ruby462 has joined #ruby
frozengeek__ has joined #ruby
bkxd has quit [Ping timeout: 264 seconds]
montanonic has joined #ruby
davbax has joined #ruby
frozengeek__ has quit [Client Quit]
gigetoo has quit [Ping timeout: 240 seconds]
gigetoo has joined #ruby
nofxx has joined #ruby
Devalo has joined #ruby
Xiti has quit [Ping timeout: 248 seconds]
youch has quit [Ping timeout: 255 seconds]
dopamean_ has joined #ruby
ruby462 has quit [Quit: Page closed]
nowhereman has quit [Remote host closed the connection]
nowhereman has joined #ruby
ramfjord has joined #ruby
Xiti has joined #ruby
youch has joined #ruby
Devalo has quit [Ping timeout: 276 seconds]
koldbrutality has joined #ruby
milardovich has joined #ruby
cibs has quit [Ping timeout: 248 seconds]
dbxt has joined #ruby
Burgestrand has quit [Quit: Closing time!]
tolerablyjake has joined #ruby
ramfjord_ has joined #ruby
cibs has joined #ruby
ramfjord has quit [Ping timeout: 248 seconds]
davbax has quit [Read error: Connection reset by peer]
dbax has joined #ruby
xall has quit [Ping timeout: 256 seconds]
gigetoo has quit [Ping timeout: 264 seconds]
xall_ has joined #ruby
UnknownSoldier has quit [Remote host closed the connection]
gigetoo has joined #ruby
milardovich has quit [Ping timeout: 240 seconds]
dbxt has quit [Read error: Connection reset by peer]
dbxt has joined #ruby
unshadow has joined #ruby
montanonic has quit [Ping timeout: 240 seconds]
anotherpi has quit [Ping timeout: 240 seconds]
dbax has quit [Ping timeout: 240 seconds]
unshadow_ has quit [Ping timeout: 240 seconds]
jhack has quit [Quit: jhack]
nowhereman has quit [Ping timeout: 276 seconds]
arup_r has joined #ruby
sepp2k has quit [Ping timeout: 240 seconds]
Ricko has joined #ruby
<Ricko> Hi
Cohedrin_ has quit [Ping timeout: 240 seconds]
<arup_r> Hi, I have a string like -> KeyError: key not found: "key" . I want to get what is inside the "".. which is `key`. I treid, but my regex sucks http://rubular.com/r/5n59zTGUJ8. Can anyone help me please?
milardovich has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
<al2o3-cr> arup_r: %(KeyError: key not found: "key").match /(\".+\")/
gigetoo has joined #ruby
<Ricko> I have a question with JSON
<arup_r> al2o3-cr: thanks. I just need the key not the surrounded "".
<al2o3-cr> arup_r: %(KeyError: key not found: "key").match /\"(.+)\"/
<al2o3-cr> my bad
<baweaver> Ricko: ask
<Ricko> i render a json with: render json: Challenge.all.to_json
<arup_r> >> %(KeyError: key not found: "key").match(/\"(.+)\"/)[1]
<ruby[bot]> arup_r: # => "key" (https://eval.in/727057)
<arup_r> al2o3-cr: thanks friend.
<Ricko> [{"id":1,"name":"2","details":"2","description_set":"2"},{"id":2,"name":"2332","details":"2332","description_set":"2323"}]
<al2o3-cr> yw :)
nowhereman has joined #ruby
<Ricko> but i will change to {challenges:[{"id":1,"name":"2","details":"2","description_set":"2"},{"id":2,"name":"2332","details":"2332","description_set":"2323"}] }
montanonic has joined #ruby
kirun has joined #ruby
<Ricko> how can i add the "challenges"
nankyokusei has joined #ruby
Cohedrin_ has joined #ruby
<baweaver> How much Ruby do you know outside of Rails?
<baweaver> You might want to read up on what hashes are and how they work in Ruby
<baweaver> &ri Hash
Pupeno has joined #ruby
Pupeno has joined #ruby
<Ricko> it is rails
<Ricko> the controller in rails
<baweaver> I'm aware of this.
<baweaver> Do you know what a Hash is?
<Ricko> :)
<Ricko> yes from java
<Ricko> Hash callenges,myjson ?
Burgestrand has joined #ruby
<baweaver> Ah, in that case it's more of a HashMap, but anyways...
<baweaver> you need to read through some basic Ruby tutorials
<baweaver> the absolute fastest way is learnxinyminutes. The _right_ way is to read something like Eloquent Ruby
<Ricko> The approach is a hash?
<baweaver> yep
<Ricko> do you have a example of a hash?
<baweaver> I could answer you outright easily enough, but this is a basic concept you'll need to grasp
<Ricko> and can rails to be able to deal with
<baweaver> Rails is irrelevant here
nankyokusei has quit [Ping timeout: 252 seconds]
Burgestrand has quit [Client Quit]
<baweaver> You're looking to make a Hash with the key :challenges and the value which is a collection of all the items
gigetoo has quit [Ping timeout: 240 seconds]
DaveTaboola has quit [Max SendQ exceeded]
elementaru has quit [Remote host closed the connection]
arup_r has quit []
<Ricko> ah
<Ricko> do you have a good rails tutorial?
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
gigetoo has joined #ruby
<baweaver> Rails 4 in Action
<baweaver> But read Eloquent Ruby
<baweaver> it tells you how to program Ruby like a Ruby programmer which is invaluable
<baweaver> especially coming from Java.
s2013 has joined #ruby
nowhereman has quit [Read error: Connection reset by peer]
nowhereman has joined #ruby
frozengeek__ has joined #ruby
evie_hammond has quit [Quit: WeeChat 1.6]
frozengeek___ has joined #ruby
Burgestrand has joined #ruby
_geoff_ has quit [Quit: leaving]
andremaha has joined #ruby
johnny56 has quit [Ping timeout: 264 seconds]
ecuanaso has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<tuelz> hmm, are there not any more recent general ruby books?
gigetoo has quit [Ping timeout: 240 seconds]
frozengeek__ has quit [Ping timeout: 240 seconds]
<tuelz> 2011 is a long time ago in the ruby world I can't imagine it would have many new featured neat trickes
ecuanaso has joined #ruby
<havenwood> tuelz: The Well-Grounded Rubyist, Second Edition is pretty recent.
msmith has quit [Remote host closed the connection]
gigetoo has joined #ruby
ramfjord_ has quit [Ping timeout: 245 seconds]
msmith has joined #ruby
<havenwood> Well, 2014.
chouhoulis has quit [Remote host closed the connection]
Rodya_ has joined #ruby
chouhoulis has joined #ruby
<tuelz> I think I just need to scour some ruby weekly blog posts and get back into the swing of it....been writing ruby the same way for a couple years and I don't feel like I've done much interesting with the language
<Ricko> i see for Ruby and Hash
nowhereman has quit [Ping timeout: 240 seconds]
duderonomy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<tuelz> been playing with elixir a lot and stopped leveling up my ruby specific game :) although new language perspective brings some fresh insight on things for me
<Ricko> Json[:challenges] = myJson
justin_pdx has joined #ruby
nowhereman has joined #ruby
renchan has joined #ruby
<Ricko> a hash can a json json = {a,b,c}
omphe has joined #ruby
larcara has quit []
jhack has joined #ruby
harfangk has quit [Quit: Textual IRC Client: www.textualapp.com]
sepp2k has joined #ruby
andremaha has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<Ricko> elixir is a good keyword, but elixir runs not on AWS EC2-Instance
montanonic has quit [Ping timeout: 255 seconds]
bkxd has joined #ruby
dbax has joined #ruby
Flonk has quit [Ping timeout: 260 seconds]
workmad3 has quit [Ping timeout: 260 seconds]
andremaha has joined #ruby
dangerousdave has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
johnny56 has joined #ruby
dbxt has quit [Ping timeout: 240 seconds]
<dangerousdave> evening all
bkxd has quit [Ping timeout: 240 seconds]
<dangerousdave> I can't seem to figure out how to pass a path to DIR.glob https://ruby-doc.org/core-1.9.3/Dir.html#method-c-glob
last_staff has joined #ruby
gigetoo has joined #ruby
jshjsh has quit [Ping timeout: 255 seconds]
<dangerousdave> and have it recursive
JoshS has joined #ruby
marxarelli is now known as marxarelli|afk
<tuelz> what? elixir runs on tons of platforms - including every OS that sits on top of aws afaik
cdg has joined #ruby
babblebre has joined #ruby
jason^ has joined #ruby
cdg_ has joined #ruby
s2013 has quit [Read error: Connection reset by peer]
<al2o3-cr> dangerousdave: Find.find might be helpful here
<jason^> i have a large collection of IPAddr objects in a hash, i need to find the matching objects, right now i'm running z.each {|x| x.include?(ip)} which seems inefficient, is there a better way to do this i am not thinking of?
nankyokusei has joined #ruby
<dangerousdave> ?
<apeiros> anybody going to rubyconf bohol?
duderonomy has joined #ruby
cdg has quit [Ping timeout: 276 seconds]
montanonic has joined #ruby
dbxt has joined #ruby
<dangerousdave> apeiros yes, i think some people are
<apeiros> dangerousdave: eh, ok. I guess being pedantic is part of being a programmer :) I mean who in this channel is going?
<dangerousdave> :-)
Ricko has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
jshjsh has joined #ruby
gusrub has quit [Remote host closed the connection]
marxarelli|afk is now known as marxarelli
nankyokusei has quit [Ping timeout: 276 seconds]
anisha has joined #ruby
dbax has quit [Ping timeout: 240 seconds]
JoshS has quit [Ping timeout: 256 seconds]
xall_ has quit [Ping timeout: 240 seconds]
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
dbax has joined #ruby
andremaha has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ramfjord has joined #ruby
dangerousdave has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
xen0fon has quit [Quit: xen0fon]
xall_ has joined #ruby
dbxt has quit [Ping timeout: 256 seconds]
<tuelz> anyone wanna critique this code for fun? :)
<tuelz> basically I'm wondering if there's a clever way to print the symbols out in the argerror message
<tuelz> right now it's just a weird string that probably isn't very intuitive to read
<elomatreb> There is a symbol array literal, you could use to to save the map(&:to_sym)
dangerousdave has joined #ruby
<tuelz> elomatreb: good call, thanks
<elomatreb> Also, from the method name I would not expect it to raise. IMO it should return true/false
JeanCarloMachado has quit [Ping timeout: 264 seconds]
milardovich has quit [Remote host closed the connection]
<tuelz> good feedback, now if I can just get a way to represent the symbols as `:query` without the join hack I think I'm golden
gigetoo has quit [Ping timeout: 248 seconds]
<elomatreb> tuelz: You could inspect the array, it should print the containing symbols like that
<elomatreb> >> [:a, :b].inspect
<ruby[bot]> elomatreb: # => "[:a, :b]" (https://eval.in/727062)
Burgestrand has quit [Quit: Closing time!]
kht has joined #ruby
montanonic has quit [Ping timeout: 260 seconds]
xall_ has quit [Ping timeout: 255 seconds]
gigetoo has joined #ruby
ldnunes has quit [Quit: Leaving]
<tuelz> elomatreb: I think you nailed it...thanks
ur5us has joined #ruby
ecuanaso has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
chouhoul_ has joined #ruby
sepp2k has quit [Ping timeout: 276 seconds]
justin_pdx has quit [Quit: justin_pdx]
psychicist__ has quit [Ping timeout: 256 seconds]
nowhereman has quit [Remote host closed the connection]
youch has quit [Ping timeout: 240 seconds]
prestorium has quit [Quit: Leaving]
nowhereman has joined #ruby
youch has joined #ruby
consti has quit [Read error: Connection reset by peer]
chouhoulis has quit [Ping timeout: 258 seconds]
cdg has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
anisha has quit [Quit: This computer has gone to sleep]
bmurt has joined #ruby
jenrzzz has joined #ruby
My_Hearing has joined #ruby
devon21 has quit [Quit: devon21]
youch has quit [Ping timeout: 245 seconds]
evie_hammond has joined #ruby
gigetoo has quit [Ping timeout: 252 seconds]
cdg_ has quit [Ping timeout: 245 seconds]
montanonic has joined #ruby
cdg_ has joined #ruby
gigetoo has joined #ruby
Mon_Ouie has quit [Ping timeout: 255 seconds]
koldbrutality has quit [Remote host closed the connection]
dangerousdave has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<manveru> >> %i(query commit)
<ruby[bot]> manveru: # => [:query, :commit] (https://eval.in/727063)
<manveru> tuelz: :)
ramfjord has quit [Ping timeout: 240 seconds]
username_ has quit [Ping timeout: 252 seconds]
<manveru> >> "what's in the box? %p" % i(query commit)
chouhoulis has joined #ruby
<ruby[bot]> manveru: # => undefined local variable or method `commit' for main:Object (NameError) ...check link for more (https://eval.in/727064)
<manveru> >> "what's in the box? %p" % % i(query commit)
<ruby[bot]> manveru: # => /tmp/execpad-9de3a2c71035/source-9de3a2c71035:2: syntax error, unexpected tIDENTIFIER, expecting key ...check link for more (https://eval.in/727065)
<manveru> >> "what's in the box? %p" % %i(query commit)
<ruby[bot]> manveru: # => "what's in the box? :query" (https://eval.in/727066)
<manveru> oh damn
<manveru> i need a new font :(
dangerousdave has joined #ruby
blackbombay has joined #ruby
tvw has joined #ruby
nankyokusei has joined #ruby
<apeiros> tuelz: IMO a ? method shouldn't raise, it should return true/false. if your array is <= 4 elements, I'd stick with array, if >4 I'd probably opt for Set.
cdg has quit [Ping timeout: 256 seconds]
<elomatreb> apeiros: Why a SnakeCase name and not a CONSTANT?
chouhoul_ has quit [Ping timeout: 248 seconds]
<apeiros> elomatreb: because it's all turtles
<matthewd> I'd use .map(&:inspect).join(" ")
<apeiros> (classes are objects, any object can respond to new, yadda)
<apeiros> matthewd: funny, in my own code I use .inspect[1..-2] :D
<apeiros> "just get rid of the damn brackets!"
blackbom1 has quit [Ping timeout: 255 seconds]
<matthewd> It's longer, but avoids this code trying to know how to "construct" a symbol literal (and getting it wrong, though as the symbols are right there, that doesn't matter in this case)
montanonic has quit [Ping timeout: 264 seconds]
<elomatreb> Also breaks on symbols containing a space, as it doesn't quote them correctly
<apeiros> I prefer both your solution and the code I wrote here. dunno why I didn't change it in the gist.
<apeiros> exactly elomatreb
<apeiros> changed it
nankyokusei has quit [Ping timeout: 240 seconds]
tvw has quit [Ping timeout: 255 seconds]
<matthewd> apeiros: Your trick doesn't work so well on a set ;)
<apeiros> oh, true
nobitanobi has joined #ruby
<apeiros> it works well, but needs different offsets
youch has joined #ruby
<apeiros> .inspect[8..-3]
<matthewd> Yeah.. IMO it feels too needlessly linked to the structure of Set#inspect, but ¯\_(ツ)_/¯
jshjsh has quit [Ping timeout: 240 seconds]
<apeiros> it's short!
<apeiros> and and and
gigetoo has quit [Ping timeout: 276 seconds]
frozengeek___ has quit [Quit: frozengeek___]
<apeiros> I don't know
vuoto has joined #ruby
gigetoo has joined #ruby
devon21 has joined #ruby
frozengeek___ has joined #ruby
gusrub has joined #ruby
cdg has joined #ruby
nobitanobi has quit [Ping timeout: 258 seconds]
ta has joined #ruby
andremaha has joined #ruby
nowhereman has quit [Ping timeout: 240 seconds]
cdg_ has quit [Read error: Connection reset by peer]
cdg__ has joined #ruby
milardovich has joined #ruby
cdg has quit [Ping timeout: 255 seconds]
bkxd has joined #ruby
consti has joined #ruby
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
milardovich has quit [Ping timeout: 276 seconds]
jeffreylevesque has quit [Ping timeout: 252 seconds]
bkxd has quit [Ping timeout: 255 seconds]
ramfjord has joined #ruby
dangerousdave has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ddffg has quit [Ping timeout: 240 seconds]
kht has quit [Ping timeout: 240 seconds]
andremaha has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Devalo has joined #ruby
dangerousdave has joined #ruby
andremaha has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
grh has joined #ruby
xen0fon has joined #ruby
jenrzzz has quit [Ping timeout: 256 seconds]
nankyokusei has joined #ruby
gigetoo has joined #ruby
Devalo has quit [Ping timeout: 276 seconds]
gusrub has quit [Remote host closed the connection]
frozengeek___ has quit [Read error: Connection reset by peer]
frozengeek___ has joined #ruby
frozengeek___ has quit [Remote host closed the connection]
frozengeek___ has joined #ruby
aryaching has quit [Ping timeout: 240 seconds]
nankyokusei has quit [Ping timeout: 248 seconds]
csk157_ has joined #ruby
devon21 has quit [Quit: devon21]
<tuelz> thanks for all the suggestions, just seeing the new stuff
<tuelz> :)
username_ has joined #ruby
gigetoo has quit [Ping timeout: 245 seconds]
csk157_ has quit [Ping timeout: 240 seconds]
dbxt has joined #ruby
workmad3 has joined #ruby
gigetoo has joined #ruby
P1ro has joined #ruby
yaewa has quit [Quit: Leaving...]
marxarelli is now known as marxarelli|afk
Ishido has quit [Quit: Roads? Where We're Going We Don't Need Roads.]
moei has joined #ruby
montanonic has joined #ruby
johnny56 has quit [Ping timeout: 264 seconds]
dbax has quit [Ping timeout: 240 seconds]
Guest43 has joined #ruby
ur5us has quit [Remote host closed the connection]
dbax has joined #ruby
cdg has joined #ruby
jenrzzz has joined #ruby
dbxt has quit [Ping timeout: 258 seconds]
ddffg has joined #ruby
cdg__ has quit [Ping timeout: 255 seconds]
kht has joined #ruby
last_staff has quit [Quit: last_staff]
xen0fon has quit [Quit: xen0fon]
gigetoo has quit [Ping timeout: 252 seconds]
rfoust has quit [Ping timeout: 252 seconds]
gigetoo has joined #ruby
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
malconis_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
justin_pdx has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
devon21 has joined #ruby
_djbkd has joined #ruby
ecuanaso has joined #ruby
polishdub has quit [Quit: Leaving]
[Butch] has quit [Quit: I'm out . . .]
Snickers has quit [Quit: Snickers]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Snickers has joined #ruby
Snickers has quit [Client Quit]
rudisimo has joined #ruby
Snickers has joined #ruby
Snickers has quit [Client Quit]
Snickers has joined #ruby
kht has quit [Ping timeout: 240 seconds]
Snickers has quit [Client Quit]
nankyokusei has joined #ruby
justin_pdx has quit [Quit: justin_pdx]
Snickers has joined #ruby
harai_ has quit [Ping timeout: 252 seconds]
Snickers has quit [Client Quit]
Rodya_ has quit [Quit: Leaving...]
dangerousdave has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Snickers has joined #ruby
cdg_ has joined #ruby
boombox_ has joined #ruby
dangerousdave has joined #ruby
Snickers has quit [Client Quit]
Snickers has joined #ruby
Snickers has quit [Client Quit]
Guest43 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tuelz has quit [Ping timeout: 240 seconds]
Pupeno has quit [Remote host closed the connection]
cdg has quit [Ping timeout: 260 seconds]
marxarelli|afk is now known as marxarelli
gigetoo has quit [Ping timeout: 264 seconds]
marxarelli is now known as marxarelli|afk
nankyokusei has quit [Ping timeout: 256 seconds]
cdg has joined #ruby
gigetoo has joined #ruby
marxarelli|afk has quit [Quit: Textual IRC Client: www.textualapp.com]
dangerousdave has quit [Ping timeout: 240 seconds]
marxarelli has joined #ruby
rwb has quit [Ping timeout: 240 seconds]
ur5us has joined #ruby
cdg_ has quit [Ping timeout: 245 seconds]
nanoz has quit [Read error: Connection reset by peer]
sniffer has joined #ruby
milardovich has joined #ruby
bovis has joined #ruby
duckpupp1 has quit [Ping timeout: 240 seconds]
cdg_ has joined #ruby
enterprisey has joined #ruby
milardovich has quit [Ping timeout: 240 seconds]
omphe has joined #ruby
cdg has quit [Ping timeout: 245 seconds]
montanonic has quit [Ping timeout: 240 seconds]
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
boombox_ has quit [Remote host closed the connection]
bkxd has joined #ruby
sniffer has quit [Remote host closed the connection]
synthroid has quit []
Rodya_ has joined #ruby
bkxd has quit [Ping timeout: 240 seconds]
sniffer has joined #ruby
lxsameer has quit [Quit: WeeChat 1.6]
tlahtoani has joined #ruby
gloscombe has joined #ruby
gigetoo has quit [Ping timeout: 240 seconds]
quick has joined #ruby
dbxt has joined #ruby
brendan- has quit [Quit: Textual IRC Client: www.textualapp.com]
gigetoo has joined #ruby
nankyokusei has joined #ruby
ecuanaso has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
montanonic has joined #ruby
Rodya_ has quit [Read error: No route to host]
<quick> Hi there - a quick question here :) Is it possible in Ruby to read a file by specifying a path such as file:///tmp/ ?
beatdown has quit [Quit: Severed corpses make good fucks.]
<quick> for example:
Rodya_ has joined #ruby
<quick> irb(main):034:0> checksum_base_path='file:///tmp/'
<quick> => #<URI::Generic file:/tmp/apache-tomcat-8.0.36.tar.gz.md5>
<quick> irb(main):035:0> uri = URI.join(checksum_base_path, "apache-tomcat-8.0.36.tar.gz.md5")
<quick> irb(main):036:0> open(uri.to_s).read.split(' ')[0]
<quick> => "file:///tmp/"
<quick> Errno::ENOENT: No such file or directory @ rb_sysopen - file:/tmp/apache-tomcat-8.0.36.tar.gz.md5
<quick> from /usr/share/ruby/open-uri.rb:37:in `initialize'
<quick> from /usr/share/ruby/open-uri.rb:37:in `open'
<quick> from /usr/share/ruby/open-uri.rb:37:in `open'
<quick> from (irb):36
<quick> from /usr/bin/irb:11:in `<main>'
<quick> irb(main):037:0> open(uri).read.split(' ')[0]
<quick> TypeError: no implicit conversion of URI::Generic into String
<quick> from /usr/share/ruby/open-uri.rb:37:in `open'
<quick> from /usr/share/ruby/open-uri.rb:37:in `open'
<quick> from (irb):37
<quick> from /usr/bin/irb:11:in `<main>'
<apeiros> quick: stop that
UnknownSoldier has joined #ruby
dbax has quit [Ping timeout: 245 seconds]
<apeiros> see topic. use a paste service for large pastes. preferably gist.github.com.
enterprisey has quit [Remote host closed the connection]
<quick> sorry aperios
<Radar> admin plz ban
tvw has joined #ruby
<apeiros> .ban radar at your service!
<quick> genuinely sorry
<Radar> quick: File.read("/path/to/file")
nankyokusei has quit [Ping timeout: 248 seconds]
<Radar> Googling "Ruby read file" turns up this answer too: http://stackoverflow.com/a/7157218/15245
grh has quit [Ping timeout: 260 seconds]
bmurt has joined #ruby
<quick> thanks just checking
<quick> I'm just wondering if that would work with file:///
<Radar> Why does it need to work with file://?
<apeiros> seems open doesn't support that, even with open-uri required
Fernando-Basso has quit [Quit: WeeChat 1.5]
blackwind_123 has quit [Ping timeout: 258 seconds]
* apeiros thinks it's not unreasonable to assume that that'd work
<matthewd> URI has a .path
<Radar> matthewd: trufax
gusrub has joined #ruby
hahuang62 has quit [Ping timeout: 240 seconds]
millerti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
babblebre has quit [Quit: Connection closed for inactivity]
tvw has quit [Read error: Connection reset by peer]
blackwind_123 has joined #ruby
<matthewd> (but before you could use that, you'd technically need to confirm both scheme == 'file' && host.nil?)
jenrzzz has joined #ruby
<apeiros> file scheme can have a host? OO
gigetoo has quit [Ping timeout: 240 seconds]
<matthewd> Technically yes -- thus the leading /// -- though it'd be up to you to work out what to do with such information
<quick> it is legitimate
gigetoo has joined #ruby
<quick> I've tried with file://localhost/tmp/ and file:///tmp/
skweek has joined #ruby
<quick> contents = File.read('file:///tmp/apache-tomcat-8.0.36.tar.gz.md5') does not work either
frmendes has joined #ruby
montanonic has quit [Ping timeout: 256 seconds]
GodFather has quit [Read error: No route to host]
malconis has joined #ruby
oniMaker_ has joined #ruby
oniMaker_ is now known as oniMaker
oniMaker has joined #ruby
oniMaker has quit [Changing host]
andremaha has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<quick> open(uri.to_s.sub(%r{^file:}, '')).read
<quick> that works
* Radar reaches for sick bag
<quick> ha
JoshS has joined #ruby
<Radar> uri.path doesn't work?
<al2o3-cr> quick: uri.path as mentioned
<Radar> al2o3-cr: TOO SLOW
<quick> ahh yeah sorry
<quick> that works too :)
<al2o3-cr> yep, next time :)
<quick> Thanks for that
harai_ has joined #ruby
gigetoo has quit [Ping timeout: 245 seconds]
kirun has quit [Quit: Konversation terminated!]
renchan has quit [Remote host closed the connection]
gigetoo has joined #ruby
Azulinho has joined #ruby
montanonic has joined #ruby
Azulinho has quit [Client Quit]
cdg has joined #ruby
nankyokusei has joined #ruby
ramfjord has quit [Ping timeout: 240 seconds]
jeffreylevesque has joined #ruby
koldbrutality has joined #ruby
cgibsonmm has joined #ruby
ddffg has quit [Ping timeout: 240 seconds]
ddffg has joined #ruby
ecuanaso has joined #ruby
Azulinho has joined #ruby
dbax has joined #ruby
Azulinho has quit [Client Quit]
cdg_ has quit [Ping timeout: 264 seconds]
gloscombe has quit [Quit: gloscombe]
oniMaker has left #ruby [#ruby]
quick has quit [Ping timeout: 240 seconds]
GodFather has joined #ruby
nankyokusei has quit [Ping timeout: 252 seconds]
aryaching has joined #ruby
Azulinho has joined #ruby
__Yiota has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Azulinho has quit [Client Quit]
dbxt has quit [Ping timeout: 256 seconds]
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
d10n-work has quit [Quit: Connection closed for inactivity]
cdg_ has joined #ruby
akahn has quit [Quit: Connection closed for inactivity]
chrx has joined #ruby
chrx is now known as descript
jshjsh has joined #ruby
lmc has quit [Quit: Leaving...]
descript is now known as descriptt
rudisimo_ has joined #ruby
DoubleMalt has joined #ruby
biberu has quit []
msmith has quit [Remote host closed the connection]
cdg has quit [Ping timeout: 240 seconds]
msmith has joined #ruby
ramortegui has quit [Quit: Ex-Chat]
JoshS has quit [Ping timeout: 256 seconds]
rudisimo has quit [Ping timeout: 252 seconds]
wilbert has joined #ruby
ramfjord has joined #ruby
gloscombe has joined #ruby
rudisimo has joined #ruby
msmith has quit [Ping timeout: 260 seconds]
vuoto has quit [Remote host closed the connection]
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
gigetoo has quit [Ping timeout: 276 seconds]
gigetoo has joined #ruby
omphe has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rudisimo_ has quit [Ping timeout: 255 seconds]
rfoust has joined #ruby
montanonic has quit [Ping timeout: 260 seconds]
jackjackdripper has quit [Quit: Leaving.]
jhack has quit [Quit: jhack]
rwb has joined #ruby
jhack has joined #ruby
choke has joined #ruby
<baweaver> Then just use /tmp
jackjackdripper has joined #ruby
nankyokusei has joined #ruby
<baweaver> dang scroll
Azulinho has joined #ruby
bkxd has joined #ruby
devon21 has quit [Quit: devon21]
<Radar> baweaver: TOO SLOW
devon21 has joined #ruby
griffindy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nankyokusei has quit [Ping timeout: 256 seconds]
bkxd has quit [Ping timeout: 258 seconds]
SerialDev has quit [Remote host closed the connection]
gigetoo has quit [Ping timeout: 256 seconds]
gigetoo has joined #ruby
milardovich has joined #ruby
montanonic has joined #ruby
patarr has quit [Ping timeout: 258 seconds]
davezd has quit [Quit: Leaving]
devon21 has quit [Quit: devon21]
milardovich has quit [Ping timeout: 240 seconds]
devon21 has joined #ruby
dopamean1 has joined #ruby
workmad3 has quit [Ping timeout: 252 seconds]
psychicist__ has joined #ruby
saneax-_-|AFK is now known as saneax
dopamean_ has quit [Ping timeout: 240 seconds]
johnny56 has joined #ruby
jenrzzz_ has joined #ruby
dopamean1 has quit [Ping timeout: 258 seconds]
gigetoo has quit [Ping timeout: 258 seconds]
descriptt has quit [Quit: Leaving]
gigetoo has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
cschneid_ has joined #ruby
mic_e has quit [Ping timeout: 240 seconds]
<cschneid_> I'm setting up testing in a small sinatra app - using minitest - is it not the lib to provide the `test "foo" do...end` helper to writing test classes? I'm used to that in rails
<cschneid_> or is there an option or flag or extra include I'm missing?
<cschneid_> (this is near impossible to google for. "minitest test method" is not useful :)
<lupine> minitest is an odd one, due to version weirdness
<lupine> ISTR an ancient version is bundled with the stdlib and it can get in the way
mic_e has joined #ruby
nankyokusei has joined #ruby
DoubleMalt has quit [Ping timeout: 264 seconds]
charliesome has joined #ruby
wilbert has quit [Quit: WeeChat 1.7]
jessiepuls has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
wilbert has joined #ruby
<lupine> not finding it though
<lupine> still, def self.test(name, &blk) define_method("test_"+clean(name), &blk) isn't too hard
psychicist__ has quit [Ping timeout: 248 seconds]
nankyokusei has quit [Ping timeout: 258 seconds]
GodFather has quit [Read error: Connection reset by peer]
<cschneid_> sure - didn't want to reimplement something that existed elsewhere
rfoust has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<cschneid_> thank you for finding that
gigetoo has quit [Read error: Connection reset by peer]
gigetoo has joined #ruby
frozengeek___ has quit [Quit: frozengeek___]
TomyLobo has quit [Ping timeout: 255 seconds]
bjpenn has joined #ruby
<bjpenn> ruby -v shows 1.9.3p0, and i'm getting buffer overflows detected
<bjpenn> is this a known issue possibly?
JoshS has joined #ruby
montanonic has quit [Ping timeout: 240 seconds]
msmith has joined #ruby
myk267 has joined #ruby
jshjsh has quit [Ping timeout: 240 seconds]
Lord_of_Life has quit [Excess Flood]
gigetoo has quit [Ping timeout: 245 seconds]
Lord_of_Life has joined #ruby
gigetoo has joined #ruby
UnknownSoldier is now known as Tau
Guest43 has joined #ruby
is_null has joined #ruby
haylon has quit [Quit: leaving]
nankyokusei has joined #ruby
frmendes has quit [Quit: Textual IRC Client: www.textualapp.com]
Guest43 has quit [Changing host]
Guest43 has joined #ruby
Guest43 is now known as Rufus
ramfjord has quit [Ping timeout: 240 seconds]
pskosinski has joined #ruby
pskosinski is now known as Guest49359
mim1k|work has quit [Ping timeout: 240 seconds]
Pupeno has joined #ruby
Pupeno has joined #ruby
Pupeno has quit [Changing host]
jackjackdripper has quit [Quit: Leaving.]
ivanskie has joined #ruby
jshjsh has joined #ruby
Guest49359 has quit [Changing host]
Guest49359 has joined #ruby
Guest49359 has joined #ruby
harai_ has quit [Ping timeout: 276 seconds]
harai has joined #ruby
mim1k|work has joined #ruby
Guest49359 is now known as pskosinski
nankyokusei has quit [Ping timeout: 255 seconds]
msmith has quit []
montanonic has joined #ruby
JoshS has quit [Ping timeout: 256 seconds]
<Radar> bjpenn: Why not use the latest 1.9.3 patch release/
Pupeno has quit [Ping timeout: 276 seconds]
gigetoo has quit [Ping timeout: 240 seconds]
marxarelli is now known as marxarelli|afk
gigetoo has joined #ruby
raldu has quit [Ping timeout: 248 seconds]
ramfjord has joined #ruby
raldu has joined #ruby
milardovich has joined #ruby
<baweaver> Not to mention 1.9.3 being hugely out of date.
Azure has quit [Quit: Oops.]
bovis has quit [Quit: leaving]
marxarelli|afk is now known as marxarelli
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bkxd has joined #ruby
toretore has quit [Ping timeout: 255 seconds]
milardovich has quit [Ping timeout: 258 seconds]
nankyokusei has joined #ruby
nettoweb has joined #ruby
gigetoo has quit [Ping timeout: 264 seconds]
cschneid_ has quit [Remote host closed the connection]
jhack has quit [Quit: jhack]
wilbert has quit [Ping timeout: 256 seconds]
bkxd has quit [Ping timeout: 245 seconds]
gigetoo has joined #ruby
nankyokusei has quit [Ping timeout: 276 seconds]
gnufied has quit [Remote host closed the connection]
ecuanaso has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
govg has joined #ruby
JeanCarloMachado has joined #ruby