« Back to channel list

#ruby - 25 July 2015

« Back 1 day Forward 1 day »
[00:02:43] [H]unt3r: has joined #ruby
[00:03:02] prosodyContext: has joined #ruby
[00:04:42] Scriptonaut: anyone know how to open a file to write with "../.." in the path?
[00:04:58] Scriptonaut: it's giving me: Errno::ENOENT: No such file or directory @ rb_sysopen - ../../db/migrate/add_table_users.rb
[00:05:26] RickHull: it's incredibly likely that the file doesn't exist
[00:05:30] RickHull: at that path
[00:05:41] Scriptonaut: ya it doesn't, I'm trying to create the file
[00:05:48] bubbys: has joined #ruby
[00:05:57] RickHull: with what method?
[00:06:12] Scriptonaut: I'm doing File.open("../../db/migrate/add_table_users.rb", 'w') do |f| ...
[00:06:24] RickHull: probably need to use File.new
[00:06:31] RickHull: or something
[00:06:31] Scriptonaut: that gives me the same error
[00:06:36] Scriptonaut: when I take out the "../.." it works
[00:06:45] Scriptonaut: I guess I could get an absolute path
[00:06:58] RickHull: you can use File.expand_path too
[00:07:21] Scriptonaut: thanks RickHull that's exactly what I needed
[00:07:53] hays: has joined #ruby
[00:07:54] juanpablo_: has joined #ruby
[00:08:40] hays: can someone help parse out what this is doing? cl.with_slave(1) do |slave|
[00:09:13] hays: e.g., what is the |slave| bit
[00:09:20] RickHull: that's a block parameter
[00:09:35] RickHull: e.g. [1,2,3].each do |num|
[00:11:10] hays: hrm.. guess im struggling with the mental model her
[00:12:00] hays: [1,2,3].each returns an iterator... so I guess that just gets passed into the do somehow?
[00:12:31] Yzguy: has joined #ruby
[00:12:38] RickHull: each accepts a block. you are passing the block (do ... end) to each
[00:12:49] RickHull: if you don't pass a block, each returns an iterator
[00:13:27] Ox0dea: has joined #ruby
[00:13:44] Thomas-0725: has joined #ruby
[00:14:03] bruno-: has joined #ruby
[00:14:07] hays: ModBus::TCPClient.connect(IP_ADDRESS, PORT, :connect_timeout=>2) do |cl| so in this case... i guess that function is accepting a block
[00:14:12] jackjackdripper: has joined #ruby
[00:14:26] dopie: has joined #ruby
[00:14:45] acke: has joined #ruby
[00:15:04] hays: does it have to accept a block?
[00:15:15] Ox0dea: hays: Every method accepts a (potentially implicit) block.
[00:15:18] jenrzzz: has joined #ruby
[00:16:33] Ox0dea: The String#to_i method, for instance, simply converts the receiver to an integer; you can provide a block, but it'll simply be ignored since it has no bearing on the method's return value.
[00:16:46] Ox0dea: >> '42'.to_i { this is ignored }
[00:16:47] ruboto: Ox0dea # => 42 (https://eval.in/405513)
[00:17:47] hays: What is the most useful three hours of reading I can do on this language?
[00:18:09] hays: as someone who knows quite a few other languages.. this one is ..well unique
[00:18:09] Ox0dea: That doesn't seem like the right question.
[00:18:11] banister: hays whys poignant guide
[00:18:19] Ox0dea: hays: learnxinyminutes.com/docs/ruby/
[00:19:22] Ox0dea: hays: Ruby's blocks are little more than an object-oriented spin on closures.
[00:19:27] bruno-: has joined #ruby
[00:20:02] Ox0dea: Ruby is indeed unique, but only by virtue of its being a combination of features not found anywhere else.
[00:20:25] hays: right. i've not thought about smalltalk since maybe 2002
[00:21:04] wallerdev: has joined #ruby
[00:22:00] hays: and i think im working with a bit of example code that is... especially strange
[00:22:32] hahuang65: has joined #ruby
[00:22:42] RickHull: hays: this shows some block usage: https://rickhull.github.io/loremarkov/rocco/loremarkov.html
[00:23:17] RickHull: i usually reach for braces rather than do/end
[00:23:58] Ox0dea: I use Weirich's rule.
[00:24:06] myztic: has joined #ruby
[00:24:51] lkba_: has joined #ruby
[00:26:59] ynasser: has joined #ruby
[00:29:25] bronson: has joined #ruby
[00:29:32] hays: this poignant guide is really odd
[00:30:04] bruno-: has joined #ruby
[00:30:14] workmad3: has joined #ruby
[00:30:29] RickHull: not my first choice :)
[00:30:33] Rubie: has joined #ruby
[00:31:04] bmurt: has joined #ruby
[00:31:25] hays: seriously maybe an O'Reilly book? surely there is something that won't waste my time .. meh. i'll just google around
[00:31:49] RickHull: http://pine.fm/
[00:31:56] RickHull: i think that is still online
[00:32:08] hahuang65: has joined #ruby
[00:32:12] RickHull: https://pine.fm/LearnToProgram
[00:32:23] RickHull: you can skip lots of the beginning stuff
[00:35:59] lemur: has joined #ruby
[00:36:42] Igorshp: has joined #ruby
[00:37:30] sharpmachine: has joined #ruby
[00:38:16] werelivinginthef: has joined #ruby
[00:39:14] NeverDie: has joined #ruby
[00:40:31] bruno-: has joined #ruby
[00:40:40] Ox0dea: hays: Which O'Reilly book(s) did you read in three hours?
[00:41:22] hays: ones i've skimmed most of because all programming books say the same thing except for the 10% that's unique to the language
[00:41:40] Ox0dea: hays: Then why isn't learnxinyminutes exactly what you're looking for?
[00:41:53] ascarter: has joined #ruby
[00:42:28] hays: thought you were being fecetious
[00:42:33] squirtle: has joined #ruby
[00:42:59] hays: i didn't realize that was a real link. now i do
[00:43:06] hays: facetious
[00:43:21] cntrx: Sounds like a real xy problem
[00:47:37] centrx: has joined #ruby
[00:49:16] hahuang65: has joined #ruby
[00:49:36] Azure: has joined #ruby
[00:50:46] Lucky_: has joined #ruby
[00:50:57] bruno-: has joined #ruby
[00:51:08] eGGsha: has joined #ruby
[00:51:36] fullofcaffeine: has joined #ruby
[00:52:03] shock_one: has joined #ruby
[00:53:06] Azure: has joined #ruby
[00:54:15] EminenceHC: has joined #ruby
[00:54:35] Kalov: has joined #ruby
[00:55:15] tmtwd: has joined #ruby
[00:56:27] bruno-: has joined #ruby
[00:58:31] Azure: has joined #ruby
[00:58:32] ledestin: has joined #ruby
[01:00:41] cout: what's the principle called that says that you shouldn't in a derived class change the meaning of a method defined in a base class?
[01:02:00] cout: is that Liskov or a corollary?
[01:03:13] T3: has joined #ruby
[01:03:51] mistermocha: has joined #ruby
[01:04:37] Ox0dea: cout: That's LSP, yes.
[01:04:43] cout: cool thanks
[01:05:13] Ox0dea: hays: Fluent yet? :) Y should definitely be less than 180 in this case.
[01:05:32] hahuang65: has joined #ruby
[01:05:34] radgeRayden: has joined #ruby
[01:05:59] hays: nope but im distractable
[01:06:34] omegamike: has joined #ruby
[01:10:04] ascarter: has joined #ruby
[01:11:39] allcentury: has joined #ruby
[01:12:24] bhegel: has joined #ruby
[01:13:28] hays: gem install <foo> .. is there a way to do this for a user account without sudo
[01:13:42] RickHull: gem install --user-install
[01:13:52] towski_: has joined #ruby
[01:14:43] RickHull: hays: it's probably too early to start looking at ruby version managers (e.g. rvm, rbenv, chruby) but they have their own layer for managing gems without necessary installing to system (requiring root privileges)
[01:14:54] dfockler: has joined #ruby
[01:15:06] s00pcan: has joined #ruby
[01:15:26] Azure: has joined #ruby
[01:15:53] Ox0dea: RickHull: chruby has nothing to do with gems.
[01:16:09] gambl0re: has joined #ruby
[01:16:34] chills42: has joined #ruby
[01:16:37] RickHull: uh https://github.com/postmodern/chruby
[01:16:55] bruno-: has joined #ruby
[01:17:22] webguynow: has joined #ruby
[01:17:32] hays: RickHull: I've been trying to figure out how to have two of these going at once https://github.com/flipback/rmodbus (see example)
[01:18:14] hays: the way the example is done with closures.. not sure how to have two connections open without being weird and nesting one within the other
[01:19:30] RickHull: yeah, i wouldn't put too much stock in the specific example
[01:19:36] RickHull: https://github.com/flipback/rmodbus/wiki/Getting-started
[01:19:55] Ox0dea: RickHull: chruby's observing a few environment variables oughtn't constitute "gem management", in my opinion.
[01:20:19] RickHull: Ox0dea: it sets environment variables
[01:20:30] RickHull: that's management in my book ;)
[01:20:42] Ox0dea: Fair enough, I suppose.
[01:22:07] bronson: has joined #ruby
[01:22:11] bruno-: has joined #ruby
[01:23:02] postmodern: chruby just tries to keep gem homes separate
[01:23:22] postmodern: gem_home, isolate, bundler are more gem management in my book
[01:23:35] postmodern: also rbenv-gemsets
[01:25:39] stantonnet: has joined #ruby
[01:26:26] hahuang65: has joined #ruby
[01:28:03] symm-: has joined #ruby
[01:29:07] michael_mbp: has joined #ruby
[01:32:37] michael_mbp: has joined #ruby
[01:32:54] Mendenhall: has joined #ruby
[01:36:02] s00pcan: has joined #ruby
[01:37:37] chouhoulis: has joined #ruby
[01:38:42] lemur: has joined #ruby
[01:42:38] decaff: has joined #ruby
[01:42:46] mollymorphic: has joined #ruby
[01:42:54] IceyEC: has joined #ruby
[01:44:32] Cache_Money: has joined #ruby
[01:48:16] vdamewood: has joined #ruby
[01:49:07] hahuang65: has joined #ruby
[01:52:49] Trieste: has joined #ruby
[01:53:21] nobitanobi: has joined #ruby
[01:56:26] juanpablo_: has joined #ruby
[01:56:36] dimasg: has joined #ruby
[01:58:09] benlovell: has joined #ruby
[01:58:11] dymk: has joined #ruby
[01:58:31] dymk: Are there any good up to date docs on writing native extensions in Ruby 2.x.x?
[01:59:26] bigkevmcd: has joined #ruby
[02:00:31] senayar: has joined #ruby
[02:01:38] Vile`: has joined #ruby
[02:01:55] chills42: has joined #ruby
[02:05:13] chouhoulis: has joined #ruby
[02:06:14] EminenceHC: has joined #ruby
[02:07:16] icebourg: has joined #ruby
[02:08:05] mistermocha: has joined #ruby
[02:12:16] [k-: has joined #ruby
[02:12:56] rbowlby: has joined #ruby
[02:13:05] yfeldblum: has joined #ruby
[02:13:22] sja_: has joined #ruby
[02:14:06] renier: has joined #ruby
[02:14:19] luckyruby: has joined #ruby
[02:14:45] Ox0dea: dymk: Have you found the canonical outline of the API in doc/extension.rdoc to be in some way deficient?
[02:14:48] benlovell: has joined #ruby
[02:15:29] dymk: Ox0dea, I'll take a look at that :) google hadn't directed me to that doc
[02:15:36] Alangoose: has joined #ruby
[02:16:39] rbowlby: has joined #ruby
[02:16:49] [k-: Ox0dea: ruby -rsocket.so -e 'p hello' worked
[02:17:10] Ox0dea: [k-: Thanks, but what ends up in $LOADED_FEATURES?
[02:20:00] hahuang65: has joined #ruby
[02:20:38] Ox0dea: [k-: Could you please do `ruby -rsocket.so -e 'p $LOADED_FEATURES.grep(/socket/)'`?
[02:20:53] workmad3: has joined #ruby
[02:21:08] Ox0dea: Really, I only need to know whether it's got the .dylib extension or .so.
[02:22:08] [k-: don't have my Mac now :(
[02:22:12] Ox0dea: This guy.
[02:23:06] saadq: has joined #ruby
[02:23:23] [k-: ask adaedra if you need it fast
[02:23:33] Ox0dea: adaedra: I need it fast.
[02:24:25] thiagovsk: has joined #ruby
[02:24:47] [k-: he is in UTC+2
[02:25:09] [k-: let me calculate the possibility of him being awake
[02:25:17] [k-: 4 am there
[02:27:20] chipotle: has joined #ruby
[02:30:11] mandarinkin: has joined #ruby
[02:30:31] icebourg: has joined #ruby
[02:31:22] decaff: has joined #ruby
[02:31:55] [k-: ACTION 's Mac slowly boots up
[02:33:09] [k-_: has joined #ruby
[02:33:52] Rubie: has joined #ruby
[02:34:00] [k-_: ruby -rsocket.so -e 'p $LOADED_FEATURES.grep(/socket/)'
[02:34:05] gaboesquivel: has joined #ruby
[02:34:06] [k-_: ["/Users/administrator/.rbenv/versions/2.2.0/lib/ruby/2.2.0/x86_64-darwin14/socket.bundle"]
[02:34:31] Ox0dea: Thanks, [k-.
[02:36:06] pothibo: has joined #ruby
[02:36:10] willywos: has joined #ruby
[02:36:58] Evollov3: has joined #ruby
[02:37:05] Ox0dea: Go for it.
[02:38:15] djbkd: has joined #ruby
[02:42:20] iateadonut: has joined #ruby
[02:42:37] hahuang65: has joined #ruby
[02:43:26] Evollov3: trying to make new app on ruby rails but SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed
[02:45:22] tubulife-: has joined #ruby
[02:45:27] Evollov3: Gem::RemoteFetcher::FetchError: SSL_connect returned=1 errno=0 state=SSLv3 read
[02:45:27] Evollov3: server certificate B: certificate verify failed (https://rubygems.org/gems/rake-
[02:45:27] Evollov3: 10.4.2.gem)
[02:45:27] Evollov3: An error occurred while installing rake (10.4.2), and Bundler cannot continue.
[02:45:27] Evollov3: Make sure that `gem install rake -v '10.4.2'` succeeds before bundling.
[02:45:51] ruboto: https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[02:46:05] bronson: has joined #ruby
[02:46:12] baweaver: avoid posting multiline messages
[02:46:41] baweaver: have you tried the make sure line?
[02:47:24] yfeldblum: has joined #ruby
[02:49:22] IceyEC: has joined #ruby
[02:51:40] Evollov3: has left #ruby: ()
[02:52:24] tmtwd: has joined #ruby
[02:55:00] omegamike: has joined #ruby
[02:56:07] psye: has joined #ruby
[02:56:14] [k-: aww so cute: https://drive.google.com/file/d/0Bwc34geqbVNbZEM4cWpzN1dUaEk/view?usp=docslist_api
[02:56:56] juanpablo_: has joined #ruby
[02:57:05] psye: has joined #ruby
[02:57:49] Ox0dea: [k-: Ruby can be used to build websites?!
[02:58:11] michaeldeol: has joined #ruby
[02:58:17] bl4ckdu5t: has joined #ruby
[02:59:09] hahuang65: has joined #ruby
[03:01:50] duncannz: has joined #ruby
[03:01:50] PhantomSpank: has joined #ruby
[03:02:28] [k-: HTML+CSS+Opal+Sinatra maybe?
[03:04:55] [k-: http://ruby.sg
[03:05:19] [k-: I think the workshop happened in March
[03:05:28] Rinzlit: message me :D
[03:08:30] T3: has joined #ruby
[03:08:38] devbug: has joined #ruby
[03:08:49] railswebdev: has joined #ruby
[03:09:10] braincrash: has joined #ruby
[03:13:44] hahuang65: has joined #ruby
[03:13:52] fantazo: has joined #ruby
[03:14:08] darkf: has joined #ruby
[03:14:27] devbug: has joined #ruby
[03:18:07] PaulCapestany: has joined #ruby
[03:19:10] lavros: has joined #ruby
[03:21:28] fullofcaffeine: has joined #ruby
[03:22:19] chills42: has joined #ruby
[03:22:50] chills42: has joined #ruby
[03:24:56] CBke: has joined #ruby
[03:24:56] CBke: has joined #ruby
[03:29:11] serivich: has joined #ruby
[03:32:23] dopie: has joined #ruby
[03:34:39] Peteykun: has joined #ruby
[03:35:14] Rubie: has joined #ruby
[03:36:23] baweaver: has joined #ruby
[03:37:39] sepp2k: has joined #ruby
[03:41:01] hahuang65: has joined #ruby
[03:41:49] bmurt: has joined #ruby
[03:46:00] houhoulis: has joined #ruby
[03:46:35] Rollabunna: has joined #ruby
[03:47:54] gix: has joined #ruby
[03:48:00] chills42: has joined #ruby
[03:49:23] kies^: has joined #ruby
[03:50:55] icebourg: has joined #ruby
[03:52:10] benlovell: has joined #ruby
[03:52:19] cbz: has joined #ruby
[03:52:52] bmurt: has joined #ruby
[03:53:34] YellowHighlighte: has joined #ruby
[03:54:21] RegulationD: has joined #ruby
[03:55:38] hahuang65: has joined #ruby
[03:56:00] happy_dev: has joined #ruby
[03:57:58] jobewan: has joined #ruby
[04:00:14] cbz: has joined #ruby
[04:00:55] lavros_: has joined #ruby
[04:01:50] fantazo: has joined #ruby
[04:03:39] jonee: has joined #ruby
[04:04:34] konsolebox: has joined #ruby
[04:05:44] serivichi: has joined #ruby
[04:08:12] darkf_: has joined #ruby
[04:09:49] workmad3: has joined #ruby
[04:11:24] chills42: has joined #ruby
[04:12:28] mistermocha: has joined #ruby
[04:12:45] hahuang65: has joined #ruby
[04:15:55] Peteykun: has left #ruby: ("Leaving")
[04:18:30] dseitz: has joined #ruby
[04:19:34] arup_r: has joined #ruby
[04:20:38] gaboesquivel: has joined #ruby
[04:21:26] yfeldblum: has joined #ruby
[04:23:32] yfeldblum: has joined #ruby
[04:23:48] serivichi: has joined #ruby
[04:26:25] s2013: has joined #ruby
[04:27:26] hahuang65: has joined #ruby
[04:29:34] bricker: has joined #ruby
[04:31:12] webguynow: has joined #ruby
[04:31:16] ght: Question: If I have a begin / while loop, and I use a next in error-handling
[04:31:26] chinmay_dd: has joined #ruby
[04:31:37] ght: Will the end be evaluated?
[04:31:51] ght: Example: I have begin .... end while i < 5
[04:32:44] ght: If, within the code, I have a begin /rescue on say, a remote API call
[04:32:49] ght: and within the rescue, I use next
[04:33:12] ght: Will using the next evaluate the "end while i < 5", or do I need a supplemental evaluation with break?
[04:33:33] tubulife-: has joined #ruby
[04:34:00] ght: To ensure loop execution will stop if the while i < 5 evaluation is met?
[04:36:15] psmolen: has joined #ruby
[04:37:15] psmolen: has joined #ruby
[04:37:19] Ox0dea: ght: Is that two `begin`s, then?
[04:37:31] ght: well, yes, but just an example
[04:37:36] Ox0dea: Could you not attach both the `rescue` and the `while` to the same `begin`?
[04:37:46] ght: My actual situation is this: I have while myvalue != 0 ..... end
[04:37:56] ght: And at the end of the loop I have myvalue += 1
[04:38:10] ght: That's a better example
[04:38:22] [k-: you don't really need while loops in Ruby
[04:38:26] ght: and within it I have an API call that I error handle with begin / rescue XMLRPC::FauleException => e
[04:38:38] [k-: what is your actual problem?
[04:38:44] ruboto: it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
[04:38:58] ght: My actual problem is as decribed, when error handling, I don't want to break out of the loop, I want it to go to the next iteration, but I'm worried if I call next
[04:39:22] ght: Well, hmm, never mind, I know how to handle this.
[04:39:36] Ox0dea: So many wasted keyboard strokes.
[04:39:38] ght: Disregard, thanks just the same.
[04:39:46] ght: 0x0dea: Well, we all can't be that elite.
[04:39:49] eggoez: has joined #ruby
[04:40:04] [k-: you can test using irb
[04:40:21] [k-: raise 'Exception'; rescue next etc
[04:40:25] ght: [k-: I'm well aware, just figured I'd ask in her instead of spending 10 minutes recreating this method in Ruby.
[04:40:28] ght: I've got it, all is good.
[04:40:36] ght: Thank you just the same.
[04:40:50] [k-: you don't have to recreate the method!
[04:41:03] YellowHighlighte: has left #ruby: ("Leaving")
[04:41:38] [k-: the gist of your problem is, is code executed after an exception?
[04:41:58] [k-: the answer is no, because next just skips to the next iteration
[04:42:06] serivich: has joined #ruby
[04:43:06] omegamike: has joined #ruby
[04:44:19] [k-: what you should actually do is: 5.times { begin (.
[04:44:51] [k-: ..) rescue (...)next end }
[04:45:07] [k-: this will ensure that the code is called 5 times at most
[04:45:37] juanpablo_: has joined #ruby
[04:45:50] acke: has joined #ruby
[04:48:23] ght: Here's a question for you fine people: Does next always step through the current loop in the case of nested loops?
[04:48:50] ght: If you have myarr.each do |arrs|; arrs.each do |arr|; next;
[04:48:54] ght: Will that step through arrs.each ?
[04:49:03] ght: Or the parent my arr.each?
[04:49:06] ght: I assume the former
[04:49:20] [k-: i assume the former as well
[04:49:24] ruboto: Why don't you try it and see for yourself?
[04:49:38] ght: So we don't know, got it.
[04:49:42] ght: I'll build it in irb, thanks just the same.
[04:49:50] rbowlby: has joined #ruby
[04:50:07] [k-: not all of us know Ruby inside out
[04:50:56] baweaver: has joined #ruby
[04:53:31] lxsameer: has joined #ruby
[04:53:32] lxsameer: has joined #ruby
[04:53:39] eggoez: has joined #ruby
[04:56:37] mjuszczak: has joined #ruby
[04:57:00] mary5030: has joined #ruby
[04:57:44] kies^: has joined #ruby
[04:57:54] fullofcaffeine: has joined #ruby
[04:59:10] texasmade: has joined #ruby
[04:59:11] rbowlby: has joined #ruby
[05:00:17] swgillespie: has joined #ruby
[05:01:05] hahuang65: has joined #ruby
[05:04:30] stonith: has joined #ruby
[05:04:30] stonith: has joined #ruby
[05:04:37] riotjones: has joined #ruby
[05:09:19] jackjackdripper: has joined #ruby
[05:13:12] Dildeaux: has joined #ruby
[05:14:00] jaygen: has joined #ruby
[05:14:24] fullofca_: has joined #ruby
[05:16:38] hahuang65: has joined #ruby
[05:17:42] baweaver: has joined #ruby
[05:24:43] sameerynho: has joined #ruby
[05:31:37] hahuang65: has joined #ruby
[05:35:13] leat3: has joined #ruby
[05:36:34] tejasmanohar: has joined #ruby
[05:38:37] shock_one: has joined #ruby
[05:42:44] mary5030: has joined #ruby
[05:42:45] akkad: has joined #ruby
[05:42:54] tejasmanohar: has joined #ruby
[05:42:58] tejasmanohar: has left #ruby: ()
[05:43:03] tejasmanohar: has joined #ruby
[05:45:28] leat3: has joined #ruby
[05:46:20] ozzloy: has joined #ruby
[05:46:48] acke: has joined #ruby
[05:48:20] tejasmanohar: can you subscribe to an rss feed in ruby and parse an item each time it is added to the field?
[05:48:44] tejasmanohar: like in rss, are there events for that you can listen to, or do you jsut have to GET the feed URL every X?
[05:48:47] Ox0dea: Of course.
[05:49:46] tejasmanohar: hmm trying to find that
[05:49:48] Ox0dea: Well, sure, you'll have to poll if the feed source doesn't support WebSockets.
[05:50:03] tabakhase: has joined #ruby
[05:50:41] tejasmanohar: the feed is probably meant for actual people but i'm using a few feeds programmatically to load data for my app...
[05:50:56] tejasmanohar: do you know how often most RSS clients ping the feed to update the feed of the user?
[05:51:02] hahuang65: has joined #ruby
[05:51:06] Ox0dea: That's almost always configurable.
[05:51:29] tabakhase: hmpf, im struggeling in understanding the bare bare basics... ive done a lot of other stuff before, and now want to poke into ruby for a project - but alone the "setup of the structure" eatens hours with buggeling around back and forth to get to a state where i get all gems and can rake and such
[05:51:38] tejasmanohar: i'm just trying to find out what's "too quick" with the interval
[05:51:58] Ox0dea: tejasmanohar: Any reason not to follow SOP and make it configurable?
[05:52:00] tejasmanohar: i don't want to get blocked for fetching the feed too much
[05:52:13] tabakhase: is that usual? or am i just going way to big? -- any recommended starterTuts that are NOT the "hello world" level? - ive done +10years of coding...
[05:52:19] Ox0dea: Ah, you want to fetch as frequently as is permissible, then?
[05:52:37] tejasmanohar: users of my app won't know it's using the rss feed :P
[05:52:50] tejasmanohar: that's all in the backend
[05:53:06] tejasmanohar: but i also don't want the rss feed maintainer to be like im getting 1 request per sec from this guy...
[05:53:21] Ox0dea: Well, you'll likely have to experiment to figure out the optimal rate.
[05:53:32] Ox0dea: You might want to do that from behind a proxy. :)
[05:53:34] tejasmanohar: but once every 10-15 minutes shouldn't be bad i don't think
[05:53:37] tejasmanohar: Ox0dea: yeah probably :P
[05:53:44] Ox0dea: Nah, that's far from excessive.
[05:53:51] tejasmanohar: it's happening in a background job, going to populate database so that's ok
[05:54:23] [k-: blogs don't update every 15 minutes
[05:54:30] tejasmanohar: [k-: it's not a blog :P
[05:55:07] Ox0dea: [k-: Nevertheless, it's usually nice to know precisely when some watched thing has something new for us. :)
[05:55:18] tejasmanohar: it's deal hunting in a way, but i'd rather not go into great detail
[05:55:24] tejasmanohar: no reason to i guess :P
[05:56:02] tejasmanohar: i'm trying to think what database to use. i build a lot of apps w/ postgresql but this app really just needs a "cache"
[05:56:11] tejasmanohar: there's no data that's going to be stored for a long period of time
[05:56:15] tejasmanohar: it's all going to be updated every X
[05:56:17] Ox0dea: tejasmanohar: PStore seems a good fit.
[05:56:32] tejasmanohar: filesystem directly?
[05:56:33] Jackneill: has joined #ruby
[05:56:38] GriffinHeart: has joined #ruby
[05:56:41] tejasmanohar: redis maybe? Ox0dea
[05:57:24] tejasmanohar: i don't think pstore would work on heroku or any PaaS w/ an ephermal filesystem, no? Ox0dea
[05:57:29] tejasmanohar: not sure where i'm deploying it rn
[05:57:34] tejasmanohar: i like heroku for a lot
[05:57:41] tejasmanohar: don't wanna limit msyelf really, looking into some databases
[05:58:18] Ox0dea: I forgot how ephemeral /tmp is on Heroku's free tier, but it might do.
[05:58:36] jenrzzz: has joined #ruby
[05:58:43] Ox0dea: s/forgot/forget/, to clarify.
[05:59:14] tejasmanohar: Ox0dea: you'll lose it after an app restart :P
[05:59:25] tejasmanohar: and there's no guaruntee
[05:59:36] Ox0dea: Aye, you'll want a database, then.
[05:59:38] tejasmanohar: it's ok if it's a quick place to store a file and uplaod it etc (though just streaming the upload is best)
[05:59:49] Ox0dea: Heroku integrates with PG very well, as I recall.
[05:59:53] tejasmanohar: i'd rather just use one from the start, i never like limiting things by infra etc
[06:00:00] tejasmanohar: heroku has PG + redis hosted :)
[06:00:05] Ox0dea: Seems you're good to go. :)
[06:00:14] tejasmanohar: i mean that's not a problem honestly like i can host whatever database wherever and connect it no big deal
[06:00:22] tejasmanohar: do you think redis would be suitable for what i'm describing?
[06:00:38] tejasmanohar: i guesss i didn't explain what kinda data i'm storing for those < 1h periods...
[06:00:45] fullofcaffeine: has joined #ruby
[06:00:45] Ox0dea: Indeed you didn't.
[06:01:16] tejasmanohar: flights by location
[06:01:32] tejasmanohar: maybe hotels too
[06:01:41] Ox0dea: In any case, redis is sufficiently general-purpose that the structure of your data shouldn't be much of a factor.
[06:01:46] tvw: has joined #ruby
[06:01:54] tejasmanohar: yeah it has many data structs from what i looked
[06:02:05] tejasmanohar: so i guess i wouldn't need pg, redis should be enough
[06:02:26] tejasmanohar: Ox0dea: redis is disk persistent so its safe, right? i don't need to write to postgres and then a redis cache or anything like that?
[06:02:29] Ox0dea: Bonus points if you manage to effectively use a HyperLogLog. ^_^
[06:02:47] tejasmanohar: reading about what that is :P Ox0dea
[06:02:53] Ox0dea: tejasmanohar: That's configurable; you'll have to look into how Heroku does it by default.
[06:03:49] Ox0dea: It's rather easy to imagine that they do the sensible thing, though.
[06:04:07] tejasmanohar: i'll look just to make sure :P
[06:04:18] tejasmanohar: btu i don't think that's a big deal, there are many hosted redis providers on AWS like heroku is
[06:04:23] tejasmanohar: so latency etc isn't an issue either
[06:04:31] tejasmanohar: and i can host it myself too if i want
[06:04:42] safeforge: has joined #ruby
[06:05:23] riotjones: has joined #ruby
[06:06:04] jenrzzz_: has joined #ruby
[06:07:45] sevenseacat: has joined #ruby
[06:07:49] jonee: has joined #ruby
[06:08:24] tejasmanohar: Ox0dea: do people ever use redis as primary store w/ rails?
[06:08:59] jenrzzz: has joined #ruby
[06:09:17] Jaood: has joined #ruby
[06:11:00] allomov: has joined #ruby
[06:14:44] Ox0dea: tejasmanohar: I'm sure somebody somewhere does, but that's pretty unorthodox.
[06:14:45] markholmes: has joined #ruby
[06:15:34] Ox0dea: Why oppose a bona fide database, if you don't mind my asking?
[06:18:02] busterarm: has joined #ruby
[06:19:13] hahuang65: has joined #ruby
[06:21:00] jenrzzz: has joined #ruby
[06:21:08] mistermocha: has joined #ruby
[06:21:43] tubulife-: has joined #ruby
[06:23:47] Rubie: has joined #ruby
[06:23:51] rippa: has joined #ruby
[06:23:53] mistermocha: has joined #ruby
[06:24:08] tejasmanohar: Ox0dea: unsure, im updating the data every 15 mins ish
[06:24:11] tejasmanohar: so its basically a cache, no
[06:25:10] Trynemjoel: has joined #ruby
[06:28:10] Ox0dea: tejasmanohar: Old data is completely useless, then?
[06:29:25] jack_rabbit: has joined #ruby
[06:29:38] Ox0dea: You won't need to perform queries on or make comparisons between the old and new data?
[06:31:22] ta: has joined #ruby
[06:32:35] havenwood: has joined #ruby
[06:32:59] railswebdev: has joined #ruby
[06:33:13] rht: has joined #ruby
[06:33:17] hololeap: has joined #ruby
[06:33:57] tejasmanohar: Ox0dea: fair enough, good point
[06:33:58] tejasmanohar: historical data
[06:34:10] tejasmanohar: ok i'll use postgresql and cache my own API calls in redis later because users make repeat cals a lot :P
[06:34:17] tejasmanohar: eh can use cache-cotnrol as well but yeha
[06:34:25] tejasmanohar: *excuse my typos
[06:34:30] juanpablo_: has joined #ruby
[06:35:47] Ox0dea: tejasmanohar: Yep, that seems the sanest approach.
[06:36:40] hololeap: just fishing for opinions, what is the best gui library for ruby?
[06:36:54] Ox0dea: hololeap: JavaScript.
[06:37:37] djbkd_: has joined #ruby
[06:37:37] busterarm: there's always ncurses!
[06:38:30] safeforge: has joined #ruby
[06:39:31] hahuang65: has joined #ruby
[06:39:46] howdoi_: has joined #ruby
[06:41:41] jenrzzz: has joined #ruby
[06:43:18] GriffinHeart: has joined #ruby
[06:44:00] shevy: the curses
[06:44:30] [k-: [x] shevy
[06:44:58] shevy: yay click me
[06:45:32] j4cknewt: has joined #ruby
[06:47:28] Ox0dea: Dirty mouse users!
[06:47:30] GnuYawk: has joined #ruby
[06:47:30] GnuYawk: has joined #ruby
[06:47:37] Ox0dea: hololeap: I should perhaps clarify that I was not being facetious.
[06:47:55] [k-: filthy*
[06:48:09] Ox0dea: [k-: I was trying not to be wholly impolite.
[06:48:24] Ox0dea: "Filthy" connotes a little ruder than "dirty", as I see it.
[06:48:33] Ox0dea: Deceptions!
[06:48:40] Ox0dea: Circumlocutionary tactics!
[06:48:42] hololeap: Ox0dea: you really meant that javascript is your gui favorite library for ruby? :p
[06:49:06] hololeap: *favorite gui library
[06:49:53] Ox0dea: hololeap: Well, you asked about "the best", not anybody's preference.
[06:50:37] CloCkWeRX: has joined #ruby
[06:50:39] Ox0dea: We are flawed creatures, so the two needn't be mutually inclusive.
[06:51:24] Ox0dea: If you've really considered the thing and concluded that you want to build a native GUI in Ruby, I'd advise consulting shevy on the matter; he seems to have gotten into that as of late.
[06:51:30] ryez: has joined #ruby
[06:51:45] hololeap: Ox0dea: i meant gtk, qt, wxwidgets, tcl-tk
[06:51:52] Ox0dea: hololeap: I know.
[06:52:53] busterarm: javascript is probably the sanest choice just for portability reasons, I imagine
[06:53:26] [k-: shevy is using gtk I think
[06:53:27] mary5030: has joined #ruby
[06:54:06] CloCkWeRX: has left #ruby: ()
[06:54:11] hololeap: ruby-gtk3 is what i'll probably be going with. i just wanted to see what other people had to say
[06:54:36] DexterLB: has joined #ruby
[06:55:04] Ox0dea: As I understand it, none of the GUI bindings for Ruby makes any considerable effort to hide the fact that they're wrappers around some underlying C(++) libraries.
[06:55:31] lanemeyer: has joined #ruby
[06:56:13] hololeap: Ox0dea: yeah, there is some truth to that. i guess i just feel that i'm most comfortable with ruby and would prefer to use it instead of another language
[06:57:26] Ox0dea: hololeap: Have you considered Opal, then?
[06:57:42] hololeap: Ox0dea: never heard of it
[06:57:55] Ox0dea: The myriad benefits of JavaScript + the syntax and (most of the) semantics of Ruby.
[07:00:19] shevy: yeah I am a gtkster
[07:00:37] shevy: hololeap my gtk brother!
[07:01:26] hololeap: i might just reacquaint myself with javafx. i like that framework, actually
[07:01:50] hololeap: ugh, but then again, it is java
[07:02:10] shevy: ruby-gnome are the only ruby-GUI bindings that have an extensive wiki http://ruby-gnome2.osdn.jp/hiki.cgi
[07:03:30] ght: Question: I've been researching this to no working avail, is there a method for "sourcing" bash files that set environment variables within a ruby script?
[07:03:55] hololeap: shevy: i walked myself through that once before. i wonder if there's much of a difference between ruby-gtk2 and ruby-gtk3
[07:04:02] ght: Without having to make a parent bash file that sources the files to set the envvars, then call the ruby script?
[07:04:10] shevy: ght not really but all environment variables are stored in ENV, which you can update
[07:04:20] ght: yes, that's true.
[07:05:21] busterarm: opal-native? :D
[07:05:43] busterarm: to 0x0dea i mean
[07:07:18] Ox0dea: busterarm: The worst of both worlds. ^_^
[07:07:35] Ox0dea: JavaScript really is the mouth with which software is eating the world.
[07:08:28] jonee: has joined #ruby
[07:08:34] Ox0dea: ACTION knows his intuition that it would be trivial to add user-defined read-only variables to Ruby is ill-placed.
[07:13:42] hahuang65: has joined #ruby
[07:17:02] leat3: has joined #ruby
[07:19:08] Kilo`byte: has joined #ruby
[07:21:10] EminenceHC: has joined #ruby
[07:22:15] GriffinHeart: has joined #ruby
[07:25:15] psye: has joined #ruby
[07:26:58] sinkensabe: has joined #ruby
[07:27:17] Houshalter: has joined #ruby
[07:27:30] jenrzzz: has joined #ruby
[07:28:42] hahuang65: has joined #ruby
[07:28:49] Houshalter: has left #ruby: ("Leaving")
[07:29:31] mistermocha: has joined #ruby
[07:30:23] chinmay_dd: has joined #ruby
[07:33:30] tejasmanohar: Ox0dea: maybe you know this one? i asked in #ror but didnt get much feedback so moving here its more generic anyways not just rails
[07:33:33] tejasmanohar: a) if i have a job that needs to run every X minutes/hours, seems that `whenever` or `clockwork` would be ideal?
[07:33:47] tejasmanohar: b) what if i have an array of items and i want to run X on item 1 and then give an Y minute gap and then run X on item 2 etc etc looping thru it
[07:33:52] jenrzzz_: has joined #ruby
[07:33:59] tejasmanohar: the breaks are due to rate-limits, should i just run one process that does that or setup job queues w/ sidekiq, resque, delayedjob, etc.? and how do i decide?
[07:34:06] tejasmanohar: many solutions out there for job scheduling
[07:36:17] PhantomSpank: has joined #ruby
[07:36:34] sross07: has joined #ruby
[07:36:43] nertzy: has joined #ruby
[07:37:04] brendan-: has joined #ruby
[07:37:56] Ox0dea: tejasmanohar: The truly *ideal* solution to a) would be cron; I've never bothered to emulate it from Ruby, so you'll have to test-drive those offerings if cron isn't an option.
[07:38:34] Peteykun: has joined #ruby
[07:38:39] MVPhelp: has joined #ruby
[07:39:46] Ox0dea: You could probably get away with basic Threads and `sleep` if $thing is simple enough. If not, you'll find sidekiq integrates rather nicely with redis, if that's still the path you intend to take.
[07:39:53] cescalante: has joined #ruby
[07:40:15] A124: has joined #ruby
[07:40:22] sevenseacat: sidekiq also has a scheduling addon called sidetiq
[07:40:27] sevenseacat: which may help you
[07:40:28] mikecmpbll: has joined #ruby
[07:40:43] ajaiswal: has joined #ruby
[07:40:46] Ox0dea: sevenseacat: Vacation over so soon?
[07:40:47] yebyen: has joined #ruby
[07:42:45] riffraff: has joined #ruby
[07:45:28] sinkensabe: has joined #ruby
[07:47:12] workmad3: has joined #ruby
[07:52:13] modern: has joined #ruby
[07:53:43] Igorshp: has joined #ruby
[07:55:41] RegulationD: has joined #ruby
[07:55:43] user1138: has joined #ruby
[07:57:42] leat3: has joined #ruby
[07:57:45] acke: has joined #ruby
[07:58:59] hahuang65: has joined #ruby
[08:03:51] eGGsha: has joined #ruby
[08:04:00] busterarm: has joined #ruby
[08:04:42] Averna: has joined #ruby
[08:04:52] busterarm: has joined #ruby
[08:06:21] MatthewsFace: has joined #ruby
[08:07:16] Mendenhall: has joined #ruby
[08:08:22] GriffinHeart: has joined #ruby
[08:09:28] fantazo: has joined #ruby
[08:09:34] Ilyas: has joined #ruby
[08:09:53] tubulife-: has joined #ruby
[08:11:42] busterarm: has joined #ruby
[08:13:01] dented42: has joined #ruby
[08:17:01] hahuang65: has joined #ruby
[08:17:07] busterarm: has joined #ruby
[08:17:20] bruno-: has joined #ruby
[08:19:09] omegamike: has joined #ruby
[08:22:45] bruno-: has joined #ruby
[08:23:09] juanpablo_: has joined #ruby
[08:26:31] Rollabun_: has joined #ruby
[08:27:43] lessless: has joined #ruby
[08:29:00] atmosx: has joined #ruby
[08:29:59] dfockler: has joined #ruby
[08:30:46] myztic: has joined #ruby
[08:31:49] hahuang65: has joined #ruby
[08:32:58] bruno-: has joined #ruby
[08:33:51] mistermocha: has joined #ruby
[08:35:19] bradleyprice: has joined #ruby
[08:41:01] roolo: has joined #ruby
[08:42:10] elia: has joined #ruby
[08:42:45] TheHodge: has joined #ruby
[08:43:07] eGGsha: has joined #ruby
[08:45:25] shinnya: has joined #ruby
[08:45:55] timonv: has joined #ruby
[08:48:10] channellier: has joined #ruby
[08:49:03] marr: has joined #ruby
[08:50:30] troulouliou_dev: has joined #ruby
[08:52:07] The_Phoenix: has joined #ruby
[08:56:53] busterarm: has joined #ruby
[08:57:02] lxsameer: has joined #ruby
[08:57:07] krz: has joined #ruby
[08:57:22] tjbiddle: has joined #ruby
[09:00:11] busterarm: has joined #ruby
[09:02:42] hahuang65: has joined #ruby
[09:04:35] The_Phoenix1: has joined #ruby
[09:08:22] PhantomSpank: has joined #ruby
[09:09:14] cornerma1: has joined #ruby
[09:11:59] ndrei: has joined #ruby
[09:13:59] atmosx: has joined #ruby
[09:15:26] hahuang65: has joined #ruby
[09:16:23] DLSteve: has joined #ruby
[09:16:45] MatrixBridge: has joined #ruby
[09:17:28] banister: has joined #ruby
[09:18:09] lkba: has joined #ruby
[09:21:25] apfeluser: has joined #ruby
[09:23:58] railswebdev: has joined #ruby
[09:26:37] texasmade: has joined #ruby
[09:27:02] nyuszika7h: has left #ruby: ("WeeChat 1.3-dev")
[09:29:56] hahuang65: has joined #ruby
[09:35:54] workmad3: has joined #ruby
[09:35:57] joelataylor: has joined #ruby
[09:36:47] nsuke: has joined #ruby
[09:37:01] mistermocha: has joined #ruby
[09:40:34] robbyoconnor: has joined #ruby
[09:44:39] user1138: has joined #ruby
[09:45:21] stamina: has joined #ruby
[09:52:48] sogard: has joined #ruby
[09:54:54] Trynemjoel: has joined #ruby
[09:57:08] hahuang65: has joined #ruby
[09:58:01] tubulife-: has joined #ruby
[09:59:49] Rubie: has joined #ruby
[10:01:12] FernandoBasso: has joined #ruby
[10:02:42] lkba_: has joined #ruby
[10:06:33] carpot: has joined #ruby
[10:07:13] shock_one: has joined #ruby
[10:07:52] omegamike: has joined #ruby
[10:10:25] Trynemjoel: has joined #ruby
[10:11:55] juanpablo_: has joined #ruby
[10:18:00] jonee: has joined #ruby
[10:20:07] Hobogrammer_: has joined #ruby
[10:20:17] rbowlby: has joined #ruby
[10:20:34] serivich: has joined #ruby
[10:25:38] michael_mbp: has joined #ruby
[10:26:14] vdamewood: has joined #ruby
[10:27:33] ledestin: has joined #ruby
[10:29:48] sdothum: has joined #ruby
[10:33:51] vickleton: has joined #ruby
[10:35:31] SCHAAP137: has joined #ruby
[10:35:41] linuxboytoo: has joined #ruby
[10:35:54] hahuang65: has joined #ruby
[10:38:42] acke: has joined #ruby
[10:39:01] joelataylor: has joined #ruby
[10:39:31] Igorshp: has joined #ruby
[10:39:41] acke: has joined #ruby
[10:40:05] jonee: has joined #ruby
[10:40:30] ddarkpassenger: has joined #ruby
[10:41:28] Trynemjoel: has joined #ruby
[10:42:54] mistermocha: has joined #ruby
[10:47:06] dorei: has joined #ruby
[10:48:21] DEA7TH: has joined #ruby
[10:53:44] pandaant: has joined #ruby
[10:54:15] hahuang65: has joined #ruby
[10:54:30] despai: has joined #ruby
[10:57:14] phutchins: has joined #ruby
[10:58:48] ht__: has joined #ruby
[11:01:23] sepp2k1: has joined #ruby
[11:01:59] Trynemjoel: has joined #ruby
[11:03:39] jonee: has joined #ruby
[11:08:53] radgeRayden: has joined #ruby
[11:10:30] Trynemjoel: has joined #ruby
[11:11:23] arup_r: has joined #ruby
[11:11:33] hahuang65: has joined #ruby
[11:12:37] CloCkWeRX: has joined #ruby
[11:16:41] ndrei: has joined #ruby
[11:16:56] Xeago: has joined #ruby
[11:22:09] mandarinkin: has joined #ruby
[11:23:10] sdothum: has joined #ruby
[11:24:12] omegamike: has joined #ruby
[11:24:18] jonee: has joined #ruby
[11:24:40] workmad3: has joined #ruby
[11:25:14] kirun: has joined #ruby
[11:26:10] iateadonut: i'm trying to create a function, that queries a different model depending on a variable.
[11:26:22] iateadonut: so, def getoords(id, type)
[11:26:47] iateadonut: customer = type.find(id) - type is the model, and can be 'Customers' or 'Dealers'
[11:29:58] Soda: has joined #ruby
[11:30:22] apeiros: iateadonut: getoords(5, Customer) # this will already work
[11:30:59] apeiros: because `type = Customer; type.find(5)` works just fine. classes are objects. objects can be assigned to variables.
[11:31:13] despai: has joined #ruby
[11:31:20] sarkyniin: has joined #ruby
[11:32:15] sanguisdex: has joined #ruby
[11:32:16] iateadonut: i had to do: type.constantize.find(id)
[11:32:32] iateadonut: let me see...
[11:33:15] iateadonut: from the console is there a way i can reload the application (in order to keep my command line history) or do i have to exit and restart the console?
[11:33:55] iateadonut: (you're right. worked just fine.) my second question is can i have the word 'model' as a function argument?
[11:34:00] jhass: iateadonut: http://stackoverflow.com/a/10467597/2199687
[11:34:12] iateadonut: lke def getCoords(id, model) - or is model a reserved word?
[11:34:34] jhass: no it's not reserved
[11:34:41] ddarkpassenger: has joined #ruby
[11:34:44] jhass: btw getCoords is how you would name the method in Java
[11:34:50] jhass: this isn't Java
[11:35:07] [k-: this shouldn't be java
[11:35:13] hahuang65: has joined #ruby
[11:35:21] iateadonut: i'm not getting you. what should i do instead?
[11:35:22] jhass: so name it coords or find_coords or something
[11:35:47] apeiros: iateadonut: if you had to do .constantize, then it means you did NOT pass in Customer, but "Customer"
[11:35:51] [k-: better yet, just find
[11:35:51] iateadonut: you mean no camel case?
[11:35:59] iateadonut: apeiros, you are right. thanks.
[11:36:00] apeiros: those two are NOT the same. one is a class, the other a string.
[11:36:03] jhass: yes, no camelCase, but snake_case
[11:36:08] jhass: and no get_ prefixes
[11:36:13] apeiros: and no set_
[11:36:18] jhass: and instead of set_ prefixes use foo=
[11:36:21] apeiros: and mostly no is_ or has_
[11:36:32] jhass: instead of is_ use foo?
[11:36:43] apeiros: setFoo, getFoo, isFoo -> foo=, foo, foo?
[11:37:10] arpe: has joined #ruby
[11:37:26] shock_one: has joined #ruby
[11:37:53] symm-: has joined #ruby
[11:39:40] iateadonut: from the irb shell is there a way i can reload the application or do i have to exit and restart the console when i make a change?
[11:39:56] apeiros: iateadonut: rails?
[11:40:14] apeiros: ?rails iateadonut
[11:40:14] ruboto: iateadonut, Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[11:40:19] apeiros: also this ^ ;-)
[11:42:25] RegulationD: has joined #ruby
[11:42:55] iateadonut: ok. in my method, i'm going to use a couple of different values for variables depending on the value of 'type' that is first entered. do i just do if elseif here?
[11:43:49] iateadonut: also, since 'type' is a model, what would the operand look like to compare if the variable 'type' == Customers.instance_of()?
[11:46:11] tubulife-: has joined #ruby
[11:46:12] mistermocha: has joined #ruby
[11:46:28] apeiros: ?crosspost iateadonut
[11:46:28] ruboto: iateadonut, Please do not crosspost without at least telling so and mentioning provided suggestions and their outcome in all channels. Experience shows that people don't do either, and not doing so is considered rude.
[11:46:45] joonty: has joined #ruby
[11:48:03] kiddorails: has joined #ruby
[11:48:57] iateadonut: i didn't crosspost. i only asked the ruby question after you said to ask it there.
[11:49:47] bronson: has joined #ruby
[11:52:06] sarkyniin: has joined #ruby
[11:53:59] iateadonut: jhass, thanks, i didn't see that before.
[11:54:37] iateadonut: apeiros, thanks.
[11:55:30] ledestin: has joined #ruby
[11:56:10] tno: has joined #ruby
[11:57:29] busterarm: has joined #ruby
[11:59:15] hahuang65: has joined #ruby
[12:00:41] juanpablo_: has joined #ruby
[12:00:54] Igorshp: has joined #ruby
[12:05:23] user1138: has joined #ruby
[12:08:27] ddarkpassenger: has joined #ruby
[12:10:29] ruby-lang060: has joined #ruby
[12:11:05] ruby-lang060: how to expire url using FOG::Storage?
[12:11:05] iateadonut: to rephrase, is it better to make my argument a string, and then assign my model and other variables based on the string, or should i check if var == Model.instance_of()? and what is the correct way to write Model.instance_of()?
[12:11:30] mary5030: has joined #ruby
[12:12:00] ruby-lang060: how to expire public_url to abort download from aws3 using FOG::storage
[12:12:09] safeforge: has joined #ruby
[12:12:28] [k-: people generally use is_a?
[12:12:46] [k-: kind_of? is more restrictive than is_a?
[12:13:06] ruby-lang060: any one can help me out?
[12:13:12] apeiros: [k-: kind_of? is an alias of is_a?
[12:13:19] apeiros: instance_of? is the one which is more restrictive
[12:13:34] [k-: sorry got messed up
[12:15:35] ruby-lang060: how to expire public_url to abort download from aws3 using FOG::storage ?
[12:16:13] apeiros: ruby-lang060: if nobody knew an answer 5min ago, nobody will know now. it's no use to repeat your question every 5 minutes.
[12:16:48] Ilyas: has joined #ruby
[12:19:19] mary5030: has joined #ruby
[12:20:47] hahuang65: has joined #ruby
[12:21:01] ndrei: has joined #ruby
[12:23:13] antlong: has joined #ruby
[12:27:03] khebbie: has joined #ruby
[12:27:28] khebbie_: has joined #ruby
[12:28:17] bizportal: has joined #ruby
[12:28:44] banister: has joined #ruby
[12:32:21] Rollabunna: has joined #ruby
[12:32:51] IceyEC: has joined #ruby
[12:33:51] gheegh: has joined #ruby
[12:35:18] Ilyas: has joined #ruby
[12:36:47] jottr: has joined #ruby
[12:37:18] imfilp: has joined #ruby
[12:40:13] bruno-: has joined #ruby
[12:41:30] banister: has joined #ruby
[12:41:43] jottr_: has joined #ruby
[12:42:37] jonee: has joined #ruby
[12:43:40] yeticry: has joined #ruby
[12:43:54] Hanmac: has joined #ruby
[12:44:13] freerobby: has joined #ruby
[12:45:36] bruno-: has joined #ruby
[12:47:46] IceyEC: has joined #ruby
[12:49:52] mistermocha: has joined #ruby
[12:49:54] nalley: has joined #ruby
[12:50:52] zuQe8: has joined #ruby
[12:50:56] bruno-: has joined #ruby
[12:51:33] hahuang65: has joined #ruby
[12:51:49] krz: has joined #ruby
[12:58:05] khebbie: has joined #ruby
[12:58:14] khebbie_: has joined #ruby
[13:00:57] iateadonut: how do i use a variable within a method name?
[13:01:15] iateadonut: e.g. model.{var}_id = customer.id
[13:01:16] jhass: to call or to define it?
[13:01:34] iateadonut: where var = 'customer' or 'dealership'
[13:01:55] jhass: model.public_send("#{var}_id=", customer.id), but in AR just model["#{var}_id"] = customer.id
[13:02:13] jhass: activerecord
[13:02:48] jottr_: has joined #ruby
[13:02:54] iateadonut: thanks so much. i'm very new to ruby and you probably just saved me 10 or 20 minutes.
[13:03:25] jhass: well, I expect "variable in method name ruby"'s first google result to be some stackoverflow thread explaining it, so more like 2-3
[13:03:29] Rubie: has joined #ruby
[13:03:48] iateadonut: point taken.
[13:03:58] sevenseacat: you wouldnt typically set the ID like that
[13:04:24] sevenseacat: you would just set the record, eg. model.send("#{var}=", customer)
[13:04:37] jhass: yeah, btw sounds like you're reimplementing a polymorphic association there
[13:04:49] sevenseacat: its not a common thing to do
[13:05:22] [k-: we should not teach him about send!
[13:05:35] sevenseacat: I also really really question starting with a rails app if you're brand new to ruby, but thats an entirely different kettle of fish
[13:05:40] lannonbr: has joined #ruby
[13:07:08] iateadonut: i don't think it's a polymorphic association. it's a method that grabs addresses from a customer table, finds the coordinates and puts it into a coordinates table.
[13:07:15] iateadonut: but i want it to work for two sets of two tables.
[13:07:38] iateadonut: also, i'm quite familiar with laravel, which seems to have grabbed all it's concepts from ruby.
[13:07:58] tonsils: has joined #ruby
[13:08:00] iateadonut: eloquent having a very similar structure to activerecord, etc.
[13:08:14] jhass: s/ruby/rails/ you mean I guess
[13:08:24] iateadonut: yes, that too
[13:08:52] sevenseacat: so what does customer or dealership have to do with anything then
[13:09:29] iateadonut: is this room logged?
[13:09:37] jhass: see /topic
[13:09:48] lkba: has joined #ruby
[13:10:07] iateadonut: some records are stored in customer and some in dealership, but they have very similar structures.
[13:10:32] jhass: so you have Coordinates or whatever that either belongs to Customer or belongs to Dealership
[13:10:35] Alina-malina: has joined #ruby
[13:10:35] DaniG2k: has joined #ruby
[13:10:39] jhass: sounds pretty polymorphic to me
[13:11:07] iateadonut: ok. i thought polymorphic was when customers belongs_to dealers.
[13:11:33] busterarm: I question people who start Rails apps without understanding how databases work, but it happens a lot
[13:11:36] decoponio: has joined #ruby
[13:12:00] iateadonut: ACTION tries not to get defensive
[13:12:15] busterarm: and I say that having done that myself, not really grasping MVC and then going off and learning SQL, reading ActiveRecord's source and then jumping into Rails again
[13:12:18] krz: has joined #ruby
[13:12:34] omegamike: has joined #ruby
[13:12:37] freerobby: has joined #ruby
[13:13:03] pontiki: one of Rails's key selling points has long been you don't have to worry about the database, though, so it shouldn't really be that surprising
[13:13:32] workmad3: has joined #ruby
[13:13:33] busterarm: yeah but 'not having to worry about it' isn't the same thing as 'not knowing what it is'
[13:13:52] pontiki: it's a pretty close statement
[13:14:00] pontiki: i'm not defending it
[13:14:28] iateadonut: i know sql very well, so i can certainly be taught how i'm supposed to code the models.
[13:14:41] iateadonut: i have two tables (that i can't change): dealerships and customers
[13:14:53] iateadonut: i made two more: coordinates and coor_dealers
[13:14:57] busterarm: i wasn't saying you don't
[13:15:12] adaedra: [k-, Ox0dea
[13:15:16] busterarm: was just lazily following sevenseacat's comment
[13:15:18] iateadonut: (i mean to say, what you are saying will not fall on deaf ears; thanks for helping me)
[13:15:19] adaedra: yes I sleep at 4am
[13:16:06] [k-: hello adaedra :>
[13:16:53] sigurding: has joined #ruby
[13:17:03] mikecmpb_: has joined #ruby
[13:17:04] GooseAlan: has joined #ruby
[13:17:39] linuxboytoo: has joined #ruby
[13:17:57] bustrarm: has joined #ruby
[13:17:57] CBke: has joined #ruby
[13:17:57] CBke: has joined #ruby
[13:18:08] durazno: has joined #ruby
[13:18:53] SCHAAP137: has joined #ruby
[13:20:11] PhantomS_: has joined #ruby
[13:21:59] silverdust: has joined #ruby
[13:22:23] pipework: has joined #ruby
[13:23:08] hahuang65: has joined #ruby
[13:23:30] Hiro`: has joined #ruby
[13:23:51] alem0lars: has joined #ruby
[13:24:13] freerobby: has joined #ruby
[13:25:56] iamse7en: has joined #ruby
[13:26:15] hj2007: has joined #ruby
[13:26:28] Hiro`: Hey guys, I'm not too familiar with Ruby, but I've written a method that contains a bunch of local variables, some loops, and a helper method that handles error checking. In the error-checking method I would like to examine some of the local variables, but IRB throws NameErrors, saying that they are not defined. Is there a way to do this in Ruby?
[13:26:53] apeiros: ?guys Hiro`
[13:26:53] ruboto: Hiro`, we're not all guys - while you probably don't meant to be exclusive, not everybody feels that way. Maybe consider using "folks", "y'all" or "everyone" instead?
[13:27:38] jhass: Hiro`: local variables are, well, local. You have to pass them explicitly to widen their scope
[13:27:44] apeiros: Hiro`: how do you run the code in irb? also, please put your gist and session on gist.github.com
[13:27:51] CloCkWeRX: has left #ruby: ()
[13:28:39] Trynemjoel: has joined #ruby
[13:28:59] banister: has joined #ruby
[13:29:53] shock_one: has joined #ruby
[13:29:54] mary5030: has joined #ruby
[13:31:13] DaniG2k: has joined #ruby
[13:31:19] WillAmes: has joined #ruby
[13:31:26] juanpablo_: has joined #ruby
[13:32:48] bradleyprice: has joined #ruby
[13:33:12] victortyau: has joined #ruby
[13:34:20] tubulife-: has joined #ruby
[13:34:23] nettoweb: has joined #ruby
[13:35:20] Hiro`: In Python I can refer to local variables that are in the closure of function definitions. Is there no way to do the same in Ruby?
[13:37:07] jhass: regular method definitions do not closure
[13:37:32] jhass: maybe you want to make a class?
[13:37:39] jhass: sounds like your method is too big anyway
[13:38:44] jottr: has joined #ruby
[13:39:25] Hiro`: apeiros: "guys" is often used colloqially to mean people people of either sex -- at least where I'm from. I'm sorry if you were offended by it.
[13:39:29] Xeago: has joined #ruby
[13:39:32] apeiros: ?guys2 Hiro`
[13:39:32] ruboto: Hiro`, it doesn???t matter if it???s "normal"/gender neutral to say "guys" in your idiolect. "You guys" to refer to a mixed group is erasure. All we ask from you is to be a decent channel member and respect that. If you want to further discuss this, join #ruby-offtopic.
[13:39:37] FernandoBasso: has joined #ruby
[13:39:47] sankaber: has joined #ruby
[13:40:09] apeiros: I'm not offended by it. The point is that you're essentially not-greeting (potentially) half of the channel.
[13:40:31] Hiro`: I don't want to discuss it at all, I was simply apologising.
[13:40:58] apeiros: and I simply try to make this channel welcome for not just guys.
[13:41:05] sarkyniin: has joined #ruby
[13:41:15] Hiro`: Also, I'm *potentially* not greeting the *entire* channel, if you think I'm deliberately excluding women from my greeting.
[13:42:12] bustrarm: ACTION takes a sip of his drink
[13:44:00] Hiro`: And describing "guys" as "erasure" is, frankly, compeletly idiotic. I think I'll take my newly discovered sexism somewhere else.
[13:44:03] Hiro`: has left #ruby: ("ERC Version 5.3 (IRC client for Emacs)")
[13:44:31] apeiros: fascinating how it's only guys who ever say that??? good bye.
[13:45:21] hahuang65: has joined #ruby
[13:45:50] pontiki: therein lies the conundrum
[13:46:51] apeiros: I think it's pretty obvious. it's easy to shrug off that kind of thing if you're never the target.
[13:48:09] railswebdev: has joined #ruby
[13:48:49] ged__: has joined #ruby
[13:49:55] DLSteve: what is "erasure", all Google brings up is a band.
[13:50:12] stonith: has joined #ruby
[13:50:20] bustrarm: check out Always
[13:50:23] bustrarm: that song rules
[13:50:28] [k-: search define erasure
[13:51:01] bustrarm: erasure is the reason why that band is called erasure
[13:51:54] DLSteve: so "the removal of writing, recorded material, or data."?
[13:52:41] DLSteve: busterarm, Oh, it's the robot Unicorn song lol
[13:53:19] busterarm: that game rules too
[13:55:27] mistermocha: has joined #ruby
[13:57:02] dfockler: has joined #ruby
[13:58:04] ruby-lang175: has joined #ruby
[13:58:23] bmurt: has joined #ruby
[13:58:38] tkuchiki: has joined #ruby
[13:59:23] iamninja: has joined #ruby
[13:59:41] Trynemjoel: has joined #ruby
[14:02:35] jonee: has joined #ruby
[14:03:52] noethics: has joined #ruby
[14:04:46] Rubie: has joined #ruby
[14:05:13] [k-: has joined #ruby
[14:05:19] DaniG2k: does anyone know how to save to activerecord from a ruby gem?
[14:05:28] DaniG2k: via a rake task
[14:05:46] DaniG2k: I've written down some of my code in this question: http://stackoverflow.com/questions/31624602/create-an-inverted-index-from-an-unknown-model
[14:08:14] hj2007: has joined #ruby
[14:08:41] haxrbyte: has joined #ruby
[14:08:47] jbw: has joined #ruby
[14:09:15] leat3: has joined #ruby
[14:12:33] [k-: has joined #ruby
[14:14:05] hahuang65: has joined #ruby
[14:15:18] jbw: has joined #ruby
[14:16:31] pontiki: DaniG2k: i probably don't understand, but couldn't you equally intercept after_save and launch a delayed task to build the inverted index?
[14:17:19] lordkryss: has joined #ruby
[14:17:25] pontiki: or was your question "how do i build an inverted index?" ?
[14:17:56] DaniG2k: pontiki: I think I got the saving part. I was able to intercept it with ActiveSupport::Concern's before_save
[14:18:07] pontiki: yes, i'm talking about point 2
[14:18:24] DaniG2k: pontiki: I guess my question is now more along the lines of, once a model gets saved, how can I edit another db table
[14:18:45] DaniG2k: basically everty time someone adds content to a given model, I'd like my gem to update the inverted index table
[14:18:50] pontiki: and my question is, can't you use after_save like you're using before_save?
[14:19:01] DaniG2k: pontiki: sure thing
[14:19:11] DaniG2k: pontiki: i dont think the order is important right now
[14:19:17] DaniG2k: i am just trying to get the basics to work
[14:19:20] pontiki: what does order have to do with it?
[14:19:23] havenwood: has joined #ruby
[14:19:37] DaniG2k: pontiki: before/after save. Both work :)
[14:19:54] pontiki: after_save runs after the model saves, right? you want your other model updated after this model is saved, right?
[14:19:56] fullofcaffeine: has joined #ruby
[14:20:12] DaniG2k: so its fine
[14:20:16] DaniG2k: before_save, after_save
[14:20:23] DaniG2k: this part works
[14:20:25] pontiki: so use after_save to trigger the update in the other model
[14:20:44] DaniG2k: hmmm no maybe I'm not describing my problem properly
[14:21:01] DaniG2k: I have a gem called Foo and a Rails app called Bar
[14:21:10] DaniG2k: Bar includes Foo in the Gemfile
[14:21:18] DaniG2k: I create a model in Bar
[14:21:50] DaniG2k: and when I save that, I want Foo to use its own database table to create an inverted index of the data that Bar passed
[14:22:03] DaniG2k: I was able to get the after_save part down so that's fine
[14:22:23] pontiki: then i ask again: is the question really "how do i build an inverted index?" ?
[14:22:26] DaniG2k: I'm tyring to figure out how to create Foo's database and how to add data to it
[14:22:46] sevenseacat: you do not want to be running rake tasks in model callbacks
[14:22:50] pontiki: that's a hugely different question than the one in the stackoverflow
[14:22:52] sevenseacat: thats just insanity
[14:23:01] sevenseacat: indeed, it is
[14:23:04] pontiki: which is why i said use a delayed job
[14:23:27] KrzaQ: I have a problem with ruby on windows: p [Encoding.default_external, Encoding.default_internal] produces [#<Encoding:CP852>, nil] even though I put #encoding: utf-8 at the top of the file.
[14:23:38] dtzitz: has joined #ruby
[14:23:41] KrzaQ: Ruby version: ruby 2.2.2p95 (2015-04-13 revision 50295) [x64-mingw32]
[14:23:49] ruboto: we're not all guys - while you probably don't meant to be exclusive, not everybody feels that way. Maybe consider using "folks", "y'all" or "everyone" instead?
[14:24:05] Vile`: has joined #ruby
[14:24:23] ruboto: I don't know anything about cats
[14:24:24] sevenseacat: I know, presuming gender of everyone really is weird, isnt it
[14:24:53] dtzitz: I am just going to use the term 'scumbags' as an inclusive term
[14:25:01] dtzitz: sup scumbags
[14:25:09] shevy: bye dtzitz :)
[14:25:14] dtzitz: has left #ruby: ("WeeChat 1.2")
[14:25:16] sevenseacat: something tells me you might not last long here
[14:25:49] Coraline: Also hi everyone
[14:25:54] apeiros: sevenseacat: you should reconsider your career options. I see a great future as an oracle or prophet!
[14:25:57] sevenseacat: evening Coraline
[14:26:13] apeiros: hi there Coraline & sevenseacat
[14:26:23] JeramyRR: has joined #ruby
[14:26:55] timonv: has joined #ruby
[14:27:06] qwebirc2802: has joined #ruby
[14:27:31] pontiki: hi Coraline
[14:28:28] MrJiks: has joined #ruby
[14:29:17] nobitanobi: has joined #ruby
[14:29:40] haxrbyte: has joined #ruby
[14:31:08] gambl0re: has joined #ruby
[14:31:53] tkuchiki: has joined #ruby
[14:32:26] centrx: has joined #ruby
[14:32:35] charliesome: has joined #ruby
[14:34:46] [k-: has joined #ruby
[14:34:50] bmurt: has joined #ruby
[14:35:00] hahuang65: has joined #ruby
[14:35:43] Trynemjoel: has joined #ruby
[14:38:01] Xeago: has joined #ruby
[14:40:39] busterarm: how do we feel about 'doodz'?
[14:40:59] shevy: what is that
[14:41:13] shevy: we already have him here... the dudedudeman
[14:41:37] DLSteve: has joined #ruby
[14:41:53] leafybasil: has joined #ruby
[14:42:50] [k-: has joined #ruby
[14:44:43] qwebirc2802: what does that mean? how do we feel about 'doodz'?
[14:46:50] jhass: qwebirc2802: ignore it. How's your Ruby?
[14:47:29] qwebirc2802: eh, not bad. guess I am supposed to get on the microframework bandwagon and just do an API and then do all my MVC stuff on the front end
[14:47:39] qwebirc2802: that's what the cool kids are doing these days?
[14:48:11] jhass: do whatever is fun and rewarding to you
[14:48:11] babyswizz: has joined #ruby
[14:48:28] busterarm: as far as being an inclusive term
[14:48:36] busterarm: it just came up a couple times
[14:48:41] jhass: ?ot busterarm
[14:48:41] ruboto: busterarm, this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
[14:51:08] qwebirc2802: ahh busterarm good luck with that, IMO if you can't find the right balance you can rip a community to shreds but that's all offtopic and not a rabbit hole I would like to visit after seeing it in the python community
[14:52:08] ciwolsey: has joined #ruby
[14:52:11] NeverDie: has joined #ruby
[14:53:10] vpereira: has joined #ruby
[14:53:27] vpereira: any client code using faye and celluloid?
[14:53:46] vpereira: i just find examples using EM.. and i dont want to use it :(
[14:53:58] pontiki: qwebirc2802: it's now all Mvc on the back end and MVVM on the front end :>
[14:53:59] centrx: Hey losers
[14:54:56] qwebirc2802: MVC was easy enough to grok but I never really did wrap my head around mvvm
[14:54:59] babyswizz: Hi all, am still new to ruby and would like to know if it's possible to build a mobile app which has a good GUI but not web or server based using RnR
[14:55:09] Azure: has joined #ruby
[14:55:36] jhass: babyswizz: check ruboto and rubymotion
[14:56:37] babyswizz: jhass: are you saying it's not possible on RnR?
[14:57:20] jhass: (assuming you mean Ruby on Rails, RoR), I thought you didn't want to use it?
[14:57:31] buggs: has joined #ruby
[14:57:36] gaboesquivel: has joined #ruby
[14:58:22] Mendenhall: has joined #ruby
[14:58:45] ciwolsey: guys, what is RnR ?
[14:58:52] ciwolsey: Ruby n' Rails?
[14:58:55] RegulationD: has joined #ruby
[14:59:05] omegamike: has joined #ruby
[14:59:10] ruboto: we're not all guys - while you probably don't meant to be exclusive, not everybody feels that way. Maybe consider using "folks", "y'all" or "everyone" instead?
[14:59:16] shevy: there is no RnR
[14:59:17] centrx: Toys R' Us
[14:59:27] mistermocha: has joined #ruby
[14:59:50] ciwolsey: I prefer to go by the 90s TV episode "Friends" usage of the word
[14:59:57] jhass: ?guys2 ciwolsey
[14:59:57] ruboto: ciwolsey, it doesn???t matter if it???s "normal"/gender neutral to say "guys" in your idiolect. "You guys" to refer to a mixed group is erasure. All we ask from you is to be a decent channel member and respect that. If you want to further discuss this, join #ruby-offtopic.
[15:00:21] ciwolsey: Since I find usage within popular culture a better indicator than wherever you learned it from.
[15:00:21] centrx: ?ot jhass
[15:00:21] ruboto: jhass, this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
[15:00:26] ciwolsey: And it doesn't get much more popular than friends.
[15:00:52] jhass: ciwolsey: continue in #ruby-offtopic please, I don't wan to remove you from the channel
[15:00:59] hahuang65: has joined #ruby
[15:01:08] ciwolsey: You started the discussion.
[15:01:22] babyswizz: jhass: Yea I meant RoR and I wasn't saying I didn't want to use it. I just thought it supports only web based apps and that's not what am looking at here
[15:01:25] jhass: there's no discussion, I informed you about something
[15:01:38] dseitz: has joined #ruby
[15:01:57] qwebirc2802: wow, there seems to be more interest in policing the community than participating in it =(
[15:02:01] jhass: babyswizz: RoR is a framework for build web applications that right. You don't want to do that so you probably shouldn't use it
[15:02:11] ciwolsey: Yes, please don't push your opinionated definitions on me in this channel.
[15:02:13] workmad3: has joined #ruby
[15:02:17] ciwolsey: I'm here for Ruby and Rails.
[15:02:22] Coraline: Every community has rules and standards.
[15:02:23] jhass: ?rails ciwolsey
[15:02:24] ruboto: ciwolsey, Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[15:02:24] havenwood: ciwolsey: Rails is a gem. There's a #RubyOnRails channel specifically for Rails.
[15:02:32] buggs: has left #ruby: ("WeeChat 0.4.2")
[15:02:48] ciwolsey: I'm here for Ruby then.
[15:02:51] havenwood: ciwolsey: Rails is one of many Rack adapters.
[15:02:59] shevy: we are all here for ruby \o/
[15:03:09] havenwood: ciwolsey: https://rack.github.io/
[15:03:16] centrx: Yeah why are you calling out one Rack adapter when everyone knows all the Rack adapters are good
[15:03:17] Coraline: For simple APIs sometimes Sinatra is a decent choice.
[15:03:23] pontiki: i'm secretly trying to get everyone to learn elixir and defect
[15:03:25] Coraline: Depending on your needs.
[15:03:30] qwebirc2802: cool, alright well enjoy policing your community, sure it makes it better I am going to just find somewhere that is a little more technical and a little less... whatever this is
[15:03:31] havenwood: Or Roda! \o/
[15:03:34] centrx: pontiki, what's Defect?
[15:03:40] jhass: pontiki: s/elixir/crystal/
[15:03:44] shock_one: has joined #ruby
[15:03:54] pontiki: defect is a verb
[15:04:02] centrx: not for long! github
[15:04:05] shevy: sevenseacat also was learning elixir, havenwood too, there is a lot of trendy learning going on
[15:04:11] pontiki: it's also a noun, but my usage was the verb form
[15:04:15] microspino: has joined #ruby
[15:04:19] apeiros: is today sockpuppet day?
[15:04:19] centrx: hmm, I better write this down
[15:04:22] Coraline: I think Dave Thomas' interest was a tipping point for a lot of people.
[15:04:25] Reventlov: has joined #ruby
[15:04:33] slash_nick: lol...get everyone to learn elixir and to defect... pontiki , i read it like centrx
[15:04:54] [k-: to defect means to stop following
[15:05:01] shevy: it's gotta be a new programming language
[15:05:02] centrx: I thought that was defecate
[15:05:12] [k-: north Korean escapers are called defectors
[15:05:15] [k-: I think
[15:05:40] pontiki: you are all post-cold-war babies aren't you :)
[15:06:05] slash_nick: pontiki: or they haven't watched enough spy shows or read enough tom clancy
[15:06:29] shevy: [k- I thought they are called traitors
[15:06:42] pontiki: shevy: only by the losing side
[15:07:09] shinnya: has joined #ruby
[15:08:48] babyswizz: has left #ruby: ()
[15:09:43] ynasser: has left #ruby: ()
[15:09:50] freerobby: has joined #ruby
[15:10:06] ndrei: has joined #ruby
[15:11:04] haxrbyte: has joined #ruby
[15:13:00] mary5030: has joined #ruby
[15:13:23] Scriptonaut: Hey guys, I am requiring activesupport, but I still can't use to_options
[15:13:32] Scriptonaut: it tells me undefined method `to_options' for Hash
[15:14:00] adaedra: iirc, activesupport requires to load parts manually
[15:14:15] havenwood: Scriptonaut: My maybe-not-so-helpful idea is to use the Sequel gem. :P
[15:14:34] freerobby: has joined #ruby
[15:14:39] slash_nick: havenwood: why, does that load the parts?
[15:14:54] busterarm: has joined #ruby
[15:15:08] Scriptonaut: I just wanna quick way to convert the strings in a hash to symbols
[15:15:13] havenwood: slash_nick: I just meant to not be using ActiveSupport. I guess I was assuming (probably incorrectly?) that it's outside of Rails.
[15:15:23] Scriptonaut: guess I'll have to include hashwithindifferentaccess
[15:15:31] Scriptonaut: havenwood: ya no rails
[15:15:37] shevy: that name alone, look at how long it is!
[15:15:39] Scriptonaut: I like activesupport quite a bit
[15:15:47] havenwood: Scriptonaut: <3 Sequel gem.
[15:15:48] Coraline: http://apidock.com/rails/Hash/symbolize_keys
[15:15:55] slash_nick: shevy: and that's without the underscores
[15:15:56] Coraline: ^ Scriptonaut
[15:16:06] Scriptonaut: Coraline: that's rails
[15:16:07] shevy: slash_nick haha yeah
[15:16:10] Scriptonaut: I'm not using rails
[15:16:12] slash_nick: but rails is not a dep
[15:16:21] Scriptonaut: thanks anyways
[15:16:26] Coraline: Sorry, missed that bit.
[15:16:31] Coraline: ACTION needs moar coffee
[15:16:44] tkuchiki: has joined #ruby
[15:16:44] havenwood: ACTION needs coffee desperately
[15:17:02] Scriptonaut: ACTION is on his 4th shot of espresso
[15:17:12] Coraline: I had one cup of weak stuff
[15:17:20] slash_nick: ACTION is still feeling his 4th shot of something
[15:17:21] DexterLB: hello. I have a TCP connection, and I keep an open socket. The server sends some json data every few seconds. Is there a way to read the json objects as they come, without waiting for EOF?
[15:17:22] busterarm: has joined #ruby
[15:17:23] havenwood: I've been too lazy to get out of bed.
[15:17:29] havenwood: If I just had coffee...
[15:17:31] Scriptonaut: lol slash_nick
[15:17:50] Scriptonaut: time differences in irc are always weird
[15:17:59] jhass: DexterLB: what'd you do in the meantime?
[15:18:00] slash_nick: Scriptonaut: it's 10 AM
[15:18:08] havenwood: Scriptonaut: Just want to turn keys to symbols?
[15:18:21] Scriptonaut: havenwood: indeed, I coudl write it myself but I figured there would be somethin nifty
[15:18:28] Scriptonaut: it's probably a one liner
[15:18:58] thiagovsk: has joined #ruby
[15:19:12] adaedra: map { |k, v| [k.to_sym, v] }.to_h
[15:19:13] havenwood: Scriptonaut: map { |k, v| [k.to_sym, v] }.to_h
[15:19:13] DexterLB: jhass: nothing, I imagine something like "loop do; data = read_json(socket); process(data); done"
[15:19:25] adaedra: haha havenwood
[15:19:28] havenwood: adaedra: jinx
[15:19:29] Scriptonaut: Hash( my_hash.ya, thanks
[15:19:33] mary5030: has joined #ruby
[15:19:34] jottr: has joined #ruby
[15:19:37] DexterLB: jhass: so in the meantime I just sleep, preferably blocked in the read function
[15:19:37] Scriptonaut: started writing it out
[15:19:42] FernandoBasso: has joined #ruby
[15:19:54] jhass: DexterLB: ah, your protocol would either need a clear delimiter or some bytes to read signaling
[15:19:54] Scriptonaut: is there native thread support in ruby yet
[15:19:59] Scriptonaut: I remember a few years ago there wasn't
[15:20:12] juanpablo_: has joined #ruby
[15:20:19] Scriptonaut: you had to use jruby back then for threads
[15:20:36] havenwood: Scriptonaut: Ruby 1.8 did have green threads, yeah. Yes, native system threads now but there's still a GVL in CRuby.
[15:20:52] DexterLB: jhass: yeah, so there's no way to use the end of a toplevel json object as a delimeter?
[15:20:58] jhass: DexterLB: common delimiters would e.g. be \0 or \n
[15:21:13] jhass: not really, no
[15:21:25] hahuang65: has joined #ruby
[15:21:30] jhass: you could try if read_nonblock works for you, but that ends up in busy polling
[15:21:46] jhass: and using as } delimiter would break nested objects
[15:21:47] chipotle: has joined #ruby
[15:21:52] DexterLB: jhass: yeah, I want to avoid that
[15:22:07] DexterLB: jhass: is there a problem with using \n as a delimeter?
[15:22:24] adaedra: \n is valid inside JSON
[15:22:28] tubulife-: has joined #ruby
[15:22:55] slash_nick: DexterLB: what if you try to deserialize the json line by line, rescuing failures by trying the to deserialize lines + next-line...
[15:23:04] jhass: >> require "json"; "foo\nbar".to_json
[15:23:05] ruboto: jhass # => "\"foo\\nbar\"" (https://eval.in/405784)
[15:23:14] adaedra: DexterLB: are you always sending objects (i.e. always start and end by { and })?
[15:23:34] jhass: DexterLB: ^ seems to suggest there isn't, as long as your JSON serializer doesn't "prettify" that is
[15:23:37] DexterLB: adaedra: it's safe to assume that, yeah
[15:23:56] adaedra: because you could count { }, and trigger conversion when you go to 0 (so end of main object)
[15:24:05] DexterLB: jhass: yeah, I was thinking about just stripping all newlines from the json server-side, since they aren't a meaningful character
[15:24:15] adaedra: except if you can have strings containing unbalanced {}, which would made it harder
[15:24:20] bmurt: has joined #ruby
[15:24:21] DexterLB: and then using \n as delimeter client-side
[15:24:51] jhass: yeah, which makes it a simple .gets call on the socket
[15:24:51] DexterLB: adaedra: yeah, it's a possibility for strings to contain {}
[15:25:00] adaedra: DexterLB: unbalanced?
[15:25:26] adaedra: jhass: I was more thinking outside of strings, like {\n"hello":"world"\n}
[15:25:30] DexterLB: adaedra: probably, the string contents inside the objects can be user-provided
[15:25:30] slash_nick: DexterLB: is it just a bunch of json objects (line breaks after each json object), one huge json object, an array of json objects?
[15:25:37] adaedra: don't know what its source is
[15:25:54] jhass: adaedra: I realized later and hence my comment about "prettify"
[15:27:04] adaedra: DexterLB: instead of using a separator, you can also put the size of a JSON object before it, so you know exactly how much to read
[15:27:13] shock_one: has joined #ruby
[15:27:30] DexterLB: adaedra: nice idea
[15:27:46] j4cknewt: has joined #ruby
[15:28:24] jhass: I guess I'm too brief...
[15:29:00] jhass: <jhass> DexterLB: ah, your protocol would either need a clear delimiter or some bytes to read signaling
[15:29:18] Scriptonaut: this is weird, in my database.yml, db is rtlb_dev, user is my username, and password is also my username, but when I: psql -d rtlb_dev -U user_name -W, then enter the password, it says authentication failed
[15:29:42] DexterLB: jhass: sorry :P
[15:30:01] DexterLB: I still think I'll go with \n as a delimeter though
[15:30:18] jhass: Scriptonaut: join #postgresql, decent folk over there
[15:31:44] adaedra: less risks with \0 I would say
[15:31:59] adaedra: like jhass suggested
[15:33:44] livathinos: has joined #ruby
[15:34:39] aryaching: has joined #ruby
[15:37:18] s00pcan: has joined #ruby
[15:39:40] Oog: has joined #ruby
[15:39:48] Trynemjoel: has joined #ruby
[15:40:24] radgeRayden: has joined #ruby
[15:40:45] krz: has joined #ruby
[15:41:09] apt-get_: has joined #ruby
[15:41:17] sigurding: has joined #ruby
[15:43:32] vikaton: has joined #ruby
[15:43:52] Mendenhall: has joined #ruby
[15:45:45] charliesome: has joined #ruby
[15:46:04] Averna: has joined #ruby
[15:46:11] victortyau: has joined #ruby
[15:46:37] Guest0: has joined #ruby
[15:46:55] hahuang65: has joined #ruby
[15:47:38] malconis: has joined #ruby
[15:50:16] yaw: has joined #ruby
[15:50:40] yaw: has left #ruby: ()
[15:55:08] bruno-: has joined #ruby
[15:55:21] tkuchiki: has joined #ruby
[15:55:53] mois3x: has joined #ruby
[15:56:55] houhoulis: has joined #ruby
[15:57:53] Channel6: has joined #ruby
[15:57:55] DLSteve: has joined #ruby
[15:59:30] leat3: has joined #ruby
[15:59:47] Jarboe: has joined #ruby
[16:00:20] Scriptonaut: does anyone know how I can connect activemodel to activerecord?
[16:00:34] bruno-: has joined #ruby
[16:00:41] Scriptonaut: I want to have a model named User, and I want it to automatically connect to my users table in activerecord
[16:00:57] pontiki: activerecord includes activemodel
[16:01:19] Scriptonaut: oh, nice. So how do I go about making my model now that I have the activerecord table migrated and all that
[16:01:34] Scriptonaut: is there an easy: class User < ActiveModel
[16:01:39] Scriptonaut: is there an easy: class User < ActiveModel::Base or something
[16:01:55] Scriptonaut: do you have any docs/articles that can explain it to me?
[16:02:01] pontiki: but instead of inheriting active model, inherit active record
[16:02:08] pauly_oc: has joined #ruby
[16:02:15] Scriptonaut: ActiveRecord::Base?
[16:02:21] pontiki: just like in rails
[16:02:41] bhaak: has joined #ruby
[16:02:42] Scriptonaut: so I don't have to do any of the: include ActiveModel::Validations, etc
[16:02:45] Scriptonaut: that stuff will all be included?
[16:02:49] Scriptonaut: and will connect to the table?
[16:02:51] Scriptonaut: wow that's cool
[16:03:01] devdazed: has joined #ruby
[16:03:02] jhass: Scriptonaut: http://guides.rubyonrails.org/active_record_basics.html
[16:03:07] jhass: the other AR articles too
[16:04:41] mistermocha: has joined #ruby
[16:06:02] bruno-: has joined #ruby
[16:06:36] bestbrents: has joined #ruby
[16:08:27] Scriptonaut: I ran this migration: https://gist.github.com/robins35/0ee123ca3c7f69b50377 However the only table is "schema_migrations". Why isn't there a users table/
[16:09:10] hahuang65: has joined #ruby
[16:12:35] Blaguvest: has joined #ruby
[16:14:37] malconis_: has joined #ruby
[16:15:20] pontiki: Scriptonaut: do you think you might want to share the output of "running this migration" ?
[16:15:28] Scriptonaut: there is no output
[16:15:33] Scriptonaut: it seems to be successful
[16:15:53] pontiki: i guess there's no point in responding to your questions, then
[16:16:44] Scriptonaut: I'm willing to supply any helpful info, but what is there
[16:16:56] pontiki: how about "oh, it worked, never mind"
[16:17:14] Scriptonaut: it's not working, the table isn't beign created
[16:17:30] pontiki: wth does this mean, then: "< Scriptonaut> it seems to be successful"
[16:17:54] Scriptonaut: I mean at first glance running the migration, it doesn't error out, it seems at first to be successful, until you check the database
[16:18:15] pontiki: yeah, never mind
[16:18:59] Scriptonaut: I don't get it, what would you suggest I supply to make solving this easier
[16:19:25] JeramyRR: has joined #ruby
[16:19:48] shevy: I still don't quite understand the difference between: def self.foo versus module_function :foo
[16:20:21] tbuehlmann: shevy, when including a module, module functions become available as private methods
[16:21:26] bruno-: has joined #ruby
[16:21:39] shevy: so I essentially save myself to have to use private, if I use module_function?
[16:21:47] nalley: has joined #ruby
[16:21:55] iWaffles: has joined #ruby
[16:22:16] Cache_Money: has joined #ruby
[16:23:31] tbuehlmann: shevy, I think the primary usecase are Util-like modules on which you can call methods. when including them, you can call them from instances directly
[16:23:59] lannonbr: has joined #ruby
[16:24:06] PhantomSpank: has joined #ruby
[16:24:15] pyr0commie: has joined #ruby
[16:26:51] psye: has joined #ruby
[16:26:57] bruno-: has joined #ruby
[16:29:31] pontiki: tbuehlmann: an example would be FileUtils, where you can call, say, FileUtils.mkdir_p directory, or if you include FileUtils in a class, then you're able to call mkdri_p directly?
[16:29:38] safeforge: has joined #ruby
[16:30:20] PhantomSpank: has joined #ruby
[16:30:21] Reventlov: has left #ruby: ()
[16:32:19] bruno-: has joined #ruby
[16:33:07] shock_one: has joined #ruby
[16:33:19] fullofcaffeine: has joined #ruby
[16:33:25] jhass: shevy: module_function _copies_ the instance methods to the singleton class
[16:33:33] jhass: and makes the instance methods private
[16:33:37] jhass: (but not the copies)
[16:34:25] jhass: Scriptonaut: maybe you ran the migration and then edited to create the table and then ran it again?
[16:35:44] Scriptonaut: jhass: I thought that might be the case, so I dropped created and reran the migration, still no users table
[16:36:06] tbuehlmann: pontiki, using it in one of my libraries: https://github.com/tbuehlmann/lappen/blob/master/lib/lappen/request_context.rb - controller and view_context are available in the classes that include the module and on the module itself
[16:36:18] jhass: you're sure your (custom?) migrate task even picks it up?
[16:36:32] chinmay_dd: has joined #ruby
[16:36:49] tbuehlmann: one could argue about meaningfulness and encapsulation, but I think it's just handy in some situations
[16:36:51] Scriptonaut: I'll post my code that I use to migrate
[16:37:04] hashrocket: has joined #ruby
[16:37:09] [k-: you are going to make encapsulation sad :(
[16:37:32] Scriptonaut: jhass: https://gist.github.com/robins35/56bc447841d0bb4aa99f
[16:37:35] Scriptonaut: that's my db.rake file
[16:37:47] bruno-: has joined #ruby
[16:37:56] Scriptonaut: line 52 is where I migrate
[16:38:32] jhass: Scriptonaut: run File.expand_path on MIGRATIONS_DIR and then print it to check it's the correct path
[16:39:55] chouhoulis: has joined #ruby
[16:39:55] Scriptonaut: jhass: thank you so much
[16:40:13] Scriptonaut: I figured the current directory would be where the file was, but it was being included into the root
[16:41:10] icebourg: has joined #ruby
[16:41:25] jhass: Scriptonaut: you can make it deterministic with File.join(__dir__, "whatever"), __dir__ will be directory of the current file (so also File.expand_path if you got to join ..'s to it)
[16:42:02] pontiki: has left #ruby: (""Poets have been mysteriously silent on the subject of cheese" -- G.K.Chesterson")
[16:42:23] jwinder: has joined #ruby
[16:43:17] bruno-: has joined #ruby
[16:44:15] ledestin: has joined #ruby
[16:44:23] wallerdev: has joined #ruby
[16:44:53] hahuang65: has joined #ruby
[16:44:55] safeforge: has joined #ruby
[16:47:29] omegamike: has joined #ruby
[16:47:44] alienaut: has joined #ruby
[16:48:53] Trynemjoel: has joined #ruby
[16:49:34] bnizzle: has joined #ruby
[16:49:44] towski_: has joined #ruby
[16:50:57] juanpablo_: has joined #ruby
[16:51:05] apt-get_: has joined #ruby
[16:51:12] workmad3: has joined #ruby
[16:53:18] psye: has joined #ruby
[16:54:13] psye: has joined #ruby
[16:55:17] freeUmo: has joined #ruby
[16:56:53] khebbie: has joined #ruby
[16:57:02] khebbie_: has joined #ruby
[16:57:12] Vile`: has joined #ruby
[16:59:58] pengin: has joined #ruby
[17:00:36] tmtwd: has joined #ruby
[17:01:03] tkuchiki: has joined #ruby
[17:01:49] shevy: jhass hmm
[17:04:59] _lexjm: has joined #ruby
[17:09:43] alienaut: hey! when i am writing %w{1 2 3 4 5} ruby produces an array of strings but how can i produces array of integers?
[17:09:49] shevy: interesting that module_function makes it private
[17:10:06] shevy: extend self would work on the whole module. Is there something like module_function that retains it as public?
[17:10:13] shevy: on a per method basis
[17:10:37] tubulife-: has joined #ruby
[17:10:48] `derpy: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[17:15:26] Trynemjoel: has joined #ruby
[17:15:57] khebbie: has joined #ruby
[17:16:05] khebbie_: has joined #ruby
[17:17:23] busterarm: alienaut: would the integers be in a range?
[17:17:26] Saloaty: has joined #ruby
[17:17:29] christiandsg: has joined #ruby
[17:17:55] busterarm: (1..5).to_a would do that with ints
[17:18:09] hahuang65: has joined #ruby
[17:18:27] alienaut: busterarm: what if my ints arent sorted?
[17:18:53] busterarm: if they're not sorted, where are you getting them from in the first place?
[17:18:53] Stratege: has joined #ruby
[17:19:05] busterarm: what's the input?
[17:19:17] Scriptonaut: I'm not using rails, but I'm having this issue: http://stackoverflow.com/questions/27179138/rails-executing-migration-argumenterror I do a bundle update arel after setting it to gem 'arel', '6.0.2.beta2', and when I gem update arel and then run bundle install, it tells me that it can't find 'arel (= 6.0.2.beta) ruby' in any of the gem sources listed in my Gemfile or on the machine. What does that mean?
[17:19:42] alienaut: there is no input i am just wondering if it possible?
[17:19:46] jhass: alienaut: [1, 2, 3, 4, 5]
[17:20:27] busterarm: yes, making an array of integers is possible
[17:20:32] Scriptonaut: I think that's the problem at least, has anyone else gotten "wrong number of arguments (1 for 0)" when they run: create_table :users do |t|
[17:20:44] Ox0dea: busterarm: But there's no literal syntax for it like for %words.
[17:20:59] Ox0dea: %d(1 2 3) == [1, 2, 3] would be nice.
[17:21:14] jhass: Scriptonaut: looks like 6.0.2 got released, I see 6.0.0.beta2 but no 6.0.2.beta2
[17:21:26] Trynemjoel: has joined #ruby
[17:21:37] Scriptonaut: I'll try 6.0.2
[17:21:37] jhass: Scriptonaut: https://rubygems.org/gems/arel/versions
[17:21:46] alienaut: yea Ox0dea is right
[17:21:46] JeramyRR: has joined #ruby
[17:21:49] busterarm: but if you wanted to do something like that, either you have some kind of range or source you can build the array from, or you've already got an array...
[17:21:59] Ox0dea: >> %w[3 2 1].map(&:to_i) # alienaut
[17:22:00] ruboto: Ox0dea # => [3, 2, 1] (https://eval.in/405813)
[17:22:01] baweaver: has joined #ruby
[17:22:07] Saloaty: Scriptonaut: https://rubygems.org/gems/arel
[17:22:14] FernandoBasso: has joined #ruby
[17:22:29] bradleyprice: has joined #ruby
[17:22:42] jhass: I don't mind the few , in [3, 2, 1], it's the " that get annoying in ["a", "b", "c"]
[17:22:48] Scriptonaut: hrm, why the heck am I still getting that error then
[17:22:48] Saloaty: gem 'arel', '~> 6.0.2'
[17:22:52] jhass: .map(&:to_i) on a literal seems insane
[17:22:57] busterarm: a Range is already Enumerable. I'm guessing but probably less overhead than conversion from strings
[17:23:20] Scriptonaut: hrm, still getting the (1 for 0) error
[17:23:41] jhass: Scriptonaut: backtrace?
[17:24:30] alienaut: is it hard to fork ruby's itself and make my %d(3 2 1) # => [3, 2, 1]?
[17:24:50] jhass: if you don't fear parse.y ...
[17:25:14] Scriptonaut: jhass: https://gist.github.com/robins35/d3e5c72353febadaa48e
[17:25:23] Scriptonaut: that's what I get when I set Rake.application.options.trace = true
[17:25:53] jhass: run with --trace
[17:26:29] sigurding: has joined #ruby
[17:26:44] kriskropd: has joined #ruby
[17:27:51] jhass: *shrug*, get pry-rescue and wrap the migrator invocation into Pry.rescue { } ?
[17:29:21] Saloaty: has left #ruby: ("ruby")
[17:29:47] leat3: has joined #ruby
[17:30:14] howdoi_: has joined #ruby
[17:30:47] jonee: has joined #ruby
[17:30:48] swgillespie: has joined #ruby
[17:31:40] mistermocha: has joined #ruby
[17:32:07] phoo1234567: has joined #ruby
[17:35:10] TheNet: has joined #ruby
[17:35:58] Scriptonaut: jhass: I found the issue. Line 605 of active_record/migration.rb. It calls the method change, but doesn't pass it any arguments, it should be passing it one argument according to this
[17:36:45] Scriptonaut: this being the pry-byebug
[17:36:48] s00pcan: has joined #ruby
[17:36:49] Scriptonaut: should have specified my bad
[17:37:11] trouloulioud_dev: has joined #ruby
[17:37:41] Scriptonaut: ah, finally figured it out, thanks for helping me along jhass
[17:37:53] Scriptonaut: I had t.name rather than t.string
[17:38:18] trouloulioud_dev: has joined #ruby
[17:38:22] Rubie: has joined #ruby
[17:39:08] phoo1234567: has joined #ruby
[17:39:19] trouloulioud_dev: has joined #ruby
[17:43:00] michaeldeol: has joined #ruby
[17:43:27] `derpy: has joined #ruby
[17:43:37] leafybasil: has joined #ruby
[17:43:53] despai: has joined #ruby
[17:44:38] eggoez: has joined #ruby
[17:45:31] sarkyniin: has joined #ruby
[17:46:30] fullofcaffeine: has joined #ruby
[17:47:06] ninji: has joined #ruby
[17:49:16] Saloaty: has joined #ruby
[17:51:23] Saloaty: has left #ruby: ()
[17:53:14] christiandsg: has joined #ruby
[17:53:29] SCHAAP137: has joined #ruby
[17:54:45] hj2007: has joined #ruby
[17:55:22] hahuang65: has joined #ruby
[17:56:22] bubbys: has joined #ruby
[17:58:38] Mendenhall: has joined #ruby
[18:00:13] centrx: has joined #ruby
[18:00:36] Jackneill: has joined #ruby
[18:00:51] Maletor: has joined #ruby
[18:01:44] jottr: has joined #ruby
[18:02:56] nobitanobi: has joined #ruby
[18:03:08] eilkahn: has joined #ruby
[18:04:43] elia: has joined #ruby
[18:04:44] nobitanobi: has joined #ruby
[18:06:30] _djbkd: has joined #ruby
[18:07:08] ruboto: I don't know anything about list
[18:07:15] tkuchiki: has joined #ruby
[18:07:24] apeiros: centrx: you can ask ruboto in pm
[18:07:34] apeiros: it doesn't mind the query ;-p
[18:07:39] centrx: ah I was wondering about that
[18:07:52] pyr0commie: has joined #ruby
[18:08:22] lkba: has joined #ruby
[18:08:35] centrx: Try It And See
[18:08:51] hahuang65: has joined #ruby
[18:09:07] craysiii: is ruboto a bot
[18:09:38] codecop: has joined #ruby
[18:09:41] christiandsg: has joined #ruby
[18:10:25] apeiros: ?ruboto craysiii
[18:10:25] ruboto: craysiii, I'm the channel bot, linker of the rules, adept of the facts, wielder of the banhammer.
[18:12:33] craysiii: thats why it always seems they are copy pasting whenever someone says guys
[18:12:42] Yiota: has joined #ruby
[18:12:50] centrx: Here's my favorite:
[18:12:52] ruboto: I don't know anything about ruby
[18:13:07] shevy: craysiii yeah it's a spambot
[18:13:59] freerobby: has joined #ruby
[18:14:03] craysiii: who is their controller
[18:14:11] centrx: >> 9000 * :spam
[18:14:12] ruboto: centrx # => :spam can't be coerced into Fixnum (TypeError) ...check link for more (https://eval.in/405815)
[18:14:42] craysiii: >> loop { puts "hi" }
[18:14:45] ruboto: craysiii, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[18:14:46] shevy: craysiii I guess the bot queries an access control list of whoever has op powers on #ruby
[18:15:25] shevy: curious error... regular ruby loop {} won't use OpenURI
[18:15:44] ljarvis: that's an error from the bot http connection
[18:15:50] ljarvis: i.e the response from eval.in was a 500
[18:15:52] ljarvis: not the code
[18:16:02] craysiii: timed out probablyu?
[18:16:09] ljarvis: no 500 is not timeout
[18:16:40] apeiros: I'd assume that the server errs with 500 and returns a body saying something akin to "your code took too long and was killed"
[18:16:54] apeiros: try running it on eval.in directly
[18:17:11] ljarvis: i remember that returning something different actually
[18:17:17] ruboto: ljarvis # => (https://eval.in/405817)
[18:17:42] apt-get_: has joined #ruby
[18:17:43] ljarvis: anyway I'd still except that to not be 500. Seems like that was random
[18:17:59] craysiii: >> loop { puts "hello }
[18:18:00] ruboto: craysiii # => /tmp/execpad-ef13d391a7aa/source-ef13d391a7aa:7: syntax error, unexpected keyword_end, expecting '}' ...check link for more (https://eval.in/405818)
[18:18:19] craysiii: >> loop { puts "hello" }
[18:18:22] ruboto: craysiii, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[18:18:23] apeiros: mhm, indeed
[18:18:31] Ox0dea: >> 'x' * 1e30
[18:18:31] usershell: has joined #ruby
[18:18:32] ruboto: Ox0dea # => float 1e+30 out of range of integer (RangeError) ...check link for more (https://eval.in/405821)
[18:18:35] Ox0dea: >> 'x' * 1e20
[18:18:36] ruboto: Ox0dea # => float 1e+20 out of range of integer (RangeError) ...check link for more (https://eval.in/405822)
[18:18:48] apeiros: anyway, please do your experiments in the query
[18:18:57] shevy: cool... random errors \o/
[18:19:00] craysiii: what have i done.
[18:19:30] Ox0dea: craysiii: What do you mean?
[18:19:40] craysiii: i broke it /s
[18:19:49] Ox0dea: >> "It's working fine."
[18:19:51] ruboto: Ox0dea # => "It's working fine." (https://eval.in/405823)
[18:20:21] Ox0dea: apeiros: You made ruboto ignore Unicode space characters?
[18:21:07] Ox0dea: ?rub???oto
[18:21:07] ruboto: I don't know anything about rub
[18:21:14] Ox0dea: Interesting.
[18:21:16] apeiros: Ox0dea: don't look at me! I have no idea what I did!
[18:21:32] centrx: the bot writes itself, I swear!
[18:21:45] juanpablo_: has joined #ruby
[18:21:58] Ox0dea: Well, it seems friendly enough; I don't think we have to worry about being converted to paper clips.
[18:22:04] shevy: I thought the bot could not deal with unicode
[18:22:25] chinmay_dd: has joined #ruby
[18:22:25] Scriptonaut: can anyone figure out why my rake db:migrate is including my models directory for some reason? https://github.com/robins35/rubybot I can't for the life of me figure out why, it's requiring environment.rb even though I don't explicitly tell it to
[18:22:46] Yiota: has joined #ruby
[18:22:51] Scriptonaut: rake db:migratei s in lib/tasks/db.rake
[18:23:05] Hydrax: has joined #ruby
[18:23:13] Ox0dea: > mfw you don't expect implicit behavior in ruby
[18:23:37] Scriptonaut: :| I know. I don't know ruby well enough to know why it would require that file though
[18:23:43] jonee: has joined #ruby
[18:23:47] Scriptonaut: it doesn't impilcitly require other files
[18:24:32] bronson: has joined #ruby
[18:24:47] ght: Question: Anyone familiar with a method for determing "this week" from ActiveSupport::TimeZone?
[18:24:58] gregf: has joined #ruby
[18:26:20] centrx: ght, What?
[18:26:57] yeticry_: has joined #ruby
[18:27:06] shevy: never used active support
[18:27:53] linuxboytoo: has joined #ruby
[18:29:31] jhass: http://api.rubyonrails.org/classes/DateAndTime/Calculations.html#method-i-beginning_of_week
[18:29:50] ght: jhass: Perfect, thank you.
[18:29:55] bhaak: has joined #ruby
[18:30:44] centrx: That returns a day
[18:33:03] symm-: has joined #ruby
[18:33:22] Agoldfish: has joined #ruby
[18:33:34] Ox0dea: centrx: Yes, weeks begin with days.
[18:34:05] Ox0dea: New word?
[18:35:13] Yiota: has joined #ruby
[18:35:47] omegamike: has joined #ruby
[18:35:54] mistermocha: has joined #ruby
[18:36:02] centrx: TMI dude, HTML
[18:36:27] Ox0dea: Yep, must be your first day. :P
[18:36:39] houhoulis: has joined #ruby
[18:38:35] pyr0commie: has joined #ruby
[18:39:34] Yiota: has joined #ruby
[18:39:40] workmad3: has joined #ruby
[18:39:49] hahuang65: has joined #ruby
[18:39:53] apeiros: funny, I'd have thought week number
[18:40:16] apeiros: (and nothing really makes sense with *TimeZone*)
[18:40:30] centrx: yeah that's why I said "What?"
[18:40:34] craysiii: timezones should just not exist
[18:40:35] centrx: Thought that was clear
[18:40:42] craysiii: we should all be on the same time
[18:40:45] apeiros: craysiii: use swatch ebeat then ;-)
[18:41:13] apeiros: oh, they call it just "beat" today, I see.
[18:41:41] Yiota: has joined #ruby
[18:43:48] Alayde: has joined #ruby
[18:43:54] Ox0dea: centrx: Does next month start on Saturday or 30?
[18:45:09] apeiros: I think it starts on CEST
[18:45:24] RegulationD: has joined #ruby
[18:46:02] Trynemjoel: has joined #ruby
[18:47:32] freerobby: has joined #ruby
[18:48:55] Yiota: has joined #ruby
[18:52:13] FernandoBasso: has joined #ruby
[18:53:02] Trynemjoel: has joined #ruby
[18:56:18] dopie: has joined #ruby
[18:56:52] atmosx: has joined #ruby
[18:58:31] bl4ckdu5t: has joined #ruby
[18:58:49] tubulife-: has joined #ruby
[18:58:55] Yiota: has joined #ruby
[18:59:36] usershell: has joined #ruby
[18:59:45] IceyEC: has joined #ruby
[19:00:41] elia: has joined #ruby
[19:01:16] Yiota: has joined #ruby
[19:01:41] christiandsg: has joined #ruby
[19:01:58] pocketprotector: has joined #ruby
[19:02:46] usershell: has joined #ruby
[19:03:19] bruno-: has joined #ruby
[19:04:06] Fernando-Basso: has joined #ruby
[19:06:11] yfeldblum: has joined #ruby
[19:07:56] shinnya: has joined #ruby
[19:08:06] tkuchiki: has joined #ruby
[19:09:08] khebbie: has joined #ruby
[19:09:11] khebbie_: has joined #ruby
[19:09:56] jottr: has joined #ruby
[19:10:09] hahuang65: has joined #ruby
[19:11:12] pothibo: has joined #ruby
[19:14:10] allomov: has joined #ruby
[19:14:33] sarkyniin: has joined #ruby
[19:15:46] charliesome: has joined #ruby
[19:18:01] s00pcan: has joined #ruby
[19:19:10] cbz: has joined #ruby
[19:21:39] Yiota: has joined #ruby
[19:22:03] IceyEC: has joined #ruby
[19:24:41] joast: has joined #ruby
[19:25:05] freerobby: has joined #ruby
[19:27:46] nobitanobi: has joined #ruby
[19:30:40] jottr: has joined #ruby
[19:34:31] freerobby: has joined #ruby
[19:34:52] unclouded: has joined #ruby
[19:36:45] gjvc: has joined #ruby
[19:40:22] hahuang65: has joined #ruby
[19:41:24] gjvc: has joined #ruby
[19:43:03] cbz: has joined #ruby
[19:43:03] cbz: has joined #ruby
[19:43:19] decaff: has joined #ruby
[19:43:25] mistermocha: has joined #ruby
[19:43:34] chinmay_dd: has joined #ruby
[19:44:49] nofxx: has joined #ruby
[19:45:05] Vile`: has joined #ruby
[19:48:39] yqt: has joined #ruby
[19:50:33] lessless: has joined #ruby
[19:51:12] eggoez: has joined #ruby
[19:52:33] shevy: so quiet today
[19:52:44] roolo_: has joined #ruby
[19:52:55] IceyEC: has joined #ruby
[19:53:33] yorickpeterse: that's because it' Caturday
[19:56:50] railswebdev: has joined #ruby
[20:00:48] zick: has joined #ruby
[20:01:19] apeiros: dat typo: Slime::Engine
[20:03:16] apeiros: is it just me or are Slim's API docs terrible?
[20:03:19] Vile`: has joined #ruby
[20:03:22] apeiros: can't find an entry point
[20:04:16] yorickpeterse: Never used it, we still use HAML everywhere
[20:04:17] ellisTAA: has joined #ruby
[20:04:54] cytoskeletor: has joined #ruby
[20:05:23] apeiros: haml api docs were quite good iirc
[20:05:45] apeiros: at least it took me only a couple of minutes to go from "I have some haml markup" to "I have code which translates that to html"
[20:06:03] apeiros: with slim, all I have after 10min of looking around is a puzzled look on my face???
[20:06:33] busterarm: i'm still perfectly happy with ERB
[20:06:45] busterarm: ACTION wnats to be a pariah
[20:06:49] busterarm: you can write ugly code in any language
[20:07:30] juanpablo_: has joined #ruby
[20:07:31] shevy: php embedded into html was uglier
[20:07:36] shevy: and inter-wrapped with XML
[20:07:39] icebourg: has joined #ruby
[20:07:49] busterarm: I've never been in the meaningful whitespace camp
[20:08:10] michael_mbp: has joined #ruby
[20:08:38] bluOxigen: has joined #ruby
[20:09:24] busterarm: I mostly avoid the tag helpers when writing ERB anyway - sure it's more verbose but they get out of hand
[20:09:39] yorickpeterse: whitespace is poetry
[20:09:40] busterarm: closer I am to plain markup the better
[20:09:40] Ilyas: has joined #ruby
[20:09:55] yorickpeterse: when I look at whitespace it's as if angels are singing to me
[20:10:02] yorickpeterse: ACTION sounds like a hippie
[20:10:09] chipotle: has joined #ruby
[20:10:11] jhass: apeiros: how about going through tilt?
[20:10:35] hahuang65: has joined #ruby
[20:10:38] busterarm: though if I had to change, I'd definitely use Slim
[20:10:58] apeiros: jhass: seeing how slim-rails registers Slim::Template, which has no code but inherits from Tilt::Template, I was just pondering that???
[20:13:46] NeverDie: has joined #ruby
[20:13:48] FernandoBasso: has joined #ruby
[20:14:09] Ox0dea: has joined #ruby
[20:14:16] Ox0dea: busterarm: How do you write ugly code in Whitespace?
[20:14:52] omegamike: has joined #ruby
[20:15:38] busterarm: Ox0dea: two separate ideas. I'm saying haml can be written to be really ugly (as ugly as erb or worse), and I'm generally not a fan of meaningful (enforced) whitespace
[20:15:50] Ox0dea: busterarm: Whitespace is a programming language.
[20:16:14] Jarboe: has joined #ruby
[20:17:13] craysiii: the ugliness is hiding in plain sight. ctrl-A unleashes the beast
[20:17:17] busterarm: I mean, I'll write idiomatic code in whatever
[20:18:04] Ox0dea: busterarm: I was rather obviously being facetious, but I do maintain that you'd have trouble clarifying why exactly you felt a given Whitespace program was "ugly".
[20:18:04] linuxboytoo: has joined #ruby
[20:18:08] Vile`: has joined #ruby
[20:18:46] apeiros: jhass: yeah, going through tilt worked.
[20:19:09] apeiros: ponder whether I should open an issue on slim-language repo, asking to add docs for how to start using slim as an engine in your own project
[20:19:14] busterarm: that esoteric language wasn't on my radar
[20:19:25] Ox0dea: You're one of today's ten thousand. :)
[20:19:53] v0n: has joined #ruby
[20:23:57] Yiota: has joined #ruby
[20:25:02] busterarm: don't know the reference
[20:25:07] radgeRayden: has joined #ruby
[20:26:54] Rubie: has joined #ruby
[20:27:31] Ox0dea: !xkcd 1053
[20:27:46] apeiros: that'd be a nice command
[20:27:57] Ox0dea: Am I allowed to have a bot in?
[20:28:29] workmad3: has joined #ruby
[20:28:38] apeiros: rule for bot is simple: only speak when being addressed. otherwise same as any natural person. no public logging without permission (last one is a freenode rule)
[20:29:26] Ox0dea: Seems plenty reasonable, but ruboto speaks without being explicitly addressed.
[20:29:29] busterarm: i might write a bot
[20:29:37] jhass: ruboto also has ops
[20:29:47] craysiii: what is the scope of public logging? can i not log the channel?
[20:29:51] apeiros: Ox0dea: sure. ruboto is the official channel bot and got permission :)
[20:29:56] schmooster: Whitespace is great
[20:29:57] Ox0dea: Right, makes sense.
[20:30:02] apeiros: craysiii: you may not publish your logs
[20:30:04] jhass: craysiii: you can. You cannot make the logs available to a third party
[20:30:04] Ox0dea: schmooster: The language?
[20:30:17] postmodern: has joined #ruby
[20:30:24] schmooster: you may like to look at the list of esoteric languages on rosettacode
[20:30:28] jhass: craysiii: only the official public log mentioned in the topic is allowed to do that
[20:31:15] busterarm: Dogescript is still my favorite
[20:31:20] craysiii: interesting.
[20:31:52] busterarm: https://esolangs.org/wiki/Language_list
[20:31:55] schmooster: which I can't find now.. ohwait http://rosettacode.org/wiki/Category:Esoteric_Languages
[20:32:21] schmooster: just keep those two words in your search terms :D
[20:32:45] schmooster: I take it you've seen LOLCODE and BF nad the like?
[20:32:48] busterarm: i wish they had a version of the list sorted by number of instructions
[20:33:00] busterarm: yeah, have even written some bf
[20:33:14] schmooster: https://en.wikipedia.org/wiki/Esoteric_programming_language
[20:33:21] schmooster: the wikipedia page is much better tbf
[20:33:24] Igorshp: has joined #ruby
[20:33:38] schmooster: you want least or most instructions?
[20:33:56] fullofca_: has joined #ruby
[20:33:57] Ox0dea: http://esolangs.org/wiki/Main_Page
[20:34:07] Ox0dea: That's the preeminent source for all things esolang.
[20:34:27] busterarm: https://github.com/xoreaxeaxeax/movfuscator
[20:34:33] busterarm: big fan of this thing right 'ere
[20:34:36] Ox0dea: busterarm: "Sorted by number of instructions"?
[20:35:10] busterarm: well, like bf has 8 commands, etc
[20:35:14] busterarm: some have less, many more
[20:35:30] Ox0dea: Ah, gotcha.
[20:35:38] schmooster: you want to run on an OISC
[20:35:41] Ox0dea: Well, mov is Turing-complete, so one is the minimum. :)
[20:36:25] schmooster: I don't know where I picked it up from
[20:36:32] schmooster: but I've been saying that a lot recently
[20:37:18] schmooster: are you up to speed on Flynn's taxonomy?
[20:37:42] sinkensabe: has joined #ruby
[20:37:44] busterarm: empty nest (()) is another fun one
[20:37:46] schmooster: https://en.wikipedia.org/wiki/Flynn%27s_taxonomy
[20:37:53] amclain: has joined #ruby
[20:38:07] busterarm: schmooster: I'm not, no
[20:38:16] devdazed: has joined #ruby
[20:38:18] busterarm: i'm familiar with SIMD
[20:38:20] Ox0dea: busterarm: I'm fairy certain Sclipting (http://esolangs.org/wiki/Sclipting) has the greatest number of distinct instructions.
[20:38:42] schmooster: outside mathematics?
[20:38:50] Ox0dea: > The basic idea is that to minimise the number of characters in a program, the language should provide as many single-character instructions as possible.
[20:38:54] craysiii: what. the. heck
[20:39:00] Ox0dea: Yay, Unicode!
[20:39:14] schmooster: don't say unicode
[20:39:28] schmooster: there are reasons :)
[20:39:38] busterarm: omg i love that. chinese for for instructions and hangul for data....that'll really mess with people
[20:40:10] yorickpeterse: at least Hangul isn't that difficult
[20:40:16] busterarm: yeah, hangul is super easy
[20:40:19] schmooster: Ox0dea: thanks for that btw
[20:40:23] yorickpeterse: Writing it, sure
[20:40:28] yorickpeterse: understanding it? heh, lot harder
[20:40:31] busterarm: like, learn to write it in an afternoon
[20:40:38] christiandsg: has joined #ruby
[20:40:54] craysiii: i studied mandarin for 2 years, still wouldn't want to program with chinese :P
[20:41:08] yorickpeterse: Yeah but Mandarin is just....ugh
[20:41:23] Ox0dea: How do tonal languages even work, man?
[20:41:31] Ox0dea: Like, what are the mechanics of whispering?
[20:41:41] busterarm: you don't whisper
[20:41:41] yorickpeterse: "Hey peeps how do we make a language so complex even native speakers are bad at it?"
[20:41:54] craysiii: you do whisper, and there are still tonal differences, but less pronounced
[20:41:56] yorickpeterse: At least Hangul was well designed
[20:42:07] craysiii: then again a major part of the language is inference through context
[20:42:07] yorickpeterse: "Peasants are too dumb to learn Chinese, lets make it simpler"
[20:42:44] hahuang65: has joined #ruby
[20:42:47] busterarm: what I find most interesting is how the two Koreas have evolved two distinct languages in such a short time
[20:43:00] busterarm: and rapidly on the path to mutual unintelligibility
[20:43:05] craysiii: 50 years isn't so short
[20:43:13] busterarm: for language it is
[20:43:33] craysiii: true, but there are other factors at play
[20:43:46] yorickpeterse: busterarm: actually the two aren't that different
[20:43:48] Mendenhall: has joined #ruby
[20:43:57] nalley: has joined #ruby
[20:44:04] busterarm: but i guess you could say the Ryukyuuan languages will have died out in less than 100 years from their common usage, so
[20:44:29] Ox0dea: All I see are nine dragons.
[20:45:05] Yiota: has joined #ruby
[20:45:15] Ox0dea: Because "ryukyu"? No? Okay.
[20:45:38] craysiii: id say those two issues are unrelated linguistically speaking.
[20:46:09] Ox0dea: I think we should try to standardize on PIE.
[20:46:19] atomical: has joined #ruby
[20:46:36] yorickpeterse: apple pie > everything else
[20:46:52] busterarm: there should be a term for the time it takes for PIE to come up in all discussions of linguistics
[20:46:55] craysiii: "to make apple pie, first you must create the universe"
[20:46:57] tubulife-: has joined #ruby
[20:47:19] Ox0dea: busterarm: Of course, it says a lot about PIE that we really should have such a term.
[20:47:22] schmooster: cherry pie, come on
[20:47:29] craysiii: like godwin's law.
[20:47:31] schmooster: how can you put apple pie above cherry pie
[20:47:36] busterarm: kind of like how the games industry has a term for the time it takes for users to use creation tools to create in-game representations of dicks
[20:47:43] yorickpeterse: cherry pie is for peasants
[20:47:51] schmooster: shut up, this is war
[20:48:00] tkuchiki: has joined #ruby
[20:48:06] Hanmac: has joined #ruby
[20:48:08] schmooster: cherry pie is basically the ambrosia of the gods
[20:48:08] Yiota: has joined #ruby
[20:48:20] craysiii: ambrosia is meh
[20:48:31] yorickpeterse: would not consume again
[20:48:48] busterarm: I'm not much of a pie person, except for Pumpkin
[20:48:49] yorickpeterse: craysiii: what scale is, American?
[20:48:59] Ox0dea: yorickpeterse: Kinsey.
[20:49:01] busterarm: and maybe coconut cream
[20:49:07] craysiii: when scaling something i like to use prime numbers.
[20:49:24] schmooster: lemon meringue pie
[20:49:31] kirun: has joined #ruby
[20:49:33] busterarm: i hate meringue
[20:49:38] schmooster: I think cheesecake counts as pie also
[20:49:42] busterarm: i'd rather eat fondant
[20:49:50] schmooster: you're insane
[20:50:00] schmooster: go eat a block of marzipan
[20:50:07] busterarm: i like marzipan
[20:50:09] Trynemjoel: has joined #ruby
[20:50:11] schmooster: agh you would
[20:50:24] busterarm: marzipan is great
[20:50:26] schmooster: ok you can be my rival for now
[20:50:31] busterarm: it's no nougat though
[20:50:38] schmooster: nougat is awesome
[20:50:39] craysiii: nougat is great
[20:50:54] craysiii: is this something everyone agrees on?
[20:50:59] yorickpeterse: what's nougat?
[20:51:01] busterarm: no, i know people who hate nougat
[20:51:10] busterarm: as much as I hate meringue
[20:51:29] schmooster: busterarm: everything you say was going to be wrong in my ears, from now on, if you actually also hated nougat
[20:51:37] schmooster: you're a lucky being
[20:51:47] busterarm: we're totally offtopic btw
[20:51:49] apt-get_: has joined #ruby
[20:52:03] yorickpeterse: The police isn't here anyway
[20:52:03] schmooster: I am good at encouraging derailment
[20:52:15] schmooster: we are in #ruby right?
[20:52:26] schmooster: ah nevermind
[20:52:27] yorickpeterse: lets get back on track
[20:52:49] schmooster: _much better_
[20:52:58] adaedra: yorickpeterse | what's nougat?
[20:53:01] adaedra: HOW DARE YOU
[20:53:10] craysiii: i think what people are missing here. is cake > pie
[20:53:16] yorickpeterse: I've literally never heard of that word
[20:53:37] schmooster: it's a type of sticky chewy delicious sweet thing
[20:53:42] schmooster: which is not alive
[20:53:45] yorickpeterse: Ah, we call it noga
[20:53:53] craysiii: it which language?
[20:54:02] yorickpeterse: I don't like this stuff
[20:54:04] yorickpeterse: craysiii: Dutch
[20:54:15] craysiii: do you use the hard g or soft g though
[20:54:16] yorickpeterse: the language of the gods
[20:54:19] busterarm: yes cake > pie
[20:54:22] yorickpeterse: craysiii: medium
[20:54:33] elia: has joined #ruby
[20:54:44] craysiii: ik leer een beetje het nederlands :P
[20:54:45] yorickpeterse: soft g is for the peasants from the south
[20:54:57] yorickpeterse: craysiii: drop the "the"
[20:55:07] Maletor: has joined #ruby
[20:55:13] craysiii: meh. lol no formal lessons
[20:55:16] yorickpeterse: also enjoy pronouncing roggenbrood and grachtengordel
[20:55:46] yorickpeterse: and the fact that zij/zei have multiple meanings/genders depending on the context
[20:55:53] craysiii: i have enough trouble with hagelslag
[20:56:01] yorickpeterse: zij zei dat zij weg zouden gaan
[20:56:09] yorickpeterse: ^ "she said they would leave"
[20:56:15] busterarm: maybe I should learn Dutch -- I've got nearly daily exposure to it this year completely unintentionally
[20:56:23] texasmade: has joined #ruby
[20:56:29] yorickpeterse: busterarm: how so?
[20:56:29] lkba_: has joined #ruby
[20:56:31] craysiii: its a fun language.
[20:56:35] busterarm: people around me
[20:56:42] busterarm: + the internet
[20:56:46] craysiii: a lot easier to learn if you've had exposure to german
[20:56:48] busterarm: lot of Dutch programmers here in NY
[20:56:54] yorickpeterse: Ah yes, those traitors
[20:56:57] busterarm: and I've learned a little German
[20:57:05] craysiii: i want to move to the netherlands >.>
[20:57:11] yorickpeterse: hold on, I have the best image that symbolizes our country
[20:57:25] busterarm: and there's no reason an English speaker can't pick up German
[20:57:25] schmooster: not all cakes are greater than all pie, though
[20:57:36] yorickpeterse: https://b.thumbs.redditmedia.com/NQLBGyTUCtWHVwsLePQFOhkVjh90IKrCk2WHwk3QaXk.png
[20:57:39] yorickpeterse: beholdm our king
[20:57:51] shevy: now I am blind thank you yorickpeterse
[20:57:53] craysiii: koning willem
[20:57:54] yorickpeterse: it's from /r/cirletrek
[20:57:56] busterarm: I keep seeing all kinds of offers for programmers in Amsterdam but they pay is way lower
[20:58:00] schmooster: maybe on average, yes, but not all when individually cross-compared against all others in the opposing set
[20:58:05] yorickpeterse: busterarm: whatever you do, don't work for Booking.com
[20:58:11] craysiii: yorick why lol
[20:58:13] busterarm: yorickpeterse: I've heard
[20:58:14] craysiii: i hear so much about booking
[20:58:23] Ox0dea: yorickpeterse: Does "Cirkeltrek" mean what I think it does?
[20:58:33] schmooster: yorickpeterse: I know a few out at booking
[20:58:54] yorickpeterse: Booking is a modern day example of a company still using slavery
[20:58:56] craysiii: i was thinking of applying there once i finished my full stack ruby course.
[20:59:08] busterarm: (actually I love Perl)
[20:59:32] yorickpeterse: http://blogs.perl.org/users/bookingemployee/2012/03/truth-about-bookingcom.html http://blogs.perl.org/users/booking_employee/2014/01/bookingcom---a-toxic-company-for-developers.html
[20:59:44] yorickpeterse: I also know a few people that have worked there
[20:59:48] yorickpeterse: Good pay, shit treatment
[20:59:51] blackmesa: has joined #ruby
[20:59:59] busterarm: anyway, I'm learning Danish and am trying to get to CPH somehow
[21:00:13] busterarm: not really looking to detour from that
[21:00:40] yorickpeterse: it's like talking Swedish but with a potato in your mouth
[21:00:43] busterarm: the language that people learn to speak last
[21:01:04] yorickpeterse: I tried to learn Korean but gave up
[21:01:12] busterarm: everyone complains about the pronunciation but I found Icelandic way harder
[21:01:14] yorickpeterse: Doesn't really work if all your Korean speaking friends actually only live in Korea
[21:01:16] craysiii: yorick would you have any suggestions for a junior dev (as far as companies) trying to emigrate to NL from US?
[21:01:19] yorickpeterse: and work from 9 to 9
[21:01:38] yorickpeterse: craysiii: junior as in?
[21:02:11] busterarm: get a job at Booking, tbh
[21:02:14] busterarm: they'll sponser
[21:02:15] craysiii: junior ruby / rails rev.
[21:02:16] busterarm: err sponsor
[21:02:22] busterarm: then gtfo as fast as possible
[21:02:23] yorickpeterse: and your visa will be tied in to your employment
[21:02:27] yorickpeterse: so you'll be kicked out if you leave
[21:02:43] busterarm: i thought you could get an offer from another employer and then transfer it
[21:02:46] yorickpeterse: It's really not needed for US citizens, there are a bunch of treaties that make it fairly easy for US citizens to work here
[21:03:04] yorickpeterse: busterarm: Yes, but IIRC there's a chance you still have to leave the country for a while
[21:03:14] busterarm: oh you do, for sure
[21:03:16] craysiii: that treaty is only to start or invest in a business though, as i understand it.
[21:03:18] yorickpeterse: craysiii: I meant that as in years and such
[21:03:31] busterarm: they have to process it with you outside
[21:04:01] hahuang65: has joined #ruby
[21:04:10] craysiii: 2-3 years experience. I am thinking in the future.
[21:04:36] tjohnson: has joined #ruby
[21:04:37] busterarm: do you have at least a bachelor's?
[21:05:27] yorickpeterse: It's not needed either
[21:05:42] busterarm: maybe for NL
[21:05:48] craysiii: it would look better though. i just decided traditional schooling wasn't for me.
[21:05:52] busterarm: i left school to work in finance because $$$
[21:05:55] craysiii: thats why im doing fullstack course at bloc.io
[21:06:05] busterarm: OH, say hi to Chris Beck for me!
[21:06:34] busterarm: but anyway, i looked for any reasonable route into the EU and basically gave up
[21:06:37] craysiii: before that I was studying CS but stopped because i couldn't be bothered with anything that wasn't CS.
[21:06:43] shpoont: has joined #ruby
[21:06:48] busterarm: even with 10+ years sysadmin experience
[21:07:08] busterarm: it's way way easier with your degree and almost a cinch with a Master's
[21:07:10] craysiii: buster you are in the US as well?
[21:07:18] blackmesa: has joined #ruby
[21:07:21] yorickpeterse: Literally all you need is a company willing to invest in a visa
[21:07:23] busterarm: who's your mentor at Bloc?
[21:07:33] craysiii: my mentor is Jess Rodriguez
[21:07:36] craysiii: really cool guy
[21:07:42] yorickpeterse: There are some programs like "knowledge migrants" to make it easier to important skilled foreigners, but the systems are all a bit fuzzy and require certain things from the employer
[21:07:43] busterarm: yorickpeterse: yeah, I just found lot of companies are CV focused and care a lot about school
[21:08:07] busterarm: less so for Germany, Netherlands and Ireland...but all the places I wanted to go very degree-oriented...points systems and all that
[21:08:46] busterarm: once I get in a couple more years in dev I'm going to try for somewhere though
[21:09:00] busterarm: seems much more likely to get a company to sponsor
[21:09:46] craysiii: im going to do the same. girlfriend and I want to raise family in the netherlands, id be willing to go somewhere else in the EU though until i can gain permanent residency
[21:10:08] busterarm: what's Bloc like these days? I only know from when they started and their curriculum and programs are a lot different now
[21:10:37] mary5030: has joined #ruby
[21:10:38] yorickpeterse: craysiii: have you ever been to .nl before?
[21:10:56] craysiii: yes for a month. girlfriend lived their for a year while she did her master at UvL
[21:11:09] troulouliou_dev: has joined #ruby
[21:11:12] roolo: has joined #ruby
[21:11:31] yorickpeterse: If you apply for the big companies (e.g. ING, though that means also Java) you'll basically get a visa and everything for free
[21:11:33] busterarm: well, if at some point she became your spouse, it would be a lot easier...but not trying to push you into that
[21:11:35] yorickpeterse: The startups are too poor for that
[21:11:39] yorickpeterse: and your salary will suck
[21:11:50] yorickpeterse: busterarm: neg, only if she has a Dutch permit
[21:11:52] busterarm: she could very easily get a job and bring you along, depending on what she does
[21:12:07] craysiii: she is not a dutch national. though her father was and immigrated to the US from NL in the 60's.
[21:12:21] busterarm: yorickpeterse: I was thinking the more generally in the EU than there specifically
[21:12:53] craysiii: I would be okay with less money for a higher quality of life
[21:14:18] cbz: has joined #ruby
[21:14:32] yorickpeterse: I know a bunch of companies in town, but I doubt any have the money to pay for a visa
[21:14:52] yorickpeterse: Though https://www.publitas.com/ might have it since they're doing fairly well financially
[21:14:56] yorickpeterse: (they're a Rails shop)
[21:15:16] yorickpeterse: There's also https://www.zilverline.com/
[21:16:34] ChanServ: -bb r33th4x0r!*@* *!*@host22.137.druknet.bt
[21:17:10] Maletor: has joined #ruby
[21:17:29] s00pcan: has joined #ruby
[21:17:30] yorickpeterse: and http://www.supersaas.com/info/jobs
[21:17:33] charliesome_: has joined #ruby
[21:17:53] craysiii: many thanks
[21:18:04] yorickpeterse: http://www.youngcapital.nl/ is also looking for people (they tried to buy me at some point)
[21:18:51] jhk: has joined #ruby
[21:18:54] yorickpeterse: Word of advice, a lot of companies will list something like "Minimaal HBO ...." which is basically "minimum a bachelor degree"
[21:19:00] yorickpeterse: but few will actually care
[21:19:22] yorickpeterse: https://www.true.nl/over-true/vacatures/ also looking for people
[21:19:23] craysiii: okay thats good. we have a lot of that in the US as well, but where i am it doesn't apply as much (silicon valley)
[21:19:41] yorickpeterse: http://amsrb.org/jobs/ basically everything on this list
[21:19:54] yqt: has joined #ruby
[21:19:59] yorickpeterse: If you have the skills the lack of a degree is easily dealt with
[21:20:05] jhk: has left #ruby: ()
[21:20:27] yorickpeterse: I don't have a degree either and I've been rolling along just fine for little over 5 years now
[21:20:38] craysiii: thats good to hear
[21:21:30] yorickpeterse: In fact, my first programming job started June 14, 2010
[21:21:43] yorickpeterse: and I earned a whopping 1050 Euros per month
[21:21:56] craysiii: thats a bit low.
[21:22:05] Scriptonaut: I've worked with a lot of programmers that never went to school
[21:22:05] yorickpeterse: Granted I was 17
[21:22:24] yorickpeterse: I think around the time I quit I earned a massive 1500 per month
[21:22:28] craysiii: that makes sense lol. i make that much pulling CAT6 and fiber cable
[21:22:29] Scriptonaut: the guy I'm working with right now was on the hash rocket team, Veezus Kreist, somewhat famous in the ruby community, and he told me he didn't go to school
[21:22:44] hahuang65: has joined #ruby
[21:22:44] busterarm: isn't it super hard to get an apartment in Amsterdam?
[21:22:46] Scriptonaut: I think we pay him almost $200 an hour
[21:22:53] craysiii: i went to school i just didnt finish ;)
[21:22:53] yorickpeterse: busterarm: yes
[21:22:55] Scriptonaut: so if you're good, it's no big deal to make money
[21:23:02] busterarm: like, people camp out outside and stuff? lol
[21:23:09] yorickpeterse: But you can easily live just outside of Amsterdam and get in by train
[21:23:10] yorickpeterse: if they operate
[21:23:16] yorickpeterse: (so not during winter)
[21:23:41] yorickpeterse: Pricing in Amsterdam is crazy too
[21:23:50] craysiii: what about den haag
[21:23:56] yorickpeterse: That's where all the scum lives
[21:24:13] yorickpeterse: (that's only partially a joke, sadly)
[21:24:13] craysiii: i thought that was brabant :P
[21:24:21] yorickpeterse: No, that's our texas
[21:24:40] busterarm: so what's your Florida?
[21:24:47] workmad3: has joined #ruby
[21:24:51] yorickpeterse: well, we don't have any of the sun
[21:24:59] Scriptonaut: what about the old people?
[21:24:59] yorickpeterse: So I guess Noord Holland, though that's also California
[21:25:12] yorickpeterse: Amsterdam is basically San Fransisco
[21:25:20] yorickpeterse: all the old people live in the east of the country
[21:25:22] adaedra: I smell offtopic
[21:25:22] yorickpeterse: along with all the sheep
[21:25:36] Scriptonaut: really? I didn't get that vibe at all from Amsterdam
[21:25:51] yorickpeterse: Scriptonaut: the city might be different, but it's where all the startups are
[21:25:55] craysiii: eh. i would say more or less so it's like SF, being born and raised in SF and all lol
[21:26:04] Scriptonaut: ah, I've only visited a few times
[21:26:09] yorickpeterse: it even comes with hobos pissing on the streets
[21:26:17] Scriptonaut: ya, SF smells like piss
[21:26:22] Scriptonaut: like half the city
[21:26:28] craysiii: its really annoying
[21:26:28] Scriptonaut: and garbage everywhere
[21:26:49] craysiii: thats because other states literally paid to bus their mentally ill to california
[21:26:54] busterarm: what's up with the armed robberies in SF's financial district lately?
[21:26:59] rickmasta: has joined #ruby
[21:27:15] Yiota: has joined #ruby
[21:27:23] busterarm: like, 'broad daylight, shoot you in the face' kind of shit
[21:27:29] craysiii: increased crime everywhere right now
[21:27:34] Scriptonaut: We have plenty up homeless up here near Seattle
[21:27:36] yorickpeterse: The one advice I have for those moving to .nl: be prepared to deal with the Dutch
[21:27:40] craysiii: summer brings out the crazy in the gang bangers and hard ons
[21:27:42] yorickpeterse: as in, we don't beat around the bush
[21:27:51] craysiii: yorick yes ive learned that one
[21:28:11] craysiii: very direct. which actually isnt a bother for me, i'm the same way myself most of the time.
[21:28:17] Rubie: has joined #ruby
[21:28:23] busterarm: you say that, and I believe you, but all of the Dutch folks I know are super positive people
[21:28:27] busterarm: just direct
[21:28:30] blackmesa: has joined #ruby
[21:28:36] yorickpeterse: It has little to do with negativity
[21:28:46] Scriptonaut: general bluntness
[21:28:50] busterarm: no but I mean unusual amounts of positivity
[21:28:54] yorickpeterse: It's more about "Does this dress fit me?" "No you look fat in it"
[21:29:17] yorickpeterse: also our food culture sucks
[21:29:21] Scriptonaut: I greeted someone in the netherlands, "How're you doing", and they spent like 10 minutes explaining how they're day wasn't going that well
[21:29:23] yorickpeterse: as in, it barely exists
[21:29:28] Scriptonaut: they took it literally
[21:29:29] yorickpeterse: Scriptonaut: hahaha
[21:29:36] craysiii: thats true yorick. but you had a place i really likes called jackets
[21:29:40] yorickpeterse: It's very uncommon to ask somebody that here
[21:29:42] craysiii: stuffed baked potato :P
[21:29:43] yorickpeterse: unless you're actually interested
[21:29:45] busterarm: Most of western europe's food culture sucks
[21:29:53] busterarm: or sucked until recently
[21:30:01] yorickpeterse: Belgium at least has decent beer
[21:30:07] Scriptonaut: agreed on the food culture, it's like mashed potatoes mixed with greens and sausage 50% of the time
[21:30:10] busterarm: France is a huge outlier
[21:30:14] craysiii: kriekbeer is life
[21:30:23] Scriptonaut: that's the sour beer isn't it?
[21:30:38] craysiii: no its cherry beer
[21:30:54] craysiii: delicious AF
[21:30:59] busterarm: New Nordic quisine is money though
[21:31:36] Scriptonaut: only kriek I had was a lambic ale, too damn sour for me
[21:31:42] Scriptonaut: tasted like vinegar a bit
[21:31:48] craysiii: damn. bad first impression
[21:32:05] Scriptonaut: will have to try agian, we have a great beer culture up here
[21:32:14] busterarm: anyone who has any complaint about beer should drink Icelandic beer
[21:32:15] craysiii: where are you around?
[21:32:17] shevy: beer brings people together
[21:32:20] Scriptonaut: western WA state
[21:32:27] busterarm: makes all other beers seem amazing in comparison
[21:32:30] Scriptonaut: we have the most breweries per capita last I checked
[21:32:31] craysiii: thats what i was thinking lol.
[21:32:37] yorickpeterse: busterarm: are you sure you didn't drink whale pee instead?
[21:32:40] Scriptonaut: Oregon might have us beat now
[21:32:53] yorickpeterse: did you ever drink whale pee before?
[21:33:15] busterarm: It's that stuff they sell in a bottle and call Beer there, right?
[21:33:17] hahuang65: has joined #ruby
[21:33:25] Scriptonaut: sounds like bud light
[21:33:34] Scriptonaut: we call that wolf piss here
[21:33:40] busterarm: this is waaaaaaaaaaaaay worse than bud light
[21:34:00] craysiii: can i ask what is with europeans and loving black licorice.
[21:34:14] Scriptonaut: I love that salmiak stuff from Finland
[21:34:15] busterarm: whatever you think the worst beer is...Keystone, Beast, Schaefer, Nattybo.....Icelandic beer is like 100x worse than that
[21:34:21] busterarm: Salkmiakkikossu is amazing
[21:34:27] busterarm: love that stuff
[21:34:32] busterarm: err Salmiakkikossu
[21:34:56] busterarm: Iceland has one decent beer (Gull) and it's like their Bud Light
[21:35:24] ruboto: this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
[21:35:56] Scriptonaut: well I mean until somebody has a real question
[21:36:05] Scriptonaut: which luckily I do
[21:36:48] Scriptonaut: https://gist.github.com/robins35/e961a8237b7fa158859d
[21:37:05] Scriptonaut: I'm getting NameError: undefined local variable or method `attr_accessible' for User(id: integer, name: string):Class
[21:37:17] yorickpeterse: Rails 4 doesn't have it anymore IIRC
[21:37:21] cornerma1: has joined #ruby
[21:37:21] jhass: yap, that's gone in 4
[21:37:23] ruboto: Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[21:37:26] Scriptonaut: no this isn't rails
[21:37:33] busterarm: it's all about strong_params now
[21:37:34] Scriptonaut: I'm not using rails
[21:37:36] yorickpeterse: Scriptonaut: attr_accessible is part of Rails
[21:37:40] jhass: Rails is a collection of integrated libraries, of which you use two
[21:37:42] yorickpeterse: it's not available outside of it iIRC
[21:37:47] jhass: well almost 3
[21:37:49] yorickpeterse: It's certainly not part of AR
[21:38:40] zenspider: Scriptonaut: ActiveRecord is part of rails... so AR-only questions should be directed there too.
[21:38:42] Scriptonaut: awesome, I don't even need to use it
[21:38:59] zenspider: in this case, seems a moot point tho.
[21:39:11] Papierkorb: has joined #ruby
[21:39:16] Scriptonaut: I usually hangout in #rubyonrails because I'm primarily a rails dev, but when I ask questions in there for this ruby project they refer me to here
[21:40:05] zenspider: I think in this case, you probably don't want anything. you'll get the methods you need from the schema
[21:41:21] lannonbr: has joined #ruby
[21:41:34] leafybasil: has joined #ruby
[21:46:23] [H]unt3r: has joined #ruby
[21:46:48] RegulationD: has joined #ruby
[21:47:38] blackmes1: has joined #ruby
[21:47:43] CorySimmons: has joined #ruby
[21:47:44] mistermocha: has joined #ruby
[21:48:30] CorySimmons: has joined #ruby
[21:49:26] cbz: has joined #ruby
[21:49:26] cbz: has joined #ruby
[21:50:47] CorySimmons: has joined #ruby
[21:52:22] swgillespie: has joined #ruby
[21:52:38] SupportMrHogan: has joined #ruby
[21:52:53] hahuang65: has joined #ruby
[21:54:36] swgillespie: has joined #ruby
[21:54:43] Trynemjoel: has joined #ruby
[21:57:39] michael_mbp: has joined #ruby
[21:57:39] markholmes: has joined #ruby
[21:57:57] railswebdev: has joined #ruby
[21:58:11] yfeldblum: has joined #ruby
[22:01:23] decoponio: has joined #ruby
[22:01:37] freerobby: has joined #ruby
[22:02:04] towski_: has joined #ruby
[22:03:24] glennt: has joined #ruby
[22:03:27] svdb64: has joined #ruby
[22:04:35] omegamike: has joined #ruby
[22:05:29] segy: has joined #ruby
[22:09:46] hahuang65: has joined #ruby
[22:11:46] despai: has joined #ruby
[22:11:49] Limix: has joined #ruby
[22:15:34] gheegh: has joined #ruby
[22:18:54] shpoont: has joined #ruby
[22:21:09] jottr: has joined #ruby
[22:21:50] perturbation: has joined #ruby
[22:23:42] Cache_Money: has joined #ruby
[22:24:07] psye: has joined #ruby
[22:24:53] lkba: has joined #ruby
[22:24:56] psye: has joined #ruby
[22:27:12] Thomas-0725: has joined #ruby
[22:27:34] chuy: has joined #ruby
[22:28:45] Rubie: has joined #ruby
[22:29:04] hj2007: has joined #ruby
[22:29:17] JeramyRR: has joined #ruby
[22:29:45] tejasmanohar: has joined #ruby
[22:30:17] ellisTAA: has joined #ruby
[22:31:47] zenspider: man I love StringScanner
[22:32:43] Ox0dea: ACTION ensures he's not in #java.
[22:32:48] kresk: has joined #ruby
[22:33:15] Trynemjoel: has joined #ruby
[22:35:07] tubulife-: has joined #ruby
[22:35:40] blackmes1: has joined #ruby
[22:36:02] Ox0dea: > EOF = :eof_haha!
[22:41:48] hahuang65: has joined #ruby
[22:42:12] charliesome: has joined #ruby
[22:42:57] diegoviola: has joined #ruby
[22:44:30] kresk: has left #ruby: ("Leaving")
[22:45:02] JeramyRR: has joined #ruby
[22:46:53] jottr: has joined #ruby
[22:48:07] shock_one: has joined #ruby
[22:50:21] mistermocha: has joined #ruby
[22:50:27] baweaver: has joined #ruby
[22:50:58] mary5030: has joined #ruby
[22:55:49] arooni-mobile: has joined #ruby
[22:56:56] hahuang65: has joined #ruby
[22:59:02] DukeDave: has joined #ruby
[22:59:27] bmcginty: Is there any single http client in ruby that does cookies, digest auth, and keep-alive?
[22:59:35] fullofcaffeine: has joined #ruby
[22:59:49] svdb64: has joined #ruby
[23:00:03] apeiros: bmcginty: mechanize doesn't?
[23:00:11] svdb64: has joined #ruby
[23:02:13] bmcginty: apeiros: I'm somewhat new to ruby. Let me take a look. Figured mechanize was more of a scrapign framework rather than just a client. (not scraping framework, but...more than a client...)
[23:03:04] apeiros: bmcginty: an http client isn't concerned about cookies. to it, it's just a header.
[23:03:15] apeiros: so what you want is technically already more than just an http client.
[23:03:31] apeiros: (or at least what I'd understand to be an http client)
[23:03:55] mroth: has joined #ruby
[23:04:03] busterarm: rest-client doesn't do those?
[23:04:05] apeiros: (and assuming by "do cookies" you mean "cookie management" - because every http client lib can send and receive headers???)
[23:04:09] busterarm: i think it does
[23:04:10] bmcginty: apeiros: That...makes more sence than I'd like to admit. Thanks.
[23:05:22] bmcginty: apeiros: right, managing cookies. I'm coming from a python background, and one of those "magic" packages python has is a client that does the above.
[23:06:48] shock_one: has joined #ruby
[23:08:51] charliesome: has joined #ruby
[23:09:01] ckrailo: has joined #ruby
[23:09:42] hahuang65: has joined #ruby
[23:09:50] troulouliou_dev: has joined #ruby
[23:10:32] shock_one: has joined #ruby
[23:11:24] akahn: has joined #ruby
[23:12:18] _blizzy_: has joined #ruby
[23:13:52] bruno-: has joined #ruby
[23:14:07] omegamike: has joined #ruby
[23:14:17] bmurt: has joined #ruby
[23:17:19] workmad3: has joined #ruby
[23:19:20] bruno-: has joined #ruby
[23:19:50] ledestin: has joined #ruby
[23:20:09] _blizzy_: has joined #ruby
[23:21:59] dimasg: has joined #ruby
[23:22:47] alfajor: has joined #ruby
[23:23:19] jottr: has joined #ruby
[23:24:45] bruno-: has joined #ruby
[23:26:22] willywos: has joined #ruby
[23:32:11] baweaver: has joined #ruby
[23:33:26] crazydiamond: has joined #ruby
[23:35:03] bruno-: has joined #ruby
[23:35:48] hahuang65: has joined #ruby
[23:37:23] blackmes1: has joined #ruby
[23:37:50] bato: has joined #ruby
[23:40:19] bato: heya, i'm trying to add files to a tar archive using tarwriter but I keep getting a " Gem::Package::NonSeekableIO" error while trying to add my file
[23:40:39] bato: not quite sure what i'm doing wrong at this point
[23:41:16] bato: http://pastebin.com/8bcLqgNM
[23:41:17] ruboto: bato, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/20c8466dff3fc40f4b4f
[23:41:17] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[23:41:36] shock_one: has joined #ruby
[23:41:56] bato: my bad ^^;
[23:42:48] zenspider: please show the error
[23:43:28] bato: /usr/lib/ruby/1.9.1/rubygems/package/tar_writer.rb:106:in `add_file': Gem::Package::NonSeekableIO (Gem::Package::NonSeekableIO) from logs_tgz.rb:12:in `block (3 levels) in <main>'
[23:45:04] juanpablo_: has joined #ruby
[23:45:10] michael_mbp: has joined #ruby
[23:45:38] troulouliou_dev: has joined #ruby
[23:46:31] sharpmachine: has joined #ruby
[23:47:12] malcolmva: has joined #ruby
[23:47:31] zenspider: bato: based on the code, it looks like your gzipwriter doesn't accept pos=, so tarwriter blows up
[23:48:07] decaff: has joined #ruby
[23:48:22] zenspider: this code looks sketchy
[23:48:25] dimasg: has joined #ruby
[23:49:19] DanFredriksen: has joined #ruby
[23:49:48] bato: well, i'm trying to figure out how to use tarwriter instead of just copying files and tarring them using system calls :/
[23:49:57] zenspider: bato: to experiment, remove the gzip writer
[23:50:24] DanFredriksen: would you recommend substituting php with ruby? I'm kind of tired of PHPs bad documentation and half-baked community.
[23:50:31] zenspider: well... you're using a class that is private to rubygems. you're using it in a way that they don't expect... hiccups happen
[23:50:50] zenspider: DanFredriksen: I don't think anyone here would advocate for ruby over php
[23:51:06] DanFredriksen: zenspider: is php better?
[23:51:32] DanFredriksen: you are kidding right
[23:51:40] zenspider: would I kid you?
[23:52:01] DanFredriksen: no, you seem to be an honest person. I trust you
[23:52:06] zenspider: also: asking such arbitrary and subjective questions in a channel dedicated to a specific technology is going to get you OBVIOUSLY biased answers.
[23:54:07] DanFredriksen: well, the community surely is different lol :3
[23:54:25] DanFredriksen: more mature people hanging in here than in ##php I guess. We'll see
[23:56:18] PhilK: has joined #ruby
[23:56:29] tejasmanohar: has joined #ruby
[23:57:34] Soda: has joined #ruby
[23:57:41] Limix: has joined #ruby
[23:58:35] arescorpio: has joined #ruby