« Back to channel list

#RubyOnRails - 02 October 2015

« Back 1 day Forward 1 day »
[00:00:14] herbst: has joined #RubyOnRails
[00:00:35] quazimodo: has joined #RubyOnRails
[00:01:46] _djbkd: has joined #RubyOnRails
[00:02:05] mices: i see a lot of (gems?) on github but no apps
[00:02:26] FailBit: search Gemfile
[00:02:55] FailBit: or config.ru
[00:03:00] Radar: config.ru?
[00:03:33] annlewis: has joined #RubyOnRails
[00:04:05] CanTonic: has joined #RubyOnRails
[00:05:53] ecksit: has joined #RubyOnRails
[00:06:22] atomical: has joined #RubyOnRails
[00:07:41] Jon30: has joined #RubyOnRails
[00:08:05] ecksit: has left #RubyOnRails: ()
[00:08:57] smathy: Radar, he meant search *for* those files, to find a rails app hosted on GH.
[00:09:27] Radar: mices: here's the app from Rails 4 in Action: https://github.com/rubysherpas/r4ia_examples/tree/master/ticketee
[00:14:23] jwaldrip__: has joined #RubyOnRails
[00:16:29] greengriminal: has joined #RubyOnRails
[00:16:33] baweaver: has joined #RubyOnRails
[00:17:19] jwaldrip___: has joined #RubyOnRails
[00:17:30] RockLee: has joined #RubyOnRails
[00:18:30] Lycanii: has joined #RubyOnRails
[00:19:09] a1fa: Radar: i got it working
[00:19:13] Radar: a1fa: good
[00:19:23] a1fa: Radar: i replaced is_a? (ActiveRecord::Base) to .any?
[00:19:31] tweeeaks: has left #RubyOnRails: ("Leaving")
[00:19:35] Radar: a1fa: I don't get why you need to do that call at all
[00:19:41] Radar: a1fa: You should remember to show the full context. Please consider that we don't know everything about your app.
[00:19:44] tweeeaks: has joined #RubyOnRails
[00:20:02] chipotle: has joined #RubyOnRails
[00:20:43] a1fa: Radar: the wrath of nil. i'm wrongly conditioning myself to always test for nil
[00:21:00] Radar: a1fa: then why not check .nil? instead of AR::Base?
[00:22:15] a1fa: good question i thought the later is proper
[00:22:25] rushed: a1fa: it doesn't even do that (guard against nils in the collection) since any? will return truthy as long as *everything* in there isn't nil~
[00:22:49] sdwrage: has joined #RubyOnRails
[00:23:28] lasker85: has joined #RubyOnRails
[00:23:49] rushed: a1fa: it's rarely proper in ruby to check a class type
[00:23:51] sdwrage: has joined #RubyOnRails
[00:23:54] loc22: has joined #RubyOnRails
[00:23:57] Radar: a1fa: full context for this code, please
[00:24:01] Radar: This'll be the last time I ask for it.
[00:26:25] a1fa: Radar: trying
[00:26:35] Radar: a1fa: copy + paste is not hard?
[00:26:36] apg: has joined #RubyOnRails
[00:26:41] a1fa: Radar: i'm using Remmina in ubuntu 14.10; copy and paste does not work
[00:26:56] Radar: push code to GitHub and copy + paste from there?
[00:26:59] a1fa: its pissing me off
[00:26:59] infocreativosweb: has joined #RubyOnRails
[00:27:20] a1fa: can't.. no access from the box to the internet, hence why i rdp into it
[00:27:29] Radar: Sounds like you've painted yourself into a corner.
[00:27:32] lasker85: has joined #RubyOnRails
[00:27:39] Ropeney: has joined #RubyOnRails
[00:28:05] a1fa: i will have to restart X to get copy & paste working i think
[00:28:09] a1fa: reconnecting didnt do the trick
[00:28:22] a1fa: or re-load a ppa
[00:28:28] j0sephandres: has joined #RubyOnRails
[00:28:29] rushed: a1fa: please tell us more~
[00:28:55] baweaver: rdp, going to windows route eh?
[00:29:09] baweaver: it's easier if you just learn how to use bash
[00:29:10] apg: has joined #RubyOnRails
[00:29:20] rushed: a1fa: maybe a blog post about your incredible dev setup
[00:29:37] baweaver: rushed: be nice
[00:29:57] rushed: baweaver: you're a little curious~
[00:30:00] a1fa: baweaver: worse
[00:30:27] a1fa: baweaver: rdp to windows, ssh to linux box from there, and vi ;)
[00:30:28] j0sephandres: i'm building an app, but I have a little doubt, in this gist I explain everything I appreciate your help https://gist.github.com/j0sephandres1987/8560399a9e9aa141ca60
[00:30:53] a1fa: do i win an award for most awkward setup?
[00:30:55] baweaver: why can't you get directly to the *nix box?
[00:31:20] a1fa: only the windows box can, two different routing domains
[00:31:34] rushed: a1fa: there is no award, you just win having everything you do be harder then it needs to be for no reason
[00:31:35] baweaver: You could just use Cygwin on the Windows box to make a bridge over ssh
[00:32:50] SteenJobs: has joined #RubyOnRails
[00:33:16] baweaver: or just make a hop box
[00:33:26] chills42: has joined #RubyOnRails
[00:33:55] j0sephandres: i'm building an app, but I have a little doubt, in this gist I explain everything I appreciate your help https://gist.github.com/j0sephandres1987/8560399a9e9aa141ca60
[00:34:30] allcentury: has joined #RubyOnRails
[00:36:50] j0sephandres: come guys help
[00:37:32] diego1: has joined #RubyOnRails
[00:37:34] diego1: has joined #RubyOnRails
[00:39:58] charliesome: has joined #RubyOnRails
[00:40:47] ramfjord: has joined #RubyOnRails
[00:41:04] rushed: j0sephandres: "edit_product view" ... ":action => "new"" <= ?
[00:41:54] ramfjord: I'm using active_record version 4.2.1 - is there any way to prevent ActiveRecord::Base.connection.inspect from returning like 300 lines?
[00:42:15] ramfjord: mosly type_map_initializer stuff
[00:42:17] bricker: ramfjord: why/what data are you interested in
[00:42:17] rushed: j0sephandres: also, if you don't want to build the blank items you might skim over http://railscasts.com/episodes/197-nested-model-form-part-2 taking a look at the link_to_add_fields
[00:42:57] rushed: ramfjord: if you don't call ActiveRecord::Base.connection.inspect it imagine it will return zero lines
[00:44:10] j0sephandres: rushed mmm...
[00:44:13] tawaffan: has joined #RubyOnRails
[00:47:25] apg: has joined #RubyOnRails
[00:47:26] apg: has joined #RubyOnRails
[00:47:36] _djbkd: has joined #RubyOnRails
[00:47:38] Lytol: has joined #RubyOnRails
[00:48:46] rushed: j0sephandres: mmm...
[00:50:17] greengriminal: has joined #RubyOnRails
[00:50:20] charliesome: has joined #RubyOnRails
[00:51:52] j_mcnally: has joined #RubyOnRails
[00:52:09] j_mcnally: quick question about postgres
[00:52:23] j_mcnally: how do i specify a table relation when i do a :references migration?
[00:52:32] j_mcnally: the colum is named requestor but the table is users
[00:52:38] j_mcnally: its looking for requestors
[00:53:33] rushed: j_mcnally: if the column already exists why are you creating a migration?
[00:53:53] j_mcnally: im trying to do this
[00:53:54] j_mcnally: t.references :requestor, index: true, foreign_key: true, references: "users"
[00:54:05] j_mcnally: but its still looking for a relation named requestors
[00:54:12] ramfjord: bricker: and rushed - I'm running commands in the console, and I have objects which have connections stored in them
[00:54:12] ramfjord: inspect automatically calls inspect on all member vars
[00:54:12] ramfjord: might be able to override that behavior
[00:54:12] ramfjord: and anything returned to the console is automatically inspected
[00:55:14] rushed: j_mcnally: you might consider just doing t.integer :requestor_id, ...(everything else you had)...
[00:55:40] havenwood: has joined #RubyOnRails
[00:56:03] nya: has joined #RubyOnRails
[00:56:12] j_mcnally: ahh it was a fk issue
[00:56:16] rushed: ramfjord: create ramfjords_awesome_helper that you can call from the console that digs out just what you're interested in and puts in?
[00:56:17] j_mcnally: i think i have it resolved
[00:57:16] lasker85: has joined #RubyOnRails
[00:58:11] j_mcnally: splitting the fk out and adding it manually seems to fix it
[00:59:45] sevenseacat: has joined #RubyOnRails
[01:01:19] ramfjord: has joined #RubyOnRails
[01:02:08] ktchup: has joined #RubyOnRails
[01:02:12] qejk: has joined #RubyOnRails
[01:02:15] ianm_: has joined #RubyOnRails
[01:05:05] maletor_: has joined #RubyOnRails
[01:05:28] ianm_: after a rails3 => rails4 upgrade, there's just one action that is odd, the log says "Processing by ReservationsController#schedule as JS" but then later it says "Rendered reservations/schedule.html.erb within layouts/application" (schedule.js.erb exists and was chosen properly in rails3). Adding "respond_to :html, :js" at the end of the action fixes it. Anyone know why this would be needed in rails4?
[01:09:44] ktchup: has joined #RubyOnRails
[01:09:58] Grundell: has joined #RubyOnRails
[01:13:41] rakm: has joined #RubyOnRails
[01:16:20] rclanan: has joined #RubyOnRails
[01:16:45] rclanan: has joined #RubyOnRails
[01:18:38] diegoviola: has joined #RubyOnRails
[01:21:00] diegoviola: has joined #RubyOnRails
[01:21:02] cih: has joined #RubyOnRails
[01:21:07] EminenceHC: has joined #RubyOnRails
[01:21:49] inoter: has joined #RubyOnRails
[01:22:42] apg: has joined #RubyOnRails
[01:24:52] apg: has joined #RubyOnRails
[01:27:04] j_mcnally: has joined #RubyOnRails
[01:32:28] iamjarvo: has joined #RubyOnRails
[01:36:06] lasker85: has joined #RubyOnRails
[01:36:52] bruno-: has joined #RubyOnRails
[01:36:53] cnk: has left #RubyOnRails: ()
[01:39:43] nya: has joined #RubyOnRails
[01:45:05] workmad3: has joined #RubyOnRails
[01:45:28] lasker85: has joined #RubyOnRails
[01:45:45] sarink: has joined #RubyOnRails
[01:45:56] cih: has joined #RubyOnRails
[01:51:03] joshkovach: has joined #RubyOnRails
[01:52:56] FrankD: has joined #RubyOnRails
[01:53:42] TheWhiteOx: has joined #RubyOnRails
[01:54:52] robbyoconnor: has joined #RubyOnRails
[01:55:30] nya: has joined #RubyOnRails
[01:56:34] oflannabhra: has joined #RubyOnRails
[01:57:01] joshkovach: has joined #RubyOnRails
[02:00:51] jenrzzz: has joined #RubyOnRails
[02:03:46] ianm_: has joined #RubyOnRails
[02:05:13] A124: has joined #RubyOnRails
[02:15:30] r00tl3ss: has joined #RubyOnRails
[02:18:54] charliesome: has joined #RubyOnRails
[02:19:04] jtb__: has joined #RubyOnRails
[02:20:42] jtb___: has joined #RubyOnRails
[02:20:54] RockLee: has joined #RubyOnRails
[02:24:47] jf: has joined #RubyOnRails
[02:25:01] yaymukund: has joined #RubyOnRails
[02:26:28] mary5030: has joined #RubyOnRails
[02:29:36] michael_mbp: has joined #RubyOnRails
[02:34:33] deavid: has joined #RubyOnRails
[02:34:53] nettoweb: has joined #RubyOnRails
[02:37:01] annlewis: has joined #RubyOnRails
[02:38:45] sankaber: has joined #RubyOnRails
[02:39:07] zlogan: has joined #RubyOnRails
[02:39:27] diegoviola: has joined #RubyOnRails
[02:41:09] EminenceHC: has joined #RubyOnRails
[02:44:27] stannard: has joined #RubyOnRails
[02:48:41] jun: has joined #RubyOnRails
[02:50:40] oflannabhra: has joined #RubyOnRails
[02:51:24] Guest4579: has joined #RubyOnRails
[02:54:16] rclanan: has joined #RubyOnRails
[02:55:04] Guest4579: has left #RubyOnRails: ()
[02:55:06] SteenJobs: has joined #RubyOnRails
[02:58:01] iloveitaly: has joined #RubyOnRails
[02:58:22] konsolebox: has joined #RubyOnRails
[02:58:45] corioliss: has joined #RubyOnRails
[02:59:14] mloy: has joined #RubyOnRails
[03:00:25] Flyy7: has joined #RubyOnRails
[03:01:31] stardiviner: has joined #RubyOnRails
[03:01:45] baweaver: has joined #RubyOnRails
[03:04:00] lasker85: has joined #RubyOnRails
[03:05:42] Reza_: has joined #RubyOnRails
[03:07:47] diego1: has joined #RubyOnRails
[03:08:27] r00tl3ss: has joined #RubyOnRails
[03:08:39] mxrguspxrt: has joined #RubyOnRails
[03:09:19] braincrash: has joined #RubyOnRails
[03:09:42] Meow-J: has joined #RubyOnRails
[03:10:16] moeabdol: has joined #RubyOnRails
[03:12:09] diego2: has joined #RubyOnRails
[03:12:18] mary5030: has joined #RubyOnRails
[03:16:09] Reza_: http://stackoverflow.com/questions/32883978/get-orders-not-liked-by-logged-in-user-model-in-rails-4
[03:16:53] Reza_: my question, found solution. (UPDATED part)
[03:17:03] arup_r: has joined #RubyOnRails
[03:17:12] Reza_: but please, is there any where method way?
[03:18:01] diego2: has joined #RubyOnRails
[03:19:52] pontiki: has joined #RubyOnRails
[03:22:03] iliketurtles: has joined #RubyOnRails
[03:24:01] iliketurtles: I have several service classes that make external API calls. They have to happen in a specific order. It;s possible that the API will respond with an error; in this case, the API provider demands that we re-run the API request until success (this is generally only 1-3 re-runs). I want to do this using sidekiq, but am having trouble thinking through how to preserve the order of the API requests, since sidekiq is asynchronou
[03:27:59] iliketurtles: has joined #RubyOnRails
[03:28:02] sarink: has joined #RubyOnRails
[03:28:18] rhizome: kinda hard to tell what your goal is
[03:28:58] iliketurtles: sorry IRC client crashed, lost last messages
[03:30:17] chipotle: has joined #RubyOnRails
[03:30:28] iliketurtles: can you repeat
[03:30:46] charliesome: has joined #RubyOnRails
[03:30:48] rhizome: kinda hard to tell what your goal is
[03:31:18] yfeldblum: has joined #RubyOnRails
[03:32:08] diego3: has joined #RubyOnRails
[03:32:16] RegulationD: has joined #RubyOnRails
[03:32:18] arup_r: After submitting the form rails is not sending the form_data, no params are showing up https://gist.github.com/aruprakshit/f2d807a8c242b5df296d
[03:32:30] iliketurtles: pretty simple, i'm creating some objects on a remote service, and their API is flaky, so sometimes I have to rerun an API request. but if the API requests run out of order they will fail. basically API request 1 produces an identifier that has to exist for API request 2, and so on.
[03:32:38] diego1: has joined #RubyOnRails
[03:32:57] diego1: has joined #RubyOnRails
[03:33:12] workmad3: has joined #RubyOnRails
[03:35:46] mloy: Sorry about that, mt
[03:35:47] pontiki: iliketurtles: consider the collection of your service calls forms a workflow. you should manage it as one. there's no reason not to schedule the tasks with sidekiq, but it sounds like you still need something like a state machine or workflow manager
[03:36:47] jun: has joined #RubyOnRails
[03:37:07] iliketurtles: so my sidekiq job would be a call to the workflow manager, and the manager would maintain the order of the API calls? but lets say one API call fails, will sidekiq retry the ENTIRE job, or the one line of ruby that raised the exception?
[03:37:08] _djbkd: has joined #RubyOnRails
[03:37:08] rickmasta: has joined #RubyOnRails
[03:37:47] annlewis: has joined #RubyOnRails
[03:38:09] pontiki: each api call can still be a single sidekiq task; the workflow manager would (well, could) be another much longer-running background task
[03:39:18] pontiki: another way is to wrap each api call in a begin-rescue with retry and not schedule them individually with sidekiq, but this gets hairy
[03:39:38] cwright1986: has joined #RubyOnRails
[03:39:43] baweaver: Sidekiq has after hooks
[03:39:50] baweaver: Just put each subsequent one in there
[03:40:34] ramfjord_: has joined #RubyOnRails
[03:40:45] pontiki: oh, didn't know sidekiq had them; i knew ActiveJob has them
[03:40:51] baweaver: ActiveJob does
[03:41:02] baweaver: you can fake it otherwise by mimicking the behavior
[03:41:09] baweaver: Sidekiq does in the full version
[03:41:15] pontiki: the pro version?
[03:41:27] baweaver: what irks me is that ActiveJob hides a lot of features like retry counts....
[03:42:12] arup_r: any help ?
[03:42:28] iliketurtles: pontiki: so when the workflow manager makes the calls to each child "API request worker", how will it know that the first request has finished before firing off the second, and so on?
[03:43:50] iliketurtles: baweaver: so to have after_perform hooks I'd need to use ActiveJob, correct?
[03:43:50] pontiki: iliketurtles: that's why i mean by a state machine; when the task finishes successfully, it emits an event for the state machine. baweaver's concept does seem simpler
[03:44:12] baweaver: simple as that
[03:44:17] iliketurtles: baweaver: http://edgeguides.rubyonrails.org/active_job_basics.html#available-callbacks
[03:45:11] baweaver: use ActiveJob, otherwise you end up with your own wrapper
[03:45:22] iliketurtles: baweaver: and with this approach I get the same retry functionality that is built into the backend (sidekiq)?
[03:45:24] baweaver: AJ does have its warts, but then again what doesn't?
[03:45:27] mary5030: has joined #RubyOnRails
[03:45:38] iliketurtles: solid approach!
[03:45:39] pontiki: i don't! you cad!
[03:45:44] baweaver: except it retries near indefinitely, which is an AJ issue
[03:45:51] iliketurtles: lol, can't be set?
[03:46:33] baweaver: nope, not exposed
[03:46:38] baweaver: for whatever asinine reason
[03:47:32] iliketurtles: that seems like a big problem
[03:48:23] baweaver: http://stackoverflow.com/questions/28412913/disable-automatic-retry-with-activejob-used-with-sidekiq
[03:48:30] i: has joined #RubyOnRails
[03:49:03] iliketurtles: baweaver: well i want it to retry, but not infinitely.
[03:49:12] baweaver: between this and making sure supper doesn't burn if I take a second
[03:49:26] iliketurtles: didnt see the max_retries
[03:50:01] pontiki: bedtime, methinks
[03:50:18] charliesome: has joined #RubyOnRails
[03:55:25] EminenceHC: has joined #RubyOnRails
[03:56:16] jenrzzz: has joined #RubyOnRails
[03:58:05] arup_r: any idea about the issue why my form_for not posting data inside it? https://gist.github.com/aruprakshit/f2d807a8c242b5df296d
[04:00:14] mxrguspxrt: has joined #RubyOnRails
[04:01:17] CheckYourSix: has joined #RubyOnRails
[04:05:02] Macaveli: has joined #RubyOnRails
[04:07:51] ramfjord: has joined #RubyOnRails
[04:09:54] arup_r: I got stuck in this problem since last night.. I have no clue also
[04:10:30] mary5030: has joined #RubyOnRails
[04:12:29] arup_r: I resolved it..
[04:16:18] rickmasta: has joined #RubyOnRails
[04:18:33] MarkTR: has joined #RubyOnRails
[04:24:27] iloveitaly: has joined #RubyOnRails
[04:25:23] greengriminal: has joined #RubyOnRails
[04:28:26] i: has joined #RubyOnRails
[04:28:51] dopie: has joined #RubyOnRails
[04:31:03] yfeldblum: has joined #RubyOnRails
[04:34:03] charliesome: has joined #RubyOnRails
[04:34:43] charliesome: has joined #RubyOnRails
[04:37:45] paulcsmith: has joined #RubyOnRails
[04:38:40] annlewis: has joined #RubyOnRails
[04:45:43] Maletor: has joined #RubyOnRails
[04:47:07] juliojulio: has joined #RubyOnRails
[04:47:48] cih: has joined #RubyOnRails
[04:48:23] DanKnox: has joined #RubyOnRails
[04:49:16] juliojulio: has joined #RubyOnRails
[04:50:10] juliojulio_: has joined #RubyOnRails
[04:50:49] juliojulio_: Does anyone know any open-source rails apps, that syncronize with an external api?
[04:51:11] juliojulio_: i'm building something that sync's with evernote, and I want to have some examples to reference
[04:55:37] sadaf2606: has joined #RubyOnRails
[04:58:55] johnflux: has joined #RubyOnRails
[04:58:55] johnflux: has joined #RubyOnRails
[05:00:42] mxrguspxrt: has joined #RubyOnRails
[05:01:13] Creeves: has joined #RubyOnRails
[05:02:11] ramfjord: has joined #RubyOnRails
[05:05:08] arup_r: how can I make the array while submitting form, "user_ids"=>"[1,3]" to "user_ids"=>[1,3] ?
[05:05:17] arup_r: https://gist.github.com/aruprakshit/f2d807a8c242b5df296d
[05:05:28] Contigi: has joined #RubyOnRails
[05:05:45] bronson: has joined #RubyOnRails
[05:06:29] Lytol: has joined #RubyOnRails
[05:07:32] baweaver: has joined #RubyOnRails
[05:09:55] tsujp: has joined #RubyOnRails
[05:10:36] atal421: has joined #RubyOnRails
[05:10:58] SteenJobs: has joined #RubyOnRails
[05:12:54] IFrank00: has joined #RubyOnRails
[05:16:58] dionysus69: has joined #RubyOnRails
[05:17:17] charliesome: has joined #RubyOnRails
[05:19:11] tknz: has joined #RubyOnRails
[05:20:04] dideler: has joined #RubyOnRails
[05:21:14] charliesome: has joined #RubyOnRails
[05:21:19] workmad3: has joined #RubyOnRails
[05:23:48] charliesome: has joined #RubyOnRails
[05:24:08] makman: has joined #RubyOnRails
[05:26:22] dhjondoh: has joined #RubyOnRails
[05:30:34] sevenseacat: has joined #RubyOnRails
[05:31:45] jun: has joined #RubyOnRails
[05:36:18] CheckYourSix: has joined #RubyOnRails
[05:36:32] sevenseacat: has joined #RubyOnRails
[05:36:50] RegulationD: has joined #RubyOnRails
[05:37:15] FrankD: has joined #RubyOnRails
[05:37:20] dnewkerk: has joined #RubyOnRails
[05:39:19] annlewis: has joined #RubyOnRails
[05:42:02] paulcsmith: has joined #RubyOnRails
[05:44:05] Maletor: has joined #RubyOnRails
[05:44:41] Cervajz: has joined #RubyOnRails
[05:45:20] aganov: has joined #RubyOnRails
[05:45:54] tagrudev: has joined #RubyOnRails
[05:46:03] rickmasta: has joined #RubyOnRails
[05:46:14] SteenJobs: has joined #RubyOnRails
[05:46:42] Cervajz_: has joined #RubyOnRails
[05:52:41] makman: has joined #RubyOnRails
[05:52:53] TomyLobo: has joined #RubyOnRails
[05:53:25] havenwood: has joined #RubyOnRails
[05:54:15] makman: has joined #RubyOnRails
[05:55:44] htmldrum: has joined #RubyOnRails
[05:57:08] makman: has joined #RubyOnRails
[05:58:02] dikaio: has joined #RubyOnRails
[05:58:31] TvL2386: has joined #RubyOnRails
[05:59:04] zomgbie: has joined #RubyOnRails
[05:59:57] banjara: has joined #RubyOnRails
[06:01:29] charliesome: has joined #RubyOnRails
[06:03:26] charliesome: has joined #RubyOnRails
[06:05:08] krz: has joined #RubyOnRails
[06:05:18] stannard: has joined #RubyOnRails
[06:06:25] mosez: has joined #RubyOnRails
[06:06:51] bronson: has joined #RubyOnRails
[06:08:20] Bilbo-baggons: has joined #RubyOnRails
[06:16:13] charliesome: has joined #RubyOnRails
[06:18:43] makman: has joined #RubyOnRails
[06:20:00] rickmasta: has joined #RubyOnRails
[06:20:13] DanKnox: has joined #RubyOnRails
[06:21:52] toretore: has joined #RubyOnRails
[06:22:01] arup_r: atmosx: hlo
[06:22:15] arup_r: have you used bootstrap-sortable gem ?
[06:23:58] chipotle: has joined #RubyOnRails
[06:24:56] charliesome: has joined #RubyOnRails
[06:25:01] herbst: has joined #RubyOnRails
[06:25:05] rvanlieshout: has joined #RubyOnRails
[06:27:47] makman: has joined #RubyOnRails
[06:27:47] cwright1986: has joined #RubyOnRails
[06:27:48] eGGsha: has joined #RubyOnRails
[06:28:42] manfrin_: has joined #RubyOnRails
[06:29:17] qejk: has joined #RubyOnRails
[06:30:37] tenderlo_: has joined #RubyOnRails
[06:32:40] paulcsmith: has joined #RubyOnRails
[06:33:07] Lytol: has joined #RubyOnRails
[06:33:13] ruurd: has joined #RubyOnRails
[06:34:02] cwright1986: has joined #RubyOnRails
[06:35:36] rushed: has joined #RubyOnRails
[06:36:35] cwright1986: Can anyone give their opinion on freelancing RoR and the current market state?
[06:37:42] rvanlieshout: cwright1986: ?
[06:38:20] Pumukel: has joined #RubyOnRails
[06:38:44] havenwood: cwright1986: I'm for it.
[06:39:01] sevenseacat: cwright1986: cloudy with a chance of meatballs.
[06:40:10] annlewis: has joined #RubyOnRails
[06:40:20] cwright1986: i'm just curious what technology i should be investing my time learning for freelance work. ruby looked interesting
[06:40:28] sevenseacat: if it looks interesting, learn it
[06:40:51] cwright1986: as long as it's financially viable
[06:41:12] tetraktys: has joined #RubyOnRails
[06:43:09] sevenseacat: personally I like to learn the interesting stuff in the breaks between people paying me to do things I already know
[06:43:26] sevenseacat: is why I'm now learning elixir :)
[06:44:04] makman: has joined #RubyOnRails
[06:44:46] stardiviner: has joined #RubyOnRails
[06:48:29] IFrank00: has joined #RubyOnRails
[06:48:50] habitullence: has joined #RubyOnRails
[06:50:55] makman: has joined #RubyOnRails
[06:53:26] arup_r: I am using https://github.com/drvic10k/bootstrap-sortable .. but some columns are sorting and some are not
[06:53:49] sevenseacat: thats a shame.
[06:54:42] sevenseacat: what do you want us to do about it?
[06:55:10] arup_r: You can't help me.. I am just saying.. how buggy things are
[06:55:26] sevenseacat: its more likely that you're doing it wrong.
[06:56:53] arup_r: hum.. but half working half not .. is crazy
[06:58:06] arup_r: I can be wrong only.. not anyone else
[06:58:20] riotjones: has joined #RubyOnRails
[06:58:35] sevenseacat: not what I said.
[06:58:40] habitullence: has joined #RubyOnRails
[07:00:08] jas02: has joined #RubyOnRails
[07:00:32] makman: has joined #RubyOnRails
[07:02:05] AzaToth: has joined #RubyOnRails
[07:03:52] ruurd: has joined #RubyOnRails
[07:03:53] dionysus69: has joined #RubyOnRails
[07:03:54] linus4: has joined #RubyOnRails
[07:05:23] nfk|laptop: has joined #RubyOnRails
[07:06:11] bronson: has joined #RubyOnRails
[07:06:19] noobda: has joined #RubyOnRails
[07:09:23] workmad3: has joined #RubyOnRails
[07:09:40] noobda: Hey guys I'm unable to start a simple ruby app on a VPN. What am I doing wrong? http://ideone.com/Z0zN8F
[07:10:16] habitullence: has joined #RubyOnRails
[07:10:50] iliketurtles: noobda: well there are a number of errors in that paste you sent us, have you tried addressing any of them?
[07:10:58] comrad: has joined #RubyOnRails
[07:11:39] srinidhi: has joined #RubyOnRails
[07:11:49] skroon: has joined #RubyOnRails
[07:11:59] noobda: iliketurtles: this is the prominent one if I had to guess Cannot assign requested address - bind(2) (Errno::EADDRNOTAVAIL). But I have no idea how to solve this!
[07:13:23] Fire-Dragon-DoL: has joined #RubyOnRails
[07:14:40] iliketurtles: well the address you're trying to bind to is obviously unusable; what $IP are you trying to bind to
[07:14:41] noobda: iliketurtles: oh damn I figured it out. I was using the wrong IP address. I was using my public IP ( When I tried entering it ran without errors. However, how do I access my app through the internet now?
[07:14:47] chipotle: has joined #RubyOnRails
[07:14:53] cih: has joined #RubyOnRails
[07:15:10] iliketurtles: ummm i suppose it depends what your goal is; are you trying to host your own web server?
[07:15:21] noobda: yeah that's what I was trying
[07:15:34] arBmind: has joined #RubyOnRails
[07:15:46] iliketurtles: if you just need a localhost tunnel for testing you can use ngrok
[07:16:12] iliketurtles: if you're trying to host your own web server that's basically a religious debate i'm going to stay out of :P
[07:17:00] noobda: iliketurtles: I see. haha, I'm just trying to do it for learning. Wanted to show my friends my app, but can't figure out how to do it.
[07:17:36] noobda: I have access to a free VPN but I am unable to deploy even a sample rails app on the internets :(
[07:18:26] habitullence: has joined #RubyOnRails
[07:19:39] youngbaks: has joined #RubyOnRails
[07:22:34] FCser: has joined #RubyOnRails
[07:22:57] alex88: has joined #RubyOnRails
[07:23:49] dazonic: has joined #RubyOnRails
[07:24:15] iliketurtles: noobda: maybe just use heroku?
[07:24:46] noobda: iliketurtles: that's okay I found a blog, will try to do duplicate it :D
[07:25:07] LBRapid: has joined #RubyOnRails
[07:26:16] paulcsmith: has joined #RubyOnRails
[07:26:23] dazonic: has joined #RubyOnRails
[07:28:39] DoubleMalt: has joined #RubyOnRails
[07:30:25] dazonic: has left #RubyOnRails: ()
[07:30:54] dazonic: has joined #RubyOnRails
[07:33:16] petricore: has joined #RubyOnRails
[07:33:25] dazonic: has left #RubyOnRails: ()
[07:34:16] dazonic: has joined #RubyOnRails
[07:34:32] dazonic: I???m using git as a source for a gem, like github: ???daz/repo??????.. it???s not updating the source, just using an old version based on the version number. How do i force it to update, or delete the old one?
[07:38:08] pawnbox: has joined #RubyOnRails
[07:38:16] CheckYourSix: has joined #RubyOnRails
[07:39:19] youngbaks: has joined #RubyOnRails
[07:40:44] sevenseacat: `bundle update gem_name`
[07:40:51] annlewis: has joined #RubyOnRails
[07:42:44] charliesome: has joined #RubyOnRails
[07:49:36] tvw: has joined #RubyOnRails
[07:49:36] CheckYourSix: has joined #RubyOnRails
[07:51:45] ruurd: has joined #RubyOnRails
[07:54:31] Peteykun: has joined #RubyOnRails
[07:54:57] Balzrael: has joined #RubyOnRails
[07:57:18] dazonic: sevenseacat yep i ran bundle update gem_name, it???s still using the old version
[07:57:44] mike___1234: has joined #RubyOnRails
[07:58:06] sevenseacat: is there actually an updated version in the github repo? :D
[07:58:21] dazonic: it???s like the version number takes precedence over ref in Gemfile.lock
[07:58:31] dazonic: yes it???s my repo!
[07:58:35] sevenseacat: what version number?
[07:59:00] dazonic: the version number in the gem???s gemspec
[07:59:03] sevenseacat: it wont upgrade to a version number that doesnt match whatever matcher you provide
[07:59:15] sevenseacat: thats the whole point of using version numbers
[07:59:49] dazonic: my gemfile just has this: gem 'f1results', github: 'daz/f1results'
[08:00:09] dazonic: Gemfile.lock refers to the latest ref
[08:00:13] DLSteve: has joined #RubyOnRails
[08:00:34] Bilbo-baggons: hey guys, I have an issue in production where users are clicking the submit button in quick sucession and it is submitting the form multiple times, (creating new id???s each time) which is creating a lot of duplication, how would I go about trying to stop this from happening?
[08:00:40] sevenseacat: dazonic: so whats the problem? :/
[08:00:46] sevenseacat: if Gemfile.lock is updated
[08:00:50] sevenseacat: and the code is updated
[08:01:00] dazonic: but it also has the version number in Gemfile.lock under specs:
[08:01:34] dazonic: the gem itself isnt being required, it???s using an old version
[08:01:43] sevenseacat: so the ref isnt the latest ref?
[08:02:06] sevenseacat: so why on earth did you just say it was
[08:02:26] sevenseacat: what exactly is in your Gemfile.lock
[08:02:52] siaW: has joined #RubyOnRails
[08:02:54] dazonic: sorry, i misread??? the Gemfile.lock revision: is the latest ref, definitely
[08:03:16] sevenseacat: then thats what your app is using
[08:03:30] mxrguspxrt: has joined #RubyOnRails
[08:03:55] sevenseacat: Bilbo-baggons: disable the button after they click it?
[08:04:28] dazonic: thats the thing, it definitely isn???t, i???m getting no method errors on APIs i just added
[08:04:50] Bilbo-baggons: disable the submit button?
[08:05:14] dazonic: i???ve run into it before??? if i manually clear out the old gem versions from my .rbenv dir, it works
[08:05:39] sevenseacat: dazonic: did you restart your server/spring/everything after upgrading the gem?
[08:05:53] dazonic: could it be because i have require: false on the gem
[08:06:01] dazonic: yes, everything
[08:06:18] sevenseacat: thats not what you said you had in your Gemfile
[08:06:49] dazonic: correct, sorry
[08:07:04] bronson: has joined #RubyOnRails
[08:07:26] dazonic: so that???s it?
[08:09:33] jsrn_: has joined #RubyOnRails
[08:11:32] zomgbie: has joined #RubyOnRails
[08:13:13] x44x45x41x4E: has joined #RubyOnRails
[08:16:13] darutoko: has joined #RubyOnRails
[08:16:46] paulcsmith: has joined #RubyOnRails
[08:17:07] sadaf2606: has joined #RubyOnRails
[08:18:14] zomgbie: has joined #RubyOnRails
[08:18:53] dionysus69: has joined #RubyOnRails
[08:20:29] yardenbar: has joined #RubyOnRails
[08:24:48] cih: has joined #RubyOnRails
[08:28:53] artto: has joined #RubyOnRails
[08:32:03] habitullence: has joined #RubyOnRails
[08:32:49] quazimodo: give a route like api/users/3/company, would active_record_serializers json look like { company: { id: 5, name: 'whatever' } } or { companies: [{id: 5, name: 'whatever'}] } ?
[08:32:52] Grundell: has joined #RubyOnRails
[08:32:57] quazimodo: it's a 1-many relationship
[08:33:48] quazimodo: reason I ask is because i'm using the Her gem, it's not expecting to get { company: {} }, even when I specify i want to use active_model_serializers, so i'm thinking I made a mistake?
[08:33:53] Macaveli: has joined #RubyOnRails
[08:35:10] adre: has joined #RubyOnRails
[08:36:08] marr: has joined #RubyOnRails
[08:38:03] Fahrrnhei7: has joined #RubyOnRails
[08:38:53] defsdoor: has joined #RubyOnRails
[08:41:14] ruurd: has joined #RubyOnRails
[08:41:37] annlewis: has joined #RubyOnRails
[08:44:19] pawnbox: has joined #RubyOnRails
[08:44:39] BaNzounet: Is there a shortcut to get the traduction of an attribute? instead of : t('activerecord.attributes.ad.price') ?
[08:45:09] BaNzounet: translation*
[08:46:55] Juanchito: has joined #RubyOnRails
[08:46:58] cih: has joined #RubyOnRails
[08:47:10] Spami: has joined #RubyOnRails
[08:47:26] zomgbie: has joined #RubyOnRails
[08:48:58] voker57: has joined #RubyOnRails
[08:49:31] habitullence: Good morning :)
[08:49:44] habitullence: How are we all?
[08:51:30] mosez: we are all fine :)
[08:53:25] ruurd: And nice!
[08:53:30] ruurd: Good morning!
[08:54:12] wethu: has joined #RubyOnRails
[08:54:46] rvanlieshout: friday. so what's to complain
[08:55:10] habitullence: Friiiiiday *hi5*
[08:55:22] habitullence: Hope everyone has a good day :)
[08:55:39] habitullence: Only a few hours 'til the weekend :D
[08:56:25] quazimodo: no I didn't
[08:56:29] quazimodo: butthole kitty
[08:56:49] alex88: has joined #RubyOnRails
[08:57:20] sevenseacat: ACTION raises eyebrow
[08:57:21] yaymukund: has joined #RubyOnRails
[08:57:25] Fahrenhei7: has joined #RubyOnRails
[08:57:33] workmad3: has joined #RubyOnRails
[08:57:35] rvanlieshout: didn't expect that one
[08:58:41] habitullence: quazimodo: want a shoulder or 594 to cry on?
[08:59:07] quazimodo: i dno i've a giant fuckre of a day
[08:59:35] quazimodo: hope y'all had a much better time honestly
[09:02:21] Fahrenhe17: has joined #RubyOnRails
[09:02:43] fgo: has joined #RubyOnRails
[09:03:47] mikecmpbll: has joined #RubyOnRails
[09:04:18] dhjondoh: has joined #RubyOnRails
[09:05:01] charliesome: has joined #RubyOnRails
[09:08:05] bronson: has joined #RubyOnRails
[09:08:16] stannard: has joined #RubyOnRails
[09:09:31] jlebrech: has joined #RubyOnRails
[09:09:58] jlebrech: anyone move logic back into the controller and back out to the model to make sense of things?
[09:10:33] paulcsmith: has joined #RubyOnRails
[09:10:40] universa1: jlebrech: what?
[09:10:58] yardenbar: has joined #RubyOnRails
[09:11:31] tbuehlmann: what universa1 is trying to say: wat
[09:11:35] BryceT516: has joined #RubyOnRails
[09:11:37] jlebrech: i feel I should have start my project with fat controller and then refactored
[09:11:54] Radar: jlebrech: what
[09:12:14] universa1: jlebrech: why not think about "business logic" first, draw it out on paper and implement afterwards?
[09:12:30] jlebrech: universa1: yeah, make sense :D
[09:12:40] based_pdev_: has joined #RubyOnRails
[09:13:21] nertzy2: has joined #RubyOnRails
[09:13:57] yardenbar: has joined #RubyOnRails
[09:14:12] Fire-Dragon-DoL: has joined #RubyOnRails
[09:15:27] svkurowski_: has joined #RubyOnRails
[09:15:44] chouhoul_: has joined #RubyOnRails
[09:15:52] ernesto_1imenez: has joined #RubyOnRails
[09:15:54] ahmgeek_: has joined #RubyOnRails
[09:16:04] manfrin: has joined #RubyOnRails
[09:16:19] Rennex_: has joined #RubyOnRails
[09:16:43] xhoy_: has joined #RubyOnRails
[09:16:50] gregf__: has joined #RubyOnRails
[09:16:56] martinbjeldbak_: has joined #RubyOnRails
[09:17:16] jamon_: has joined #RubyOnRails
[09:17:41] Depili_: has joined #RubyOnRails
[09:17:42] yardenbar: has joined #RubyOnRails
[09:17:42] jkwood_: has joined #RubyOnRails
[09:17:52] n1lo_: has joined #RubyOnRails
[09:17:53] arathald_: has joined #RubyOnRails
[09:17:53] zmd: has joined #RubyOnRails
[09:17:54] quazimodo: jlebrech: service objects mate D
[09:17:58] dhjondoh: has joined #RubyOnRails
[09:18:04] Radar: Don't confuse the poor man
[09:18:24] nygrenh_: has joined #RubyOnRails
[09:18:47] jlebrech: quazimodo: yeah my service objects are a mess
[09:18:54] jalcine: has joined #RubyOnRails
[09:19:14] sevenseacat: Radar: you aren't a poor man.
[09:19:21] Radar: sevenseacat: #fact
[09:19:50] Radar: writing books be like http://cache2.asset-cache.net/gc/6501-000055-dollar-bills-on-bed-gettyimages.jpg?v=1&c=IWSAsset&k=2&d=vx6WePM%2B8YwH73EkG%2BdldsU2ZJi9hL6t%2FtoI2imXlHlZgOGSdaJbFRMo9j88BoFNILY7jGO7sbkIpM8pEaCsnQ%3D%3D
[09:20:02] Radar: Maybe I should've shortened that
[09:20:02] zomgbie: has joined #RubyOnRails
[09:20:13] mxrguspxrt: has joined #RubyOnRails
[09:20:38] Fahrenhei7: has joined #RubyOnRails
[09:20:47] sevenseacat: people are amazed when they ask me how much money I've made from my book and I tell them absolutely nothing
[09:21:03] Radar: "I did it for the love"
[09:21:20] teegee543: has joined #RubyOnRails
[09:21:42] finges_: has joined #RubyOnRails
[09:22:31] sevenseacat: then the person usuallly goes 'what, *nothing*?' and then my fiance interrupts with 'omg please don't get her started'
[09:22:35] herbst: i always wondered if its worth it. i guess it is for some, but not for most
[09:23:10] noodle: has joined #RubyOnRails
[09:23:14] Brando753: has joined #RubyOnRails
[09:23:16] rvanlieshout: the better question would be how much satisfaction you've got from writing the book
[09:23:53] sevenseacat: I did it for the credibility and recognition.
[09:24:06] DEA7TH: has joined #RubyOnRails
[09:24:10] herbst: think about your second book, how satisfying will it be if you first experience was more like wasting time (except the fun argument for sure)
[09:24:10] sevenseacat: well, not really, but I've gotten some of that at least.
[09:24:30] spectra: has joined #RubyOnRails
[09:25:26] habitullence: has joined #RubyOnRails
[09:25:41] DEA7TH: Is it ok to do one-line commands in the controller? Like @user.comments.delete_all, instead of delegating this to the model.
[09:25:46] Radar: Manning: "We'll pay you when the book is done. Promise!"
[09:25:48] Radar: Then we complete the book
[09:26:01] Radar: Manning: "We will pay you at the start of the next quarter because we only pay royalties quarterly"
[09:26:04] Radar: Us: "How much do we get?"
[09:26:09] Radar: Manning: *crickets*
[09:26:21] habitullence: quazimodo: what doesn't kill you makes you stronger ;)
[09:26:35] Radar: DEA7TH: Yes because then what is the point of doing User.new and so on?
[09:27:03] sevenseacat: at this point when friends ask me where they can buy it that will get me the most money, I tell them to pirate it
[09:27:11] xhoy: has joined #RubyOnRails
[09:27:32] habitullence: Radar: no contract?!
[09:27:43] workmad3: has joined #RubyOnRails
[09:27:51] Radar: habitullence: of course there is a contract but (again, of course) it favours Manning.
[09:27:59] dhjondoh: has joined #RubyOnRails
[09:28:03] DEA7TH: idk I'm a bit confused by OO's information hiding thing. Some things (like Clojure) don't even recommend that.
[09:28:12] Radar: DEA7TH: explain please
[09:28:18] sevenseacat: ACTION adds another name to the 'regularly scheduled grumpy email' list
[09:28:49] sevenseacat: I've already threatened one set of idiots with legal action today
[09:29:00] habitullence: DEA7TH: hiding thing?
[09:29:41] DEA7TH: Radar: by doing @user.comments, my controller now knows that @user has a comments field. That's supposedly bad in OO, but ok in Clojure. I'm all against 2-3+ lines or reusable logic in controllers, but I don't understand the point of encapsulation.
[09:29:48] habitullence: sevenseacat: unleash the hounds!
[09:29:53] DEA7TH: (I should've said encapsulation instead of hiding)
[09:30:22] Radar: DEA7TH: imo the whole point of controllers is to call out to models
[09:30:29] habitullence: DEA7TH: controller doesn't know but user does ;)
[09:30:46] Radar: DEA7TH: I think a couple of lines of model code is fine. If it's > 3 lines of code that deals with a model then the code should go into the model as a method... and then that method should be called from the controller
[09:30:54] habitullence: https://en.wikipedia.org/wiki/Law_of_Demeter
[09:31:30] habitullence: DEA7TH: also this https://www.google.co.uk/url?sa=t&rct=j&q=&esrc=s&source=web&cd=4&cad=rja&uact=8&ved=0CDMQtwIwA2oVChMIyvTMmL2jyAIVx7sUCh0MBgBB&url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D8bZh5LMaSmE&usg=AFQjCNElBEEI9qkVEARCBVPbCS18nU2J8g&sig2=j-BeKVwvhhALBJhQGyl0ww
[09:31:45] habitullence: this https://www.youtube.com/watch?v=8bZh5LMaSmE
[09:31:53] Radar: admin plz ban
[09:32:47] habitullence: There's no tracking in that link.... I promise ;P
[09:34:07] habitullence: DEA7TH: Also there's a destroyallsoftware video that talks about this kind of principle/refactoring but I can't remember which off the top of my head
[09:34:40] habitullence: Did his brain explode already?!
[09:34:55] habitullence: I've killed death, yay!
[09:35:02] DEA7TH: I've watched a few such videos but I'm still a bit confused.
[09:35:13] DEA7TH: Solution: watch more of 'em!
[09:36:09] DEA7TH: Perhaps some day, I will make reek happy. (reek is a gem)
[09:37:28] habitullence: Yep, will take time for everything to sink in and make sense.. The Sandi Metz and Gary Bernhardt stuff will go a long way towards clearing things up for you
[09:37:35] charliesome: has joined #RubyOnRails
[09:38:04] sevenseacat: is it bad that my first thought on Reek was the game of thrones character
[09:38:27] Radar: damn it helpa
[09:38:31] Radar: let me down in my hour of need
[09:40:47] makman: has joined #RubyOnRails
[09:41:35] subshad: has joined #RubyOnRails
[09:42:20] DEA7TH: I don't like the first paragraph of the disadvantages of the Law of Demeter wiki page. The many wrappers part.
[09:42:27] annlewis: has joined #RubyOnRails
[09:43:47] DEA7TH: it will probably make sense when I have to deal with a sufficiently big system
[09:44:06] reber: has joined #RubyOnRails
[09:44:34] dionysus69: has joined #RubyOnRails
[09:46:51] charliesome: has joined #RubyOnRails
[09:48:14] moeabdol: has joined #RubyOnRails
[09:48:29] blackmesa: has joined #RubyOnRails
[09:54:22] nettoweb: has joined #RubyOnRails
[09:55:23] arBmind: has joined #RubyOnRails
[09:57:46] walidvb: has joined #RubyOnRails
[09:58:09] walidvb: hi all, i'm having issues with route helpers.
[10:00:47] universa1: so tell us about it
[10:01:32] dhjondoh: has joined #RubyOnRails
[10:02:18] sevenseacat: where's the fun in that?
[10:03:14] universa1: you're right. i just give a non-verbal/written answer then ;)
[10:04:30] paulcsmith: has joined #RubyOnRails
[10:05:36] jenrzzz: has joined #RubyOnRails
[10:05:51] stamina: has joined #RubyOnRails
[10:09:02] bronson: has joined #RubyOnRails
[10:11:01] vasilakisfil_: has joined #RubyOnRails
[10:11:22] monq: has joined #RubyOnRails
[10:12:06] vasilakisfil_: has left #RubyOnRails: ()
[10:12:31] vasilakisFiL: has joined #RubyOnRails
[10:12:55] vasilakisFiL: hey! which branch of AMS should I use? seems like 0.10 is too tied to active record and I have many POROs :/
[10:14:09] arup_r: has joined #RubyOnRails
[10:14:23] universa1: vasilakisfil: the one that best fits your needs?
[10:15:25] universa1: vasilakisfil: and augmenting your poros with activemodel shouldn't be too hard. or not using ams at all might also be an alternative.
[10:17:11] Ergo: has joined #RubyOnRails
[10:17:15] nfk|laptop: has joined #RubyOnRails
[10:17:24] vasilakisFiL: I might use 0.10 eventually
[10:17:40] DanKnox: has joined #RubyOnRails
[10:18:13] vasilakisFiL: but I feel the direction the AMS project has taken is wrong.. too tied to AR not good
[10:20:19] rickmasta: has joined #RubyOnRails
[10:20:41] universa1: vasilakisfil: it is tied to activemodel, not ar.
[10:24:15] relix: has joined #RubyOnRails
[10:27:13] frzn: has joined #RubyOnRails
[10:27:22] herbst: has joined #RubyOnRails
[10:27:23] habitullence: Can someone tell me if you always have to use keys in an association?
[10:27:41] universa1: habitullence: how else would you know which records belong to another one?
[10:27:47] universa1: elaptics: i guess foreign keys
[10:28:04] elaptics: it's the basics of relational databases
[10:28:31] habitullence: I'm doing something with postgis.. In one table polygons and points in the other
[10:28:57] elaptics: I'm not familiar with postgis and how that might work with AR
[10:28:59] habitullence: So I want to express a query for all the points within that polygon
[10:29:29] habitullence: Brief intro http://ngauthier.com/2013/08/postgis-and-rails-a-simple-approach.html
[10:29:39] habitullence: but doesn't cover cross model stuff
[10:29:59] bruno-_: has joined #RubyOnRails
[10:30:04] habitullence: How would you normal do stuff cross model without an id/keys/whatever
[10:30:19] universa1: habitullence: you don't.
[10:30:29] universa1: habitullence: use a scope.
[10:30:35] tetraktys: has joined #RubyOnRails
[10:31:09] universa1: Whatever.inside_polygon(polygon: some_polygon); class Whatever; scope :inside_polygon (polygon:) -> { some_where_magic }
[10:31:26] elaptics: or a query object if it's particularly complex
[10:32:21] j_mcnally: has joined #RubyOnRails
[10:32:42] habitullence: universa1: ok scopes.. thanks
[10:32:57] universa1: but then, i don't have a clue about postgis
[10:33:00] habitullence: elaptics: explain/link..
[10:33:26] universa1: habitullence: !g rails query object
[10:33:30] universa1: would be my approach ;)
[10:33:43] elaptics: habitullence: http://blog.codeclimate.com/blog/2012/10/17/7-ways-to-decompose-fat-activerecord-models/ see point 4
[10:34:04] habitullence: universa1: no problem, it seems like the whole things pretty niche/new right now... Google is a barren wasteland :|
[10:34:51] habitullence: universa1: mine too ;)
[10:35:41] habitullence: was looking for some recommend-by-a-person reading.. although Google feels more and more like it knows what I'm thinking, creepy
[10:36:28] habitullence: defsdoor: http://dictionary.reference.com/browse/barren
[10:36:39] defsdoor: habitullence, scray isn't it - I've just googled something and got suggestions to go to the toilet first
[10:37:05] vasilakisFiL: universa1 unfortunately it is tied to AR. otherwise posos would work out of the box with a simple module inclusion
[10:37:50] habitullence: defsdoor: Goooood... le :O
[10:38:12] habitullence: knows you better than you know yourself
[10:38:53] vasilakisFiL: universa1 https://github.com/rails-api/active_model_serializers/issues/1009#issuecomment-123162869
[10:39:12] defsdoor: what I hate though is googling for a product, or visiting amazon etc.. buying what I want and then getting targetted advertising for the same thing for the next 3 months
[10:39:17] defsdoor: I bought it already!
[10:40:13] habitullence: Good read elaptics :)
[10:41:16] sininen: has joined #RubyOnRails
[10:41:41] FailBit: <elaptics> http://blog.codeclimate.com/blog/2012/10/17/7-ways-to-decompose-fat-activerecord-models/
[10:41:44] FailBit: that blog post disturbs me slightly
[10:43:02] elaptics: FailBit: why's that?
[10:43:19] annlewis: has joined #RubyOnRails
[10:43:26] sevenseacat: has joined #RubyOnRails
[10:43:32] qejk: has joined #RubyOnRails
[10:44:16] FailBit: it feels like C++ all over again
[10:44:31] FailBit: 'make a lot of objects because objects are good'
[10:45:24] FailBit: > ???Any application with an??app/concerns directory is concerning.???
[10:45:27] FailBit: no, fuck that. single-model concerns are not ideal but seriously
[10:46:27] charliesome: has joined #RubyOnRails
[10:46:34] jsrn_: has joined #RubyOnRails
[10:48:40] chills42: has joined #RubyOnRails
[10:50:30] iateadonut: has joined #RubyOnRails
[10:52:51] allcentury: has joined #RubyOnRails
[10:53:53] riskish: has joined #RubyOnRails
[10:54:30] rodfersou: has joined #RubyOnRails
[10:55:08] charliesome: has joined #RubyOnRails
[10:56:42] tetraktys: has joined #RubyOnRails
[10:57:31] njero: has joined #RubyOnRails
[11:00:16] dionysus69: has joined #RubyOnRails
[11:00:33] hamster88: has joined #RubyOnRails
[11:00:40] hamster88: greetings everyone
[11:00:42] linus4: has joined #RubyOnRails
[11:01:06] paulcsmith: has joined #RubyOnRails
[11:01:14] hamster88: I have been trying to implement elasticsearch with searchkick on rails app but can't get it to work
[11:02:38] mugurel: has joined #RubyOnRails
[11:02:49] hamster88: when i type anything for search i get this error undefined method `paginate' for #<Searchkick::Results:0x007f3ff123f0e0>
[11:03:37] Guest250: has joined #RubyOnRails
[11:03:44] Guest250: has left #RubyOnRails: ()
[11:03:47] mugurel: A quick question related to mercurial and bitbucket, if i created a fork from one of my repos and i deleted that parent repo, but i added it back later with the same name, how can i point my fork to the newly created repo (because bitbucket does not recognire the new repo even if it has the same name)
[11:05:09] elaptics: FailBit: what's your alternative, fat models?
[11:05:33] Grundell: has joined #RubyOnRails
[11:07:09] DanKnox: has joined #RubyOnRails
[11:08:06] Fahrenhei7: has joined #RubyOnRails
[11:08:12] ramfjord: has joined #RubyOnRails
[11:08:31] jun: has joined #RubyOnRails
[11:08:52] charliesome: has joined #RubyOnRails
[11:08:53] naftilos76: has joined #RubyOnRails
[11:09:23] ruurd: has joined #RubyOnRails
[11:09:27] arup_: has joined #RubyOnRails
[11:10:01] bronson: has joined #RubyOnRails
[11:10:27] arup_r: has joined #RubyOnRails
[11:10:38] Coldblackice: has joined #RubyOnRails
[11:12:24] htmldrum: has joined #RubyOnRails
[11:13:02] linus4: has joined #RubyOnRails
[11:17:13] FailBit: elaptics: I'll take that over following java principles
[11:17:57] herbst: has joined #RubyOnRails
[11:18:03] elaptics: really? how do you find testing your application then? Or don't you bother with tests?
[11:18:03] FailBit: next thing you know I'll be building factories
[11:19:14] FailBit: I find testing tedious regardless of model scope
[11:21:52] FailBit: there's also not a huge amount of complex logic that goes on here... the biggest one is the search compiler which makes sense to be an object since it's used by controllers and models
[11:22:09] FailBit: it's stored in lib/
[11:22:21] FailBit: oh yeah that reminds me of why lib/ sucks in rails
[11:22:32] FailBit: it's not automatically reloaded on refresh
[11:23:58] rvanlieshout: why would it be in lib/?
[11:24:01] rvanlieshout: doesn't it belong to the app?
[11:24:42] pjammer: has joined #RubyOnRails
[11:25:04] emilkarl: has joined #RubyOnRails
[11:25:06] FailBit: it's not a model or a concern or a controller or a job or a mailer or a view or a public asset or a helper
[11:25:26] FailBit: it belongs in lib/. it's a PORO and does not require rails to run.
[11:25:46] FailBit: service <> job
[11:26:11] elaptics: if it's specific to the application domain then I put it within the app structure, if it's totally generic code that could be reused in multiple projects, aka an actual library then it goes in lib
[11:26:42] emilkarl: I have a has_many relationship and nested form.
[11:27:07] emilkarl: hmm never mind.
[11:27:28] rvanlieshout: agreed FailBit, what's a PORO?
[11:27:37] rvanlieshout: elaptics: or in a gem
[11:27:41] FailBit: plain old ruby object
[11:27:42] Karolis: has joined #RubyOnRails
[11:27:58] FailBit: has no ties to rails whatsoever
[11:28:01] elaptics: rvanlieshout: yep
[11:28:31] FailBit: the compiler domain is too specific for a gem but too generic for app inclusion
[11:28:32] elaptics: FailBit: I have lots of POROs in my rails apps, they're still specific to the application domain though
[11:29:00] Karolis: has left #RubyOnRails: ()
[11:30:27] KanoTheDev: has joined #RubyOnRails
[11:31:24] siaW: has joined #RubyOnRails
[11:32:45] northfurr: has joined #RubyOnRails
[11:33:36] ldnunes: has joined #RubyOnRails
[11:33:57] Fahrenhe17: has joined #RubyOnRails
[11:33:58] rushed: has joined #RubyOnRails
[11:36:25] moeabdol: has joined #RubyOnRails
[11:37:51] nya: has joined #RubyOnRails
[11:38:41] linus4: has joined #RubyOnRails
[11:43:36] c0dedead: has joined #RubyOnRails
[11:43:43] KanoTheDev: Hello, how to write this for postgres? .select('(firstname || " " || lastname) as \'full_name\', *')
[11:43:59] DanKnox: has joined #RubyOnRails
[11:44:22] annlewis: has joined #RubyOnRails
[11:44:51] paulcsmith: has joined #RubyOnRails
[11:46:06] jhass: KanoTheDev: why not add def full_name; "#{firstname} #{lastname}"; end; to the model?
[11:47:13] emilkarl: if I have nested attributes and create a records, is it possible to access the nested attributes data inside an after_save callback?
[11:47:36] universa1: emilkarl: self.whatever_nested_models.each ?
[11:47:44] pwnd_nsfw: Just like youw ould regularly...
[11:48:15] yardenbar: has joined #RubyOnRails
[11:48:53] chipotle: has joined #RubyOnRails
[11:48:53] c0dedead: Hey, I am still relatively new to Rails and am hoping someone can help point me in the right direction to solve a problem I am having. I am working on adding some new featuring to an existing API. The API has users, and vehicles which are owned by different users. I need to extend the current functionality so that whenever a vehicle is retrieved from the database there will be a check to see if the v
[11:48:53] emilkarl: hmm even in the after_save?
[11:48:59] c0dedead: ehicle is owned by the current user, if it is not owned by the current user I need to remove an attribute. Is there something like a "before get" hook that I can put on the model to do this neatly in one place? The way it is now appears to use several different methods for retrieving vehicles depending on the circumstance.
[11:49:09] KanoTheDev: jhass, i need to have a method which returns a relation
[11:49:23] norc: has joined #RubyOnRails
[11:49:47] emilkarl: ok, but that wont be accessible outside of self right?
[11:50:06] jhass: KanoTheDev: because...?
[11:50:22] norc: Hi. I have a table where "name VARCHAR2" acts as the primary key. Is there some special naming convention I should use for this column (and referencing foreign keys) ?
[11:50:31] universa1: emilkarl: maybe step back from implementation specifics, and tell us what you actually want to do / achieve
[11:50:46] yardenbar: has joined #RubyOnRails
[11:51:08] emilkarl: I have a record that when its saved it will create a number of duplicates of itself.
[11:51:27] norc: Or should I simply manually set primary key, and have referencing tables use "foo.name"?
[11:51:41] emilkarl: I also want to duplicate the nested objects. But they arent created in the after_save hook.
[11:51:51] universa1: emilkarl: so use the after_commit hook.
[11:52:21] jhass: c0dedead: you probably want to introduce a VehiclePresenter or something that takes the current user in the initializer and hides the attribute when rendering the JSON
[11:52:48] jhass: that is that provides an as_json that's aware of the current_user
[11:52:59] Jasaka: has joined #RubyOnRails
[11:53:00] c0dedead: Great, thanks.
[11:53:18] KanoTheDev: jhass, getting a search string from frontend, parsing keywords and values, making relation with each key... one of the search value is full name so i need to concat first and last names somehow... any suggestions? :)
[11:53:27] Fahrenhei7: has joined #RubyOnRails
[11:54:41] jhass: there are libraries that solve that I think, but if you insist, just replace the double quotes with single quotes, http://www.postgresql.org/docs/9.4/static/functions-string.html
[11:55:06] emilkarl: thanks universa1
[11:55:11] emilkarl: i???ll look in to it
[11:55:12] KanoTheDev: jhass, thank you
[11:55:14] norc: Also, is using a single HTTP POST to accept a parameter like "1-5", and have the controller create 5 objects a sensible thing? Or does HTTP expect me to only create a single resource for a POST?
[11:55:37] universa1: norc: http doesn't expect anything from you.
[11:55:44] universa1: regarding creating resources
[11:56:31] trautwein: has joined #RubyOnRails
[11:56:39] norc: universa1: well the RFC uses the word "resource" in singular.. :)
[11:56:57] norc: RFC 2616 that is.
[11:57:01] universa1: norc: so the collection of whatever is the resource... you created a single resource
[11:58:10] universa1: norc: Providing a block of data, such as the result of submitting a
[11:58:10] universa1: form, to a data-handling process;
[11:58:42] workmad3: norc: POST is pretty much free of any spec-defined meaning
[11:59:18] norc: workmad3: That would explain why modern browsers have a tendency to use POST for pretty much.. everything. :-)
[11:59:51] norc: Well, anything that is not a GET that is.
[11:59:52] workmad3: norc: that's a different situation, mostly caused by HTML <form> elements only supporting GET and POST
[12:00:10] norc: Oh. I was not aware that it stemmed from that part. Interesting
[12:00:31] workmad3: norc: once you get into AJAX requests and all HTTP verbs being supported again, there's more variation :)
[12:00:42] trautwein: has joined #RubyOnRails
[12:00:56] workmad3: although some API protocols (like SOAP) will route everything over POST and basically go 'screw you' to HTTP
[12:01:06] norc: universa1: I guess I should just make sure that the bulk operation is atomic.
[12:01:40] norc: workmad3: We started migrating everything to REST APIs :)
[12:01:44] norc: Much less headache.
[12:02:59] norc: workmad3: But you have a point. I mean I have been using all HTTP verbs in ajax for a while now, so I should know better that the browser itself supports them without a problem.
[12:03:35] yardenbar: has joined #RubyOnRails
[12:06:37] rikkipitt: has joined #RubyOnRails
[12:07:45] rikkipitt: hey guys, I'm using a paid (expensive) API to get data. It is quite a massive set of nested data. Should I just save the response JSON as serialised and access data from it later?
[12:07:54] vasilakisfil_: has joined #RubyOnRails
[12:08:10] rikkipitt: Creating each sub model will take a long time as there are loads of columns...
[12:08:44] sundhell: has joined #RubyOnRails
[12:08:57] jhass: sure why not (that is you didn't give any reason not to and we aren't wizards who magically know your problem and the best solution to it)
[12:09:20] nzst: has joined #RubyOnRails
[12:09:21] emilkarl: universa1: I changed from an after_save (which triggers) to an after_commit on the same command. But that never runs.
[12:09:33] universa1: emilkarl: !code
[12:09:33] helpa: emilkarl: We cannot help you with your problem if you don't show us your code. Please put it on http://gist.github.com and give us the URL so we can see it.
[12:09:36] norc: rikkipitt: The beautiful thing is JSON can be written directly to a file. :-)
[12:09:56] rikkipitt: oooh, good idea!
[12:10:03] rikkipitt: thanks norc
[12:10:04] norc: rikkipitt: It already is a serialization format. :-)
[12:10:59] bronson: has joined #RubyOnRails
[12:10:59] rikkipitt: norc: then I can use the file as an endpoint instead of the paid one
[12:12:08] tagrudev: has joined #RubyOnRails
[12:12:55] jkamenik: has joined #RubyOnRails
[12:15:12] atomical: has joined #RubyOnRails
[12:15:45] emilkarl: universa1: http://pastie.org/10456031
[12:15:48] brunoalano: has joined #RubyOnRails
[12:16:08] emilkarl: when the workout saves. it will create an recurring_rule as well.
[12:16:34] brunoalano: What are the most essentials type of test in a RoR project? Probably all of them, but I don't have enough time to do all, so, I've made the Unit Test, and what more?
[12:16:38] emilkarl: when the recurring_rule commits i would like it to trigger RecurringRule:: update_recurrences
[12:17:24] emilkarl: on after_save it works but the custom values on the workout isnt created yet so I cannot duplicate them on to the duplicates
[12:17:41] tbuehlmann: brunoalano, integration tests, since they test your whole application/stack
[12:17:48] quazimodo: has joined #RubyOnRails
[12:18:23] brunoalano: tbuehlmann: thanks
[12:18:57] tbuehlmann: not sure if "most essential", but you get the most out of it per time, I'd say
[12:19:46] ahmgeek_: has joined #RubyOnRails
[12:19:57] itkin: has joined #RubyOnRails
[12:20:55] Prira: has joined #RubyOnRails
[12:22:25] FailBit: len = len(str( abs(int(he)) ))
[12:22:30] FailBit: programmer humor
[12:23:20] emilkarl: this could be my problem too? http://stackoverflow.com/questions/13084482/rails-does-not-fire-my-after-commit-callback
[12:23:26] dionysus69: has joined #RubyOnRails
[12:23:57] emilkarl: Using 4.1.10
[12:24:30] universa1: emilkarl: so you're seeing the misbehavior in a test?
[12:24:47] emilkarl: the test works but without the custom values saved.
[12:24:54] emilkarl: changed to after_commit the test fails
[12:25:13] emilkarl: test for CustomValue duplicates fails in both cases.
[12:25:20] ruurd: has joined #RubyOnRails
[12:25:33] rvanlieshout: FailBit: shouldn't 'he' have a value?
[12:25:35] universa1: emilkarl: ok
[12:25:46] universa1: emilkarl: http://api.rubyonrails.org/classes/ActiveRecord/Transactions/ClassMethods.html#method-i-after_commit
[12:25:47] arup_r: has joined #RubyOnRails
[12:26:17] emilkarl: test_after_commit
[12:26:40] universal: has joined #RubyOnRails
[12:26:51] A124: has joined #RubyOnRails
[12:26:52] universal: emilkarl: Note that transactional fixtures do not play well with this feature. Please use the test_after_commit gem to have these hooks fired in tests. ;)
[12:27:37] michael_mbp: has joined #RubyOnRails
[12:28:01] emilkarl: installed the gem
[12:28:13] yardenbar: has joined #RubyOnRails
[12:28:31] emilkarl: hmm cool. seems like the tests run fine now!
[12:28:41] emilkarl: thanks universal
[12:28:51] emilkarl: have to try it in the app as well
[12:29:07] michael_mbp: has joined #RubyOnRails
[12:29:18] universa1: has joined #RubyOnRails
[12:29:28] itkin: has joined #RubyOnRails
[12:32:17] bitkiller: has joined #RubyOnRails
[12:34:28] sundhell: has joined #RubyOnRails
[12:35:43] paulcsmith: has joined #RubyOnRails
[12:38:24] youngbaks: has joined #RubyOnRails
[12:40:49] srinidhi: has joined #RubyOnRails
[12:41:36] dnewkerk: has joined #RubyOnRails
[12:42:41] kitsuneyo: has joined #RubyOnRails
[12:43:04] stannard: has joined #RubyOnRails
[12:44:02] kitsuneyo: i was just wondering... is there any real difference between a helper file and a file created specifically to contain a module? besides helpers being auto-generated and linked to a module?
[12:44:53] kitsuneyo: a helper is just a file with a module in it, right?
[12:45:18] annlewis: has joined #RubyOnRails
[12:45:31] darkhex: has joined #RubyOnRails
[12:45:38] dionysus70: has joined #RubyOnRails
[12:46:42] kitsuneyo: is it safe to delete some helper files if they're empty?
[12:47:34] kitsuneyo: thanks rvanlieshout
[12:47:59] wpp: has joined #RubyOnRails
[12:48:50] brunoalano: Anyone have a good sample structure of integration test?
[12:49:40] wpp: Helo everybody. I'm using paperclip and would like to know if I can set a filename (overwrite the original filename). I found this link but it's from 2009 (https://trevorturk.wordpress.com/2009/03/22/randomize-filename-in-paperclip/)
[12:51:24] wpp: What about monkeypatching this method? https://github.com/thoughtbot/paperclip/blob/7a085d300e510c4fda076e1a77e59ceabad7e2cf/lib/paperclip/attachment.rb#L594
[12:51:40] wpp: and just return "default.png"? Is that a bad idea?
[12:51:54] kitsuneyo: has joined #RubyOnRails
[12:51:55] Fahrenhei7: has joined #RubyOnRails
[12:52:49] northfurr: has joined #RubyOnRails
[12:53:26] dionysus70: has joined #RubyOnRails
[12:55:27] sadaf2606: has joined #RubyOnRails
[12:56:14] yardenbar: has joined #RubyOnRails
[12:56:49] siaW: has joined #RubyOnRails
[12:56:52] universal: has left #RubyOnRails: ("Verlassend")
[12:59:57] dici: has joined #RubyOnRails
[13:00:24] _el_fer_: has joined #RubyOnRails
[13:03:47] yardenbar: has joined #RubyOnRails
[13:04:26] Jon__: has joined #RubyOnRails
[13:04:35] monq: has joined #RubyOnRails
[13:05:47] linus4: has joined #RubyOnRails
[13:05:49] bmurt: has joined #RubyOnRails
[13:06:44] rushed: has joined #RubyOnRails
[13:07:05] sinkensabe: has joined #RubyOnRails
[13:07:05] htmldrum: has joined #RubyOnRails
[13:08:15] The_Phoenix: has joined #RubyOnRails
[13:09:19] umgrosscol: has joined #RubyOnRails
[13:10:47] hackeron: has joined #RubyOnRails
[13:11:05] jgpawletko: has joined #RubyOnRails
[13:11:56] bronson: has joined #RubyOnRails
[13:11:57] allcentury: has joined #RubyOnRails
[13:12:01] Detch: has joined #RubyOnRails
[13:13:01] fmcgeough: has joined #RubyOnRails
[13:14:48] symbole: has joined #RubyOnRails
[13:17:45] bronson: has joined #RubyOnRails
[13:18:08] SeanLazer: has joined #RubyOnRails
[13:19:05] jun_: has joined #RubyOnRails
[13:20:29] TvL2386: has joined #RubyOnRails
[13:22:35] bejar37: has joined #RubyOnRails
[13:23:08] Jasaka: has joined #RubyOnRails
[13:24:42] moeabdol: has joined #RubyOnRails
[13:25:19] cih: has joined #RubyOnRails
[13:27:26] brunoalano: I've a model that implements Devise called Account, how can I use STI (or something else) in models called User and Employee? I'm creating a route to authenticate Employee and other for Users, but I don't want to mantain 2 email fields
[13:28:20] Fire-Dragon-DoL: has joined #RubyOnRails
[13:28:46] zmd: has left #RubyOnRails: ()
[13:29:21] dmz: has joined #RubyOnRails
[13:29:21] dmz: has joined #RubyOnRails
[13:30:40] iamjarvo_: has joined #RubyOnRails
[13:30:44] universa1: brunoalano: why do you need different authentication routes if they are all accounts?
[13:31:23] brunoalano: universal: Because Employees will see the Dasboard and Users will se the content pages (like a CMS)
[13:31:38] universa1: brunoalano: so redirect after login to the proper page?
[13:32:00] brunoalano: universal: I think that the routes will be more organized for something like: dashboard/auth/sign_in
[13:32:19] brunoalano: But if doesn't exists a good way to do that, I will create one route for authentication and then redirect
[13:32:34] universa1: can an account be an employee and an user?
[13:32:50] brunoalano: But what I'm trying to do it's `devise_for :employees`, look more organized
[13:32:52] brunoalano: universal: Yes
[13:33:26] brunoalano: universal: But Employees has roles, User's has other associations, this is why I've created 3 models (Account, User and Employee)
[13:33:40] brunoalano: universal: Because keeping NULL fields for these records isn't a good pratice
[13:34:26] universa1: brunoalano: so account belongs_to user and employee?
[13:34:29] kitsuneyo: has joined #RubyOnRails
[13:34:59] brunoalano: Account has_one User, and Account has_one Employee (XOR). User belongs_to Account. Employee belongs_to Account. Both validates_presence_of :account
[13:35:37] universa1: brunoalano: so if an account logs in, it is 100% clear if you need to redirect to the dashboard or the content pages...
[13:36:10] universa1: brunoalano: so a simple: if current_account.user?; redirect_to dashboard_url; else redirect_to content_pages_url; end will do
[13:36:28] universa1: no need for much code, no need for additional routes, simple, clean and only 3 lines of code ;)
[13:36:44] universa1: this is my personal approach
[13:37:30] siaW: has joined #RubyOnRails
[13:38:01] krz: has joined #RubyOnRails
[13:38:06] mary5030: has joined #RubyOnRails
[13:38:44] rickmasta: has joined #RubyOnRails
[13:38:58] jhass: I'd probably flip the association and make it polymorphic, Account belongs_to :holder, polymorphic: true, User has_one :account, source: :holder, Employee has_one :account, source: :holder, redirect_to account.holder.after_sign_in_path
[13:40:00] jhass: but that'll require a few more structural changes especially around your account creation
[13:41:06] ddv: how do you delete in memory activerecord objects? for example how do I delete all lines that have an empty amount @order.lines? preferably inside a before_safe
[13:41:24] paulcsmith: has joined #RubyOnRails
[13:41:51] paulcsmith: has joined #RubyOnRails
[13:41:52] A124: has joined #RubyOnRails
[13:42:24] brunoalano: universal: Thanks for that tip
[13:42:33] devdazed: has joined #RubyOnRails
[13:42:56] thejamespinto: has joined #RubyOnRails
[13:43:56] paulcsmith: has joined #RubyOnRails
[13:44:28] broman: has joined #RubyOnRails
[13:44:42] DLSteve: has joined #RubyOnRails
[13:45:20] broman: can someone please help me? Im using rails 3.. i had an ajax form that used to work.. i converted it to html form and now I'm getting the WARNING: Can't verify CSRF token authenticity ... what should i add to my form body so it works?
[13:45:22] ddv: ah found it
[13:45:23] Trynemjoel: has joined #RubyOnRails
[13:45:54] annlewis: has joined #RubyOnRails
[13:46:08] ramortegui: has joined #RubyOnRails
[13:46:46] jhass: broman: use the form_for or form_tag helper to build your form
[13:46:57] mary5030: has joined #RubyOnRails
[13:47:17] broman: just got it! <%= hidden_field_tag :authenticity_token, form_authenticity_token %>
[13:47:40] jhass: which form_for & form_tag will add automatically for you
[13:48:54] kitsuneyo: has joined #RubyOnRails
[13:50:39] Axilla: been using rails everyday for years, and i learn about new auto magic stuff almost everyday it feels like. using a blogging engine in our marketing page i wanted to share the nav partial from the main app with the engine, but the engine needed access to the main app drawn path's.. main_app helper 4tw :)
[13:51:08] Axilla: never knew it existed =/
[13:51:51] qejk: has joined #RubyOnRails
[13:53:17] stannard: has joined #RubyOnRails
[13:54:20] stannard: has joined #RubyOnRails
[13:56:30] broman: Now I have another problem... After my controller saves the post, i need it to redirect to the :index... I'm using the redirect_to but it still gives me error of template missing... I know that the template is missing but I don't want to use this.. i need the redirection to other page
[13:56:31] sanjayu: has joined #RubyOnRails
[13:57:25] broman: forget about it! i just got :)
[14:00:45] TPBallbag: has joined #RubyOnRails
[14:01:40] dionysus69: has joined #RubyOnRails
[14:07:05] darrencauthon: has joined #RubyOnRails
[14:07:14] atrius: has joined #RubyOnRails
[14:07:27] a1fa: is there a difference between .each and find_each?
[14:08:18] herbst: afaik find_each will not load the whole dataset to ram, while each does
[14:08:22] universa1: each is a ruby#enumerable method
[14:08:24] herbst: but i could be fully wrong
[14:08:26] universa1: find_each is one from rails
[14:08:33] arup_r: alfa: It depends who implemented it.. source please.. :)
[14:08:47] universa1: a1fa: http://api.rubyonrails.org/
[14:08:48] a1fa: looping through activerecord .where
[14:08:57] universa1: http://api.rubyonrails.org/classes/ActiveRecord/Batches.html#method-i-find_each
[14:08:59] universa1: this one actually.
[14:09:06] dionysus69: has joined #RubyOnRails
[14:09:10] a1fa: so use find_each vs .each
[14:09:35] rikkipitt: has joined #RubyOnRails
[14:09:41] arup_r: herbst: Nah.. you are ok :) find_each is batch kind of thing
[14:09:49] arup_r: it loads data in a chunk
[14:10:02] uris: has joined #RubyOnRails
[14:10:28] herbst: arup_r: thanks for confirming :)
[14:10:48] a1fa: cool, thank you guys and gals
[14:11:05] banister: has joined #RubyOnRails
[14:11:19] a1fa: i've used both each and find_each with AR.. but looks like find_each is more appropriate in that case
[14:12:19] a1fa: when doing .when is it more appropriate to do .when(field: somevar) or .when("field = ?", somevar)
[14:14:01] bejar37: has left #RubyOnRails: ("Textual IRC Client: www.textualapp.com")
[14:14:11] apg: has joined #RubyOnRails
[14:14:31] herbst: usually you do the first, you'll notice when you run in a case where you need the latter
[14:14:40] greengriminal: has joined #RubyOnRails
[14:14:47] a1fa: i have not had my double shot of espresso yet
[14:14:57] yaewa: has joined #RubyOnRails
[14:15:21] a1fa: herbst: isn't that always the case ;)
[14:15:26] SteenJobs: has joined #RubyOnRails
[14:15:27] apg: has joined #RubyOnRails
[14:15:27] apg: has joined #RubyOnRails
[14:15:36] a1fa: herbst: so it's more appropriate to use the later?
[14:15:54] herbst: no the first .where(field: search) is the standard basically
[14:16:16] herbst: i only use the latter when i do for example: .where("field LIKE ?", "%search%")
[14:16:26] a1fa: just trying to prevent any possibility of sql injection
[14:16:37] sinkensabe: has joined #RubyOnRails
[14:16:40] emilkarl: has joined #RubyOnRails
[14:16:41] herbst: afaik both would be ok in that case
[14:16:46] a1fa: much obliged
[14:16:59] atrius: has joined #RubyOnRails
[14:17:01] sinkensabe: has joined #RubyOnRails
[14:17:17] kitsuneyo: has joined #RubyOnRails
[14:18:07] DEA7TH: has joined #RubyOnRails
[14:19:39] chipotle: has joined #RubyOnRails
[14:19:46] TPBallbag: Hi all. I've always used CanCan for authorization. Just checking in to see if anybody has worked with other authorization gems too and which they preferred?
[14:20:08] universa1: TPBallbag: cancancan and pundit are the popular ones currently i guess, check ruby-toolbox.com
[14:21:23] tetraktys: has joined #RubyOnRails
[14:22:15] pjammer: has joined #RubyOnRails
[14:24:08] AskThatDude: has joined #RubyOnRails
[14:24:43] AskThatDude: has joined #RubyOnRails
[14:26:56] hightower4: has joined #RubyOnRails
[14:28:53] chills42: has joined #RubyOnRails
[14:30:06] sarink: has joined #RubyOnRails
[14:30:29] sarink: has joined #RubyOnRails
[14:35:33] dionysus69: has joined #RubyOnRails
[14:40:22] sanjayu: has joined #RubyOnRails
[14:41:20] lasker85: has joined #RubyOnRails
[14:42:51] mdel: has joined #RubyOnRails
[14:43:10] habitullence: universa1: where you helping me out with that scoping thing earlier?
[14:43:22] habitullence: I got distracted :P
[14:44:43] habitullence: I ended up with.. I currently have.. where(arel_table[:iso].eq('BRA').and(Arel::Nodes::NamedFunction.new('st_contains', [arel_table[:geom], Site.arel_table[:lonlat]])))
[14:44:50] bruno-: has joined #RubyOnRails
[14:45:01] habitullence: Just need to add sites table to the from this generates and should be there
[14:46:17] TheWhiteOx: has joined #RubyOnRails
[14:46:52] annlewis: has joined #RubyOnRails
[14:46:58] FailBit: 3.6k RPM, ??RT=95ms
[14:47:03] FailBit: we has gud scale
[14:47:34] jkamenik1: has joined #RubyOnRails
[14:48:18] h7br1x: has joined #RubyOnRails
[14:48:21] arup_r: someone created a HABTM table in my project without applying id: false in the migration https://gist.github.com/aruprakshit/f1722d0b04e40dc7f18d .. If I drop the id column now, is it fine ? Or should I drop the whole table and then add the table again with a new migration
[14:48:45] chouhoulis: has joined #RubyOnRails
[14:49:22] davidt: has joined #RubyOnRails
[14:50:25] h7br1x: has joined #RubyOnRails
[14:50:55] arup_r: that migration is for HABTM
[14:51:01] arup_r: so id is not needed
[14:51:59] Abhijit: has joined #RubyOnRails
[14:52:13] Abhijit: i can call @current_user in my model right? after installng devise?
[14:52:26] tubbo: arup_r: is there data in the id column?
[14:52:38] arup_r: It is in my local machine
[14:52:46] arup_r: I am implementing the feature
[14:52:52] arup_r: in local I have yes
[14:52:59] Abhijit: arup_r, sorry I mean in my controller. i am calling it there to iincrease value of one column and iit gives nil class error
[14:53:08] arup_r: I found just some time before as I was facing some issue
[14:53:22] arup_r: in controller you have
[14:53:47] Abhijit: arup_r, @current_user.totalpets = @current_user.totalpets.increment!(:ads_counter)
[14:53:48] arup_r: abhijit: ^^
[14:54:00] arup_r: show the error
[14:54:03] Abhijit: undefined method `totalpets' for nil:NilClass
[14:54:26] Abhijit: we need that only in views?
[14:54:27] arup_r: it is a helper
[14:54:40] Abhijit: but i am doing same @ in another controller and there it works?
[14:54:44] arup_r: current_user and @current_user is not the same thing
[14:55:00] arup_r: you are using Devise right ?
[14:55:17] Abhijit: arup_r, which is what? i am confused.
[14:55:19] stardiviner: has joined #RubyOnRails
[14:55:20] arup_r: tubbo: advise ?
[14:55:28] Abhijit: arup_r, in other controller i am doing @totalpets = @current_user.totalpets and it works. no error
[14:55:44] tubbo: arup_r: if you have data in the id column, then no it's not fine
[14:55:47] tubbo: because you'd be deleting data
[14:55:47] Abhijit: arup_r, yes
[14:56:13] tubbo: abhijit: you shouldn't be calling current_user like that anyway, there's a method for it.
[14:56:32] tubbo: abhijit: you shouldn't be accessing readers through their respective ivars. what happens if devise wants to change the ivar to @_current_user? your code breaks.
[14:56:40] tubbo: but they won't change the public method
[14:58:25] DEA7TH: has joined #RubyOnRails
[14:58:31] arup_r: tubbo: so what I will do ?
[14:59:15] tubbo: arup_r: ??\_(???)_/??
[14:59:22] njero: has joined #RubyOnRails
[14:59:36] arup_r: I mean drop the full table.. :D
[14:59:39] KanoTheDev: how should i ask for newly created field? http://pastie.org/private/bsrzhbzwxib96hqkana1a
[14:59:41] arup_r: or just theid
[14:59:54] TheWhiteOx: has joined #RubyOnRails
[15:00:02] tubbo: arup_r: well if you write migrations to drop tables and columns with data in them, you will lose that data. thought this was common sense.
[15:00:17] tubbo: arup_r: so it depends on how much data you want to lose, all of it or just a column :{
[15:00:27] tubbo: KanoTheDev: you could start by asking nicely
[15:00:37] deavid: has joined #RubyOnRails
[15:00:51] habitullence: Anyone know how to add tables to from clause in arel?
[15:00:52] arup_r: tubbo: it is in my dev machine...
[15:01:02] arup_r: not yet pushed
[15:01:03] bronson: has joined #RubyOnRails
[15:01:49] tubbo: arup_r: when i was referring to data, i meant the data on a shared server somewhere (like prod or staging), your dev server's data is expendable
[15:02:08] tubbo: but your staging and especially prod data is not
[15:02:21] shevy: has joined #RubyOnRails
[15:02:37] tubbo: habitullence: whatever you're doing looks cool but i have no idea :P
[15:03:21] habitullence: hey tubbo... neither do I ;P
[15:05:06] Abhijit: has joined #RubyOnRails
[15:05:12] Abhijit: arup_r, ii was diisconnected.
[15:05:21] Abhijit: any idea on why @ works in other controller but not this controller?
[15:05:34] Abhijit: also i cant do current_user.totalpets = current_user.totalpets + 1 in controller save action?
[15:05:34] habitullence: tubbo: I basically have poly geom in one table and point geom in another, I'm trying to say get me all points for whatever polygons, i.e., multi-model scope. Does that make any sense? :S
[15:05:49] arup_r: I have DistributionList and User with HABTM
[15:06:07] arup_r: and now the thing is one side is working .. and other ise not
[15:06:08] tubbo: abhijit: you shouldn't use instance variables to access current_user.
[15:06:11] moeabdol: has joined #RubyOnRails
[15:06:17] arup_r: https://gist.github.com/aruprakshit/f1722d0b04e40dc7f18d
[15:07:31] relix: has joined #RubyOnRails
[15:07:43] arup_r: this is crazy
[15:07:53] arup_r: I felt ID causing this..
[15:08:00] Bilbo-baggons: has joined #RubyOnRails
[15:08:29] Abhijit: tubbo, so in that other controller where @ is workisg there also i shoud remove it right?
[15:08:29] Abhijit: tubbo, also how to increase the value of column in save action?
[15:08:37] arup_r: abhijit: yes
[15:08:44] arup_r: not needed
[15:08:55] tubbo: abhijit: !vague
[15:08:55] helpa: abhijit: Your question has just been deemed vague; please consider rewording it. It may also help to give us any relevant code or errors so that we may better assist you.
[15:08:56] Abhijit: arup_r, thanks. also any idea how can i correct current_user.totalpets = current_user.totalpets + 1
[15:09:04] naftilos76: has joined #RubyOnRails
[15:09:15] _el_fer_: has joined #RubyOnRails
[15:09:16] Cervajz: has joined #RubyOnRails
[15:09:18] Abhijit: tubbo, current_user.totalpets = current_user.totalpets + 1 do not update the value in database.
[15:09:28] arup_r: you need to call save
[15:09:36] Abhijit: but no errors from raiils.
[15:09:39] tubbo: yeah or update_attributes
[15:09:45] ramfjord: has joined #RubyOnRails
[15:09:55] tubbo: though i think user.pets += 1
[15:09:56] tubbo: and then user.save
[15:09:57] lasker85: has joined #RubyOnRails
[15:09:58] tubbo: works better
[15:10:01] tubbo: err, looks better*
[15:10:02] arup_r: what is totalpelts ? column ?
[15:10:12] Abhijit: yes a column
[15:10:22] arup_r: well .. see the magic
[15:10:31] arup_r: current_user.increment! :totalpets
[15:10:36] arup_r: you are done
[15:10:46] arup_r: check the spelling.. :) I might be wronf
[15:10:57] Abhijit: thanks arup_r and tubbo . save work.s
[15:11:10] Abhijit: arup_r, does increment needs .save too or not?
[15:11:26] Abhijit: thanks all. bye.
[15:11:45] arup_r: tubbo: why my one side is working.. what happened to the other side ?
[15:12:19] tubbo: arup_r: what are you talking about? id isn't even being used, you're spinning your wheels about a problem that doesn't even exist.
[15:12:45] arup_r: tubbo: That was a guess.. might that caused it..
[15:12:58] arup_r: I am not seeing any reason why it is not workigng
[15:13:09] tubbo: arup_r: it's just an extra column on the table that probably isn't being used, but what i'm trying to tell you is GO ON THE PRODUCTION SERVER and query the DB to make sure that if you do any deletion of a column or table, data won't be lost...
[15:13:23] IFrank00: has joined #RubyOnRails
[15:13:41] arup_r: Ok. I have no access there.. But I can ask to check them..
[15:13:49] arup_r: if they say we have no data.. then ?
[15:13:50] tubbo: arup_r: that's probably a good thing ;)
[15:13:56] arup_r: can I drop ?
[15:13:59] IFrank00: has left #RubyOnRails: ()
[15:14:00] tubbo: arup_r: yeah, definitely.
[15:14:02] arup_r: and recreate it
[15:14:08] erichu: has joined #RubyOnRails
[15:14:14] arup_r: if they say we have data then ? :(
[15:14:17] kitsuneyo: has joined #RubyOnRails
[15:14:19] arup_r: let be like that...
[15:15:14] arup_r: tubbo: My guess is correct.. see why it is giving [] on the other side..
[15:15:21] arup_r: look the query.. SELECT "distribution_lists".* FROM "distribution_lists" INNER JOIN "distribution_lists_users" ON "distribution_lists"."id" = "distribution_lists_users"."distribution_list_id"
[15:15:34] arup_r: it is taking the id of the join table.. and trying to do some shit
[15:16:58] sanjayu: has joined #RubyOnRails
[15:17:42] ruurd: has joined #RubyOnRails
[15:18:21] moeabdol: has joined #RubyOnRails
[15:19:21] KanoTheDev: has joined #RubyOnRails
[15:19:24] h7br1x: has joined #RubyOnRails
[15:20:06] jkamenik: has joined #RubyOnRails
[15:20:29] DEA7TH_: has joined #RubyOnRails
[15:21:16] apg: has joined #RubyOnRails
[15:21:23] rubyonrails241: has joined #RubyOnRails
[15:22:04] j_mcnally: has joined #RubyOnRails
[15:22:30] TheWhiteOx: has joined #RubyOnRails
[15:22:37] njero: has joined #RubyOnRails
[15:24:11] sanjayu: has joined #RubyOnRails
[15:25:22] disgrntld: has joined #RubyOnRails
[15:25:30] KinderSpiel: has joined #RubyOnRails
[15:25:33] highcup: has joined #RubyOnRails
[15:25:53] chills42_: has joined #RubyOnRails
[15:26:54] bruno-: has joined #RubyOnRails
[15:27:13] EminenceHC: has joined #RubyOnRails
[15:28:20] pjammer: has joined #RubyOnRails
[15:28:51] moeabdol: has joined #RubyOnRails
[15:28:52] youngbaks: has joined #RubyOnRails
[15:29:03] KinderSpiel: whats up, who's here?
[15:29:03] seank_: has joined #RubyOnRails
[15:30:13] kitsuneyo: has joined #RubyOnRails
[15:31:09] ldnunes: has joined #RubyOnRails
[15:31:56] bruno-: has joined #RubyOnRails
[15:32:43] Lytol: has joined #RubyOnRails
[15:33:24] FCser: has joined #RubyOnRails
[15:33:31] j_mcnally: has joined #RubyOnRails
[15:34:23] KinderSpiel: arup_r awesome
[15:34:40] KinderSpiel: arup_r do you happen to know some railties by any chance?
[15:34:46] KinderSpiel: I'm looking for some help
[15:34:57] KinderSpiel: general question in changing rails versions
[15:35:11] arup_r: U just ask.. someone will help you for sure
[15:35:15] KinderSpiel: gist right here: https://gist.github.com/anonymous/d7651b5e0fbb60d3fe9c
[15:35:28] KinderSpiel: I'd like to use a more recent version of rails, but it doesn't seem to work
[15:36:13] KinderSpiel: the original code must have been written at about the time rails 2 came out
[15:36:56] symbol: has joined #RubyOnRails
[15:36:57] arup_r: nah.. i started from 4.. :( so I wouldn't be helpful
[15:37:20] KinderSpiel: arup_r maybe you would
[15:37:40] KinderSpiel: Do you know Rails4 generators?
[15:38:07] KinderSpiel: I'm trying to create an object, but Rails::Generators::Actions.new gives me "undefined method `new'"
[15:38:35] KinderSpiel: how can I create an action and run a generate command, that's about it...
[15:38:37] nzst: KinderSpiel: http://www.rubydoc.info/docs/rails/4.1.7/Rails/Generators/Actions
[15:40:53] Or1on: has joined #RubyOnRails
[15:41:03] KinderSpiel: nzst thanks but .generate is in "Instance Method Summary"
[15:41:25] KinderSpiel: nzst which would point to creating an object first, no?
[15:41:44] nzst: yea, i would think so
[15:42:20] EminenceHC: has joined #RubyOnRails
[15:42:25] KinderSpiel: nzst I'm trying to create an object, but Rails::Generators::Actions.new gives me "undefined method `new'"
[15:43:03] KinderSpiel: I had read the docs before, and looked everywhere for blog posts and tutorials, but generators look like a dying breed, maybe it wasn't the best thought out design
[15:43:08] sonofdirt: has joined #RubyOnRails
[15:43:19] KinderSpiel: nobody seems to care for them
[15:43:53] KinderSpiel: they're just glorified batch files anyway
[15:43:53] nzst: so it's a module, not a class, I think you need to include the module into a class
[15:44:09] KinderSpiel: nzst yeah, got that
[15:44:29] KinderSpiel: I included rails/generators and rails/generators/actions
[15:44:41] kitsuneyo: has joined #RubyOnRails
[15:45:24] KinderSpiel: nzst what I want to run is something like Rails::Generators::Actions.generate(args, options), or something else that does the job, really
[15:45:28] Jerrod: has joined #RubyOnRails
[15:45:33] habitullence: Does anyone know how to use arel project in activerecord scope?
[15:47:01] habitullence: or how to turn selectmanager into scope
[15:47:37] annlewis: has joined #RubyOnRails
[15:48:38] chouhoulis: has joined #RubyOnRails
[15:49:33] KinderSpiel: or if someone can point me out to a blog post or whatnot that shows an Action object being used, I'd really appreciate
[15:50:02] ruurd: has joined #RubyOnRails
[15:50:36] TheWhiteOx: has joined #RubyOnRails
[15:51:28] Ergo: has joined #RubyOnRails
[15:51:39] nzst: Did you dig into the source at all? https://github.com/rails/rails/tree/82ed33e4ba7d76f35b80f81441fa6356c9c9352d/railties/lib/rails/generators
[15:52:07] treehug88: has joined #RubyOnRails
[15:53:03] KinderSpiel: I did, actually
[15:53:10] habitullence: ok geniuses, how do you change select in a scope?
[15:53:40] KinderSpiel: you can see that the problem is well beyond the call to the Action object
[15:54:16] KinderSpiel: strangest thing is, sometimes the Action object doesn't have the generate method, which stumps me
[15:54:18] ruurd: has joined #RubyOnRails
[15:54:50] nzst: KinderSpiel: you can see the place where behavior method is called here https://github.com/rails/rails/blob/82ed33e4ba7d76f35b80f81441fa6356c9c9352d/railties/lib/rails/generators/actions.rb#L254
[15:55:06] towski_: has joined #RubyOnRails
[15:55:17] nzst: I was creating an object like so http://hastebin.com/uhaniyedas.rb
[15:56:17] KinderSpiel: nzst sorry, "application error"
[15:56:41] KinderSpiel: nzst I had seen the call to behavior too
[15:57:06] bricker: has joined #RubyOnRails
[15:57:52] moei: has joined #RubyOnRails
[15:58:10] KinderSpiel: nzst the code I'm trying to migrate comes from here: https://github.com/branch14/modeldrivenrails
[15:59:27] KinderSpiel: in the file lib/model_driven/design.rb
[15:59:29] kidoz: has joined #RubyOnRails
[16:02:29] bronson: has joined #RubyOnRails
[16:02:51] nfk: has joined #RubyOnRails
[16:03:07] Maletor: has joined #RubyOnRails
[16:05:34] chipotle: has joined #RubyOnRails
[16:05:49] ruurd: has joined #RubyOnRails
[16:05:53] habitullence: Anyone know how to use arel project in scopes?
[16:06:23] smathy: habitullence, same as using arel outside of scopes.
[16:06:52] DEA7TH: has joined #RubyOnRails
[16:07:07] habitullence: hi smathy, when I use project(...) I don't get records but arel::selectmanager returned
[16:07:29] smathy: habitullence, !gist what you're trying
[16:07:29] helpa: habitullence: http://gist.github.com - Put your codes online with pretty syntax highlighting and the ability to embed it into other pages.
[16:08:03] arup_r: 2 models User and DistributionList are connected through HABTM .. but then when I am not able to save data
[16:08:08] Fahrenhei7: has joined #RubyOnRails
[16:08:10] arup_r: https://gist.github.com/aruprakshit/6284c59977325c62cd27
[16:08:22] arup_r: s/when/why?
[16:08:36] habitullence: thanks smathy, https://gist.github.com/habitullence/8e4aa3bfcbbc7c1ba31d
[16:10:31] KanoTheDev: has joined #RubyOnRails
[16:10:36] dopie: has joined #RubyOnRails
[16:10:59] arooni: has joined #RubyOnRails
[16:11:46] KinderSpiel: nzst what do you think I should do?
[16:12:09] KinderSpiel: It's getting to be really hard to find any help with these generators
[16:12:25] arBmind1: has joined #RubyOnRails
[16:12:28] habitullence: smathy, I basically need to add sites to from clause
[16:12:55] kitsuneyo: has joined #RubyOnRails
[16:13:42] _djbkd: has joined #RubyOnRails
[16:16:03] smathy: habitullence, you're trying to put a scope in AdminBound that returns a collection of Sites?
[16:16:44] habitullence: should the scope be on sites?
[16:16:54] habitullence: and I pass in adminbound or something?
[16:17:17] smathy: habitullence, well, what SQL are you trying to construct here?
[16:17:44] habitullence: smathy, SELECT * FROM public.sites, public.gadm WHERE public.gadm.iso = 'BRA' AND st_contains(gadm.geom, sites.lonlat::geometry)
[16:18:41] habitullence: gadm changed to adminbonuds
[16:19:01] momomomomo: has joined #RubyOnRails
[16:19:10] habitullence: SELECT * FROM public.sites, public.admin_bounds WHERE public.admin_bounds.iso = 'BRA' AND st_contains(admin_bounds.geom, sites.lonlat::geometry)
[16:20:00] smathy: habitullence, and you understand what selecting from two tables returns?
[16:20:57] habitullence: smathy, a join I think
[16:21:03] arBmind: has joined #RubyOnRails
[16:21:18] smathy: habitullence, no.
[16:21:32] smathy: habitullence, it just produces a record for every combination of the two tables.
[16:21:32] habitullence: just all the records?
[16:22:11] arup_r: I have.. but why error ? ActiveModel::MissingAttributeError (can't write unknown attribute `distribution_list_id`):
[16:22:14] habitullence: smathy, so is my query badly formed?
[16:22:21] smathy: habitullence, well it is if you want a join.
[16:22:39] habitullence: I just want all the points for the admin_bound
[16:22:54] newdan: has joined #RubyOnRails
[16:22:56] smathy: habitullence, you're going to get every combination of the records of the two tables, so you'll get # of records in sites TIMES # records in admin_bounds
[16:23:02] newdan: has left #RubyOnRails: ()
[16:23:18] smathy: habitullence, now, next question. Your scope is trying to project to `sites.*`
[16:23:23] KinderSpiel: Fellas, can someone here help me with my gist? https://gist.github.com/anonymous/d7651b5e0fbb60d3fe9c
[16:23:31] smathy: habitullence, and yet the SQL you said you wanted was just `SELECT * ...`
[16:24:02] habitullence: smathy, so really I should have the scope on sites and pass it the adminbound?
[16:24:08] stannard: has joined #RubyOnRails
[16:24:21] smathy: habitullence, yeah, I mean if you want Site objects then you should have the scope in your Site class.
[16:25:08] ramfjord: has joined #RubyOnRails
[16:25:17] cschneid_: has joined #RubyOnRails
[16:25:44] EminenceHC: has joined #RubyOnRails
[16:26:03] atomical_: has joined #RubyOnRails
[16:26:06] habitullence: smathy, that makes a lot more sense.. As I'm using two models should I create a service kind of object or would you just pass between the two?
[16:26:15] ruurd: has joined #RubyOnRails
[16:26:28] Pazician: has joined #RubyOnRails
[16:26:28] Pazician: has joined #RubyOnRails
[16:28:19] smathy: habitullence, you want to read this too: http://guides.rubyonrails.org/active_record_querying.html Especially relating to `joins`. I think my comment on your gist will work, but read up please.
[16:29:09] polishdub: has joined #RubyOnRails
[16:29:14] smathy: habitullence, I'm guessing that your association is a belong_to from Site to AdminBounds, change the `joins` to match whatever the association name is.
[16:29:33] ruurd: has joined #RubyOnRails
[16:29:55] habitullence: smathy, will do. So I can use joins without foreign keys?
[16:30:08] sonofdirt: has joined #RubyOnRails
[16:30:26] kitsuneyo: has joined #RubyOnRails
[16:31:02] smathy: habitullence, uhoh :) Ok, so actually start reading here: http://guides.rubyonrails.org/association_basics.html
[16:31:08] sonofdirt: has joined #RubyOnRails
[16:31:37] habitullence: lol thanks smathy :)
[16:32:01] arup_r: smathy: could you see my gist ?
[16:34:46] KinderSpiel: smathy, maybe you're the guy to help me out?
[16:35:20] KinderSpiel: what has replaced this call in recent Rails versions? --> Rails::Generator::Scripts::Generate.new.run(args, options)
[16:38:15] smathy: KinderSpiel, are you just guessing at the method signature for the .generate method?
[16:38:32] epitron: has joined #RubyOnRails
[16:39:34] smathy: arup_r, in DistributionList you have a has_many :users instead of a habtm
[16:39:46] n1lo: has joined #RubyOnRails
[16:40:00] TDJACR: has joined #RubyOnRails
[16:40:01] smathy: arup_r, and so it's looking for a corresponding distribution_list_id foreign key in the users table.
[16:40:12] arup_r: typo.......... makes me wild..
[16:41:22] kzsh: has joined #RubyOnRails
[16:41:36] ruurd: has joined #RubyOnRails
[16:41:40] arup_r: smathy: thanks
[16:41:50] kzsh: has left #RubyOnRails: ()
[16:43:05] cornerma1: has joined #RubyOnRails
[16:43:23] habitullence: smathy, association basics all looks pretty familiar, was there something in particular?
[16:44:24] KinderSpiel: smathy that principle of the least surprise surprised me here a bit
[16:44:34] KinderSpiel: smathy same thing though
[16:44:46] KinderSpiel: 4.2.4 @ 2.0.0Rails::Generators::Actions.generate(options.keys.first, args) NoMethodError: undefined method `behavior' for Rails::Generators::Actions:Module
[16:45:34] sarink: i have a file: lib/ldap.rb which looks like this: module InfoCenter module LDAP def self.create_client end end end now inside of models/user.rb i have the line: client = InfoCenter::LDAP.create_client and I get the error "uninitialized constant InfoCenter::LDAP"
[16:45:48] KinderSpiel: what is this "behavior" method and why is it getting stuck there?
[16:46:23] towski_: has joined #RubyOnRails
[16:47:27] nzst: has joined #RubyOnRails
[16:48:16] annlewis: has joined #RubyOnRails
[16:48:34] fragamus: has joined #RubyOnRails
[16:49:03] smathy: habitullence, well anyone who thinks they can associate records of two different tables without a foreign key needs to read it closer.
[16:49:19] blackmesa: has joined #RubyOnRails
[16:49:22] annlewis_: has joined #RubyOnRails
[16:50:02] chills42: has joined #RubyOnRails
[16:50:16] ipstatic: I have records with start and end date columns. I am trying to find records where the start and end dates are between a given time. For some reason I am having trouble coming up with the query to perform this. Anyone have any pointers?
[16:50:33] habitullence: smathy, I don't think that.. I was wondering if I can use postgis types as foreign keys if anything ;)
[16:51:05] TheWhiteOx: has joined #RubyOnRails
[16:51:10] habitullence: I'm going to look at that and also moving the scope definition :)
[16:51:30] jgt: has joined #RubyOnRails
[16:52:06] sarink: why can't i access my own lib modules inside of a model?
[16:53:28] cih: has joined #RubyOnRails
[16:54:32] smathy: KinderSpiel, so what happens if you run, in your shell: rails g associations associated_model User id:int login:string password:string
[16:55:43] smathy: habitullence, ok, as I'm sure you saw in the first guide I pointed you to, you can pass a full join string in your `joins` method, so you can join them however you need to, but you need to join them somehow.
[16:56:12] simplyianm: has joined #RubyOnRails
[16:56:27] j_mcnally: has joined #RubyOnRails
[16:56:45] momomomomo: sarink: !ask
[16:56:45] helpa: sarink: How to ask good questions and get great answers: http://www.mikeash.com/getting_answers.html
[16:56:50] cnk: has joined #RubyOnRails
[16:57:23] habitullence: smathy, thanks, I did. Just need to learn more about how postgis types work. Thanks for help, much appreciated :)
[16:57:36] smathy: sarink, the lib directory is not auto-loaded.
[16:57:45] kzsh: has joined #RubyOnRails
[16:58:18] sotojuan: has joined #RubyOnRails
[16:58:38] smathy: ipstatic, you want the start and end dates to be within a certain range? Or you want to find records where a given date falls between your start/end dates?
[16:59:07] ipstatic: @smathy: find records where a given date falls between the start/end dates
[16:59:17] KinderSpiel: smathy first time I ran it it hang my shell, had to kill the process
[16:59:31] KinderSpiel: smathy trying a second time
[17:01:23] bronson: has joined #RubyOnRails
[17:01:59] smathy: ipstatic, right, so something like where( "? BETWEEN start_date AND end_date", Date.today )
[17:02:01] ipstatic: @smathy: my end goal is to find records that overlapping in the same 1 minute increments. I have call records and would like to know the number of concurrent calls for any given minute
[17:02:30] stannard: has joined #RubyOnRails
[17:03:32] EminenceHC: has joined #RubyOnRails
[17:04:16] j_mcnally: has joined #RubyOnRails
[17:04:28] sanjayu: has joined #RubyOnRails
[17:04:46] crdpink2: has joined #RubyOnRails
[17:05:34] thsig: has joined #RubyOnRails
[17:05:38] KinderSpiel: smathy no luck still hangs on the shell, i have to kill the process
[17:05:47] thsig_: has joined #RubyOnRails
[17:05:47] crdpink2: has joined #RubyOnRails
[17:05:54] KinderSpiel: smathy this is the original code where I'm getting stuck on: https://github.com/branch14/modeldrivenrails/blob/master/lib/model_driven/design.rb
[17:05:54] rodfersou|lunch: has joined #RubyOnRails
[17:06:01] thsig_: has joined #RubyOnRails
[17:06:05] benlieb: has joined #RubyOnRails
[17:06:12] kzsh: has left #RubyOnRails: ("Leaving...")
[17:06:38] benlieb: How can I add a ???virtual??? atribute to my model so that it appears in to_json
[17:07:55] atmosx: if my route is this: borrowers GET /borrowers(.:format) borrowers#index ... what is the equivallent route I can in in my tests? :borrowers returns unknown route.
[17:08:38] siaW: has joined #RubyOnRails
[17:10:04] goobagar: has joined #RubyOnRails
[17:11:03] _djbkd: has joined #RubyOnRails
[17:11:40] smathy: KinderSpiel, so if the generator doesn't work on the command line then it won't work in your code.
[17:11:41] sarink: smathy: ah. i thought it was. thanks.
[17:12:09] smathy: benlieb, you can't, you need to add to to_json in the to_json() method itself.
[17:13:01] KinderSpiel: smathy I can go through what's the actual problem generating later, but first I need to get the call to Actions.generate correct, so I can debug it from there
[17:13:12] benlieb: I found something I think I like that is a little higher up and would work for all serialization. What do you think of the last anwer here: http://stackoverflow.com/questions/6892044/add-virtual-attribute-to-json-output
[17:13:32] KinderSpiel: shathy code's quite old, I'm guessing it's not beyond repair
[17:15:12] smathy: KinderSpiel, well, the code you send to `.generate` is the same code you'd send to the `rails generate` on the command line, just with the generator itself as the first arg, and the rest of the args as the subsequent arguments.
[17:15:21] simkessy: Hi, I'm venturing into services and trying to add them to my helper. It seems like I'm repeating myself a lot. Can this be improved? https://gist.github.com/simkessy/0187c8ff17ee86105c7f
[17:17:09] rushed: has joined #RubyOnRails
[17:17:09] wpp: has joined #RubyOnRails
[17:18:04] RegulationD: has joined #RubyOnRails
[17:18:33] bricker: simkessy: yes, you're needlessly initializing identical objects every time you call one of those methods
[17:19:24] DLSteve: has joined #RubyOnRails
[17:19:55] havenwood: has joined #RubyOnRails
[17:20:13] simkessy: bricker: I've been trying to figure out how to initialize the object once, is that possible
[17:20:42] KinderSpiel: smathy that's helpful, appreciate it a lot, but still the problem is the error
[17:20:58] bricker: simkessy: yes, initialize and memoize it in a separate method, then call that method
[17:21:02] t_mmyv: has joined #RubyOnRails
[17:21:06] stannard: has joined #RubyOnRails
[17:21:10] KinderSpiel: smathy even with correct params, I get NoMethodError: undefined method `behavior' for Rails::Generators::Actions:Module
[17:21:18] bricker: def pricing_service; @pricing_service ||= PricingService.new(...); end
[17:21:21] petricore: has joined #RubyOnRails
[17:21:30] bricker: pricing_service.tax, pricing_service.price, etc
[17:22:08] KinderSpiel: smathy if I could at least create an object I could pry it but there's no such thing as Rails::Generators::Actions.new
[17:22:47] chills42: has joined #RubyOnRails
[17:23:14] EminenceHC: has joined #RubyOnRails
[17:23:49] rodfersou: has joined #RubyOnRails
[17:25:00] sanjayu: has joined #RubyOnRails
[17:25:35] banister: has joined #RubyOnRails
[17:25:48] netzfisch: has joined #RubyOnRails
[17:26:56] cih: has joined #RubyOnRails
[17:29:37] yfeldblum: has joined #RubyOnRails
[17:30:33] raunicolae: has joined #RubyOnRails
[17:31:03] smathy: KinderSpiel, well you said they were correct params, but the command line generator doesn't work.
[17:32:07] simkessy: bricker: Is this what you meant https://gist.github.com/simkessy/0187c8ff17ee86105c7f
[17:32:43] epitron: has joined #RubyOnRails
[17:32:53] axl_: has joined #RubyOnRails
[17:32:58] jobewan: has joined #RubyOnRails
[17:33:41] bricker: simkessy: no, see my messages above
[17:33:55] raunicolae: has left #RubyOnRails: ()
[17:34:39] simkessy: oh sorry missed those lines
[17:34:44] simkessy: trying again
[17:35:05] kzsh: has joined #RubyOnRails
[17:35:40] symbol: has joined #RubyOnRails
[17:36:23] KinderSpiel: smathy what's your point?
[17:37:25] simkessy: bricker: I think I got it now https://gist.github.com/simkessy/0187c8ff17ee86105c7f
[17:37:54] bricker: simkessy: almost, you should reference the `pricing_service` method, not the instance variable
[17:38:33] KinderSpiel: smathy I wouldn't expect the generator to work, I'm "porting" the code right now
[17:38:53] simkessy: bricker: ahhh right right, that makes sense.
[17:38:56] t_mmyv: has left #RubyOnRails: ()
[17:38:57] simkessy: Thanks for your with this
[17:39:23] EminenceHC: has joined #RubyOnRails
[17:39:35] KinderSpiel: smathy I would expect that a call to Rails::Generators::Actions.generate would give me at least an error message related to Actions, not on that behavior method
[17:40:09] KinderSpiel: smathy that I don't even know where it comes from
[17:40:50] ascarter: has joined #RubyOnRails
[17:41:15] _djbkd: has joined #RubyOnRails
[17:43:05] yaymukund: has joined #RubyOnRails
[17:43:45] kzsh: has left #RubyOnRails: ("Leaving...")
[17:44:53] _djbkd: has joined #RubyOnRails
[17:46:31] TomyLobo: has joined #RubyOnRails
[17:46:39] mikecmpbll: has joined #RubyOnRails
[17:46:52] smathy: KinderSpiel, my point is that Rails::Generators::Actions.generate really just calls the command line `rails generate ....` - so if the latter isn't working, then neither will the former
[17:47:02] Guest53: has joined #RubyOnRails
[17:47:13] pjammer: has joined #RubyOnRails
[17:48:13] sanjayu: has joined #RubyOnRails
[17:49:02] DEA7TH: has joined #RubyOnRails
[17:50:25] KinderSpiel: smathy I suppose I can't use rails 2 plugins now then, right?
[17:51:35] smathy: KinderSpiel, you're just mentioning now that you're trying to use Rails 2 plugins in Rails 4?
[17:53:28] simkessy: If still in early phases, is there any point is reducing the number of migrations files you have by making the changes in the more important migrations before going live? For example, If I have a migration to create Users but later on I have like 10 more related to users to add or remove or change types. Is it worth cleaning that up into the main migration?
[17:53:40] KinderSpiel: smathy it was on the homepage of the plugin, again: https://github.com/branch14/modeldrivenrails
[17:54:19] smathy: KinderSpiel, next time, you should lead with that.
[17:54:53] smathy: ...so yeah, you guessed right - you can't.
[17:55:12] simplyianm: has joined #RubyOnRails
[17:55:32] smathy: simkessy, before going live I *always* edit the original create migration and re-run it.
[17:56:05] simkessy: smathy: ah perfect exactly what I though.
[17:56:17] sotojuan: has joined #RubyOnRails
[17:57:05] stannard: has joined #RubyOnRails
[17:57:21] kgzm: has joined #RubyOnRails
[17:58:39] KinderSpiel: smathy actually you're wrong
[17:58:57] KinderSpiel: smathy you just need to move and rename the files to the correct places
[17:59:07] jsrn_: has joined #RubyOnRails
[18:00:01] smathy: KinderSpiel, great to hear, well done.
[18:02:13] shinnya: has joined #RubyOnRails
[18:02:19] bronson: has joined #RubyOnRails
[18:04:38] seank__: has joined #RubyOnRails
[18:04:44] Seich: has joined #RubyOnRails
[18:04:45] j_mcnally: has joined #RubyOnRails
[18:05:33] diegoviola: has joined #RubyOnRails
[18:07:00] KinderSpiel: smathy whats the joke?
[18:07:27] rushed: has joined #RubyOnRails
[18:07:40] KinderSpiel: smathy if you don't know, you don't know
[18:07:55] KinderSpiel: smathy no need to try and find cop-outs
[18:07:56] smathy: You've lost me.
[18:08:12] smathy: How is telling you that it's great to hear and well done a cop-out?
[18:08:47] KinderSpiel: didn't sound like a compliment
[18:09:30] smathy: KinderSpiel, if you want to discuss something maybe you should contact me in PM, this is not relevant for anyone else in the channel.
[18:10:07] KinderSpiel: smathy not really, just looking for someone that codes and is willing to help
[18:10:38] blackmesa: has joined #RubyOnRails
[18:10:42] smathy: KinderSpiel, you said you'd worked it out.
[18:10:48] smathy: ...or implied at least.
[18:10:55] KinderSpiel: smathy in fact, having a single plugin, for rails 2, for model driven development, kinda speaks hugely
[18:11:17] smathy: ACTION isn't following
[18:11:22] KinderSpiel: smathy no I didn't imply, because I have moved such files to the correct places
[18:11:31] tubbo: KinderSpiel: you mean it speaks hugely to how useless it is
[18:11:38] tubbo: for most rails devs that is
[18:11:54] tubbo: UML diagrams of existing rails models, however, are definitely a thing
[18:12:28] smathy: KinderSpiel, you told me that I was wrong (when I said that you can't use the Rails 2 plugin with Rails 4), and followed with an explanation of how you just need to move and rename files. That's fairly clearly an implication that you got it working by moving/renaming files.
[18:12:42] smathy: KinderSpiel, if you didn't get it working, then why would you assert that I was wrong when I said it wouldn't work?
[18:12:44] tubbo: KinderSpiel: the generators i know for a fact have changed drastically since rails 2
[18:13:21] KinderSpiel: smathy not at all, I got it working up to a point that's when the generators changed from on rails version to another
[18:13:40] benlieb: is there a community standard for documenting model attributes?
[18:13:44] smathy: KinderSpiel, so, right now, you have not got a Rails 2 plugin working in Rails 4?
[18:13:46] KinderSpiel: smathy strangelly, nobody seems to know how they work now, or I'd have found some info
[18:14:17] baweaver: has joined #RubyOnRails
[18:15:16] KinderSpiel: tubbo don't know if it's useless, it's useful for me
[18:15:44] tubbo: KinderSpiel: that's why i said "for most rails devs", in other words that's why the plugin wasn't updated or why it never gained a lot of popular usage.
[18:16:22] tubbo: KinderSpiel: now that you have the actual meat & potatoes of the code working, why not just regenerate the generators with `rails generate generator`?
[18:16:35] tubbo: probably a lot easier than spelunking and trying to find diffs between minor versions of raisl
[18:17:30] tubbo: benlieb: what do you mean, something that will give you docs in your model/spec files that tell you what columns are in each table?
[18:17:41] KinderSpiel: tubbo I don't have it working because it comes up with an unrelated error on calling a non-existant 'behavior' method
[18:18:15] KinderSpiel: tubbo if it didn't, I'd skip the generators and do my thing, execute the rest with backticks and get it done with
[18:18:40] netzfisch: has joined #RubyOnRails
[18:19:12] KinderSpiel: tubbo and the fact that MDD didn't catch up in the rails community is not a surprise to me at all, most devs use a relational model they can fit in their heads
[18:20:19] tubbo: KinderSpiel: are you "testing" this by running the generator? my thought was that if you just got rid of https://github.com/branch14/modeldrivenrails/tree/master/generators and rewrote them in the rails 3/4 style, that might solve your issue here.
[18:20:29] youngbaks: has joined #RubyOnRails
[18:21:47] RegulationD: has joined #RubyOnRails
[18:22:09] tubbo: KinderSpiel: that is absolutely not true...it's just so easy to generate a relational structure using the generators that most people don't develop UML diagrams prior to building their app. they just `rails new` and then `rails generate` until it's done :)
[18:22:50] tubbo: it's easy to see the relationships between models expressed as ruby code, so there's really not much of a need for UML unless you *really* need a visual representation, or you just want to laugh.
[18:23:03] tubbo: (i always laugh at the tangled mess a UML creates on some apps)
[18:23:49] tubbo: taking an existing UML diagram in order to generate a Rails app is even less common...mostly because Rails isn't a popular framework to refactor *into* (though it's become quite popular to refactor out of lol)
[18:24:24] KinderSpiel: tubbo I wonder why
[18:24:49] rushed: has joined #RubyOnRails
[18:25:08] KinderSpiel: I'll just give it another go before declaring this thing dead and find another solution
[18:25:24] rubyonrailed: has joined #RubyOnRails
[18:25:41] KinderSpiel: tubbo, a lof of complex applications in the world have very complex diagrams, not everything is a webapp
[18:25:48] baweaver: like not carrying preconceived notions over from other languages and frameworks and crying foul when it doesn't translate 1-1?
[18:26:01] KinderSpiel: tubbo different strokes for different folks, but I'm sure you know that
[18:26:13] tubbo: KinderSpiel: ActiveRecord (because, let's be real, that's pretty much what we're talking about here...the rest of Rails is irrelevant) is quite opinionated and is somewhat hard to use when you need to apply a lot of configuration to models. the conventional AR approach is to let AR control your database's schema.
[18:26:46] tubbo: KinderSpiel: oh definitely, and Rails is not a great choice for those kinds of extremely large scale applications. also, rails is a WEB APPLICATION FRAMEWORK so if it's not a web application...Rails is most likely not a great fit :)
[18:27:07] baweaver: Rails is opinionated, if you can't handle that then using Rails is a really bad idea. It won't apologize for what it is, and most certainly won't for what it isn't
[18:27:08] FailBit: oh fuck this fucking bot
[18:27:24] helpa: It's probably not going to scale either.
[18:27:37] sanjayu: has joined #RubyOnRails
[18:27:51] baweaver: probably hasn't been added to the users accepted for it
[18:28:48] FailBit: rails is not that worse a contender when it comes to arbitrary notions of scale
[18:29:00] relix: has joined #RubyOnRails
[18:29:01] Scient: IS IT WEBSCALE?
[18:29:04] tubbo: well once you get to a certain point the language doesn't matter anymore
[18:29:07] Scient: it is when you add mongodb to it!
[18:29:09] FailBit: because the single largest factor in your app will always be your datastores
[18:29:11] tubbo: mailchimp, for example, is written on the frontend in PHP
[18:29:11] Scient: woop woop
[18:29:21] tubbo: Scient: ur banned
[18:29:23] KinderSpiel: this is where I get off :)
[18:29:26] baweaver: Ask BitCoin how Mongo works for them
[18:29:34] Scient: ask bitcoin how bitcoin works for them
[18:29:39] tubbo: KinderSpiel: later have fun with your web scales ;)
[18:29:41] Scient: hint: it doesnt
[18:29:48] Scient: what sparked the discussion though
[18:29:50] tubbo: Scient: ask bitcoin how OH GOD IM POOR WHYYYYYY
[18:29:53] Scient: the backlog was too busy to track it down
[18:29:54] mclee_: has joined #RubyOnRails
[18:29:55] tubbo: oh wait never mind it's cool
[18:29:57] KinderSpiel: tubbo 'preciate it
[18:30:08] rubyonrailed: I'm getting this warning when I start my rails console. My app works fine and all specs pass, I just don't know how to get rid of the warning. Anybody have any ideas? https://gist.github.com/anonymous/23f7146b7c93f625312a
[18:30:17] tubbo: KinderSpiel: and remember, if the committer doesn't have a github account, the project is too old.
[18:30:21] KinderSpiel: smathy thanks man, just frustrated with this
[18:31:29] smathy: KinderSpiel, don't mention it.
[18:31:33] tubbo: rubyonrailed: it's just re-loading the Submission::Base model again and re-setting the constant. you can get rid of it by moving the file to lib/ and requiring it manually, but then the code doesn't get reloaded when you refresh the page.
[18:32:23] rubyonrailed: tubbo: Cool thanks for the quick reply
[18:33:33] targaf: anyone have experience getting the masked input plugin (http://digitalbush.com/projects/masked-input-plugin/) to play nice with rails forms?
[18:33:36] stannard: has joined #RubyOnRails
[18:35:38] `based_pdev`: has joined #RubyOnRails
[18:35:42] tubbo: rubyonrailed: i literally deal with this shit all day (we have a engine-based platform on rails with the ability to decorate classes)
[18:36:36] drptbl: has joined #RubyOnRails
[18:38:55] kzsh: has joined #RubyOnRails
[18:40:10] rclanan: has joined #RubyOnRails
[18:41:41] rclanan_: has joined #RubyOnRails
[18:41:54] herbst: has joined #RubyOnRails
[18:43:19] simplyianm: has joined #RubyOnRails
[18:43:31] Scient: targaf: doesnt seem difficult
[18:43:34] Scient: in fact it has nothing to do with rails
[18:43:36] Scient: so whats the problem
[18:43:56] Coldblackice: has joined #RubyOnRails
[18:44:08] targaf: I have no experience calling jquery functions, you're right that it is a general webdev question, though
[18:44:33] sdwrage: has joined #RubyOnRails
[18:45:49] n008f4g_: has joined #RubyOnRails
[18:47:07] toretore: has joined #RubyOnRails
[18:48:02] bruno-: has joined #RubyOnRails
[18:48:41] greengriminal: has joined #RubyOnRails
[18:48:54] tubbo: targaf: #jquery might be able to help too
[18:50:24] tsujp: has joined #RubyOnRails
[18:50:49] targaf: good call. thanks, tubbo.
[18:51:23] ramfjord: has joined #RubyOnRails
[18:52:30] blackmesa: has joined #RubyOnRails
[18:52:43] cih_: has joined #RubyOnRails
[18:56:24] j_mcnally: has joined #RubyOnRails
[18:56:28] paulcsmith: has joined #RubyOnRails
[18:56:44] shtirlic: has joined #RubyOnRails
[18:58:19] hightower4: Hey, I have a javascript function which I want to call with a value of cart_link_url, like <script>get_cart('<%= cart_link_url %>')</script>. Is this alright (given that the cart_link_url is generated by Rails and not coming from user input), or I should somehow strip/escape that value to be safe?
[19:00:27] EminenceHC: has joined #RubyOnRails
[19:00:53] yfeldblum: has joined #RubyOnRails
[19:01:45] sanjayu: has joined #RubyOnRails
[19:03:17] bronson: has joined #RubyOnRails
[19:03:53] jkamenik: has joined #RubyOnRails
[19:04:54] jkamenik: has left #RubyOnRails: ()
[19:05:10] tubbo: hightower4: you should be OK. if you start needing routes in your JS all the time, this might help: https://github.com/railsware/js-routes
[19:06:25] hightower4: tubbo, sounds good, thanks
[19:06:33] waseem_: hightower4: That value comes from a well defined Rails helper so you should, like tubbo said, OK. In case you're not sure, it is wise to escape using h http://api.rubyonrails.org/classes/ERB/Util.html#method-c-h
[19:06:34] snockerton: has joined #RubyOnRails
[19:06:51] snockerton: is there a way to open a rails console without your prompt being in the rails root directory?
[19:07:28] FailBit: (cd path/to/rails ; rails c)
[19:08:06] snockerton: what if I can't cd first?
[19:08:27] FailBit: where are you relative to the installation
[19:09:20] snockerton: in the parent directory
[19:09:24] waseem_: tubbo: That's a helpful gem. Thanks for sharing. :)
[19:09:31] maz-dev: has joined #RubyOnRails
[19:09:43] snockerton: trying to console to a rails app running in a phusion/passenger docker image
[19:09:50] snockerton: nothing seems to work
[19:10:00] FailBit: snockerton: can you run irb from outside?
[19:10:26] centrx: has joined #RubyOnRails
[19:10:56] tubbo: waseem_: no problem. we use js_routes and i18n-js to provide some rails niceties to the JS layer. as web apps are becoming increasingly dependent on the client for refreshing content, i can see rails eventually moving in this direction
[19:11:09] tubbo: like, rails incorporating this stuff into the helpers for JS/CSS assets
[19:11:17] FailBit: because then all you would need to do would be to load 'rails_app/bin/rails'
[19:12:28] jkamenik: has joined #RubyOnRails
[19:12:30] chills42: has joined #RubyOnRails
[19:12:50] waseem_: tubbo: Yeah, very often I've felt the need to use Rails routes in my JS. Harcoding the paths at different places always _felt_ weird. Mostly because of changing routes.rb requiring changes in JS as well.
[19:13:02] ruurd: has joined #RubyOnRails
[19:13:47] snockerton: FailBit: yea i can do that, but am unable to access my db to test my models
[19:13:48] stamina: has joined #RubyOnRails
[19:13:58] snockerton: i think i'm thinking about this wrong, as usual
[19:15:01] shtirlic: has joined #RubyOnRails
[19:15:04] DLSteve: has joined #RubyOnRails
[19:15:11] simplyianm: has joined #RubyOnRails
[19:17:53] snockerton: FailBit: figured out better solution - just fire up another instance of the same docker image and pass /bin/bash as cmd
[19:17:56] shtirlic: has joined #RubyOnRails
[19:18:02] yaymukund: has joined #RubyOnRails
[19:18:42] VeryBewitching: has joined #RubyOnRails
[19:20:11] qejk: has joined #RubyOnRails
[19:20:23] tubbo: snockerton: install web-console to your Gemfile? :D
[19:20:46] Cervajz_: has joined #RubyOnRails
[19:24:59] snockerton: tubbo: yea this reminded me i need to add that to my project
[19:25:25] snockerton: one of the more security conscious members of the team thinks it's evil
[19:26:15] FailBit: only add it to the development group
[19:26:30] FailBit: also, don't be patreon
[19:27:48] cac: has joined #RubyOnRails
[19:28:54] youngbaks: has joined #RubyOnRails
[19:31:31] tubbo: snockerton: certainly, if you're dumb and install development gems to production :P
[19:31:35] tubbo: FailBit: patreon?
[19:31:51] tubbo: the crowdfunding platform?
[19:32:14] FailBit: they had their production db loaded to staging, and staging was exploited to achieve file access
[19:32:26] chills42: has joined #RubyOnRails
[19:32:27] FailBit: patreon's source code and entire database are dumped for the world to see
[19:32:51] tubbo: @FailBit link? i'm curious!
[19:32:56] tubbo: not the DB, the source code
[19:33:03] FailBit: the passwords are encrypted with bcrypt, so that's one thing
[19:33:11] FailBit: you'd need some FPGAs cracking at that
[19:33:35] FailBit: tubbo: https://patreon.thecthulhu.com/extracted/patreon.tar.gz/patreon/
[19:33:43] _djbkd: has joined #RubyOnRails
[19:33:59] sanjayu: has joined #RubyOnRails
[19:34:30] thsig: has joined #RubyOnRails
[19:35:46] deavid: has joined #RubyOnRails
[19:36:05] EminenceHC: has joined #RubyOnRails
[19:36:19] pjammer: has joined #RubyOnRails
[19:36:50] tubbo: FailBit: oh, i thought it was a rails app
[19:37:38] FailBit: it's a flask/py app
[19:39:48] RegulationD: has joined #RubyOnRails
[19:40:20] ruurd: has joined #RubyOnRails
[19:40:24] pwnd_nsfw: "iesupport"
[19:40:39] based_pdev_: has joined #RubyOnRails
[19:40:48] j_mcnally: has joined #RubyOnRails
[19:41:04] ngscheurich: has joined #RubyOnRails
[19:42:20] Grundell: has joined #RubyOnRails
[19:44:44] stannard: has joined #RubyOnRails
[19:44:46] gousuto: has joined #RubyOnRails
[19:45:05] d5sx43: has joined #RubyOnRails
[19:45:07] n1lo: has joined #RubyOnRails
[19:46:09] j_mcnally: has joined #RubyOnRails
[19:46:23] FailBit: okay this is pissing me off
[19:46:41] FailBit: how do I get all the attribute values if I have an attribute I want to test every html element for
[19:47:01] workmad3: has joined #RubyOnRails
[19:49:23] ciree: how do I compile sass files programatically?
[19:49:34] ciree: Sass::SyntaxError: File to import not found or unreadable: ./globals/all
[19:50:00] sanjayu: has joined #RubyOnRails
[19:51:21] jkamenik: has joined #RubyOnRails
[19:54:00] cnk: has joined #RubyOnRails
[19:54:02] Scient: is there like a comparison of rails css minifiers out there?
[19:55:59] tubbo: Scient: i'm curious, what other kinds of minifiers are available for rails? i typically use sass for css, and uglify for js
[19:56:38] baweaver: has joined #RubyOnRails
[19:57:25] Stuffness: has joined #RubyOnRails
[19:58:20] paulcsmith: has joined #RubyOnRails
[19:58:47] paolochiodi: has joined #RubyOnRails
[19:59:01] bronson: has joined #RubyOnRails
[19:59:36] baweaver: has joined #RubyOnRails
[20:00:35] l1meon: has joined #RubyOnRails
[20:02:07] annlewis: has joined #RubyOnRails
[20:02:11] hahuang65: has joined #RubyOnRails
[20:02:32] dllama: has joined #RubyOnRails
[20:02:55] l1meon: hello, I have a question. What is the difference between a junior and middle developer? What can do middle and can't junior?
[20:03:14] centrx: junior developer gets the coffee
[20:03:28] tubbo: middle developer gets blamed for the coffee tasting like shit by the senior
[20:04:00] l1meon: nice one :D
[20:04:14] l1meon: but if really ?
[20:04:22] skyjumper: more like senior gets the new job, junior and middle get envious
[20:04:31] skyjumper: what those terms mean is open to interpretation
[20:04:45] paulcsmith: has joined #RubyOnRails
[20:05:37] eggie5: has joined #RubyOnRails
[20:05:57] skyjumper: does this make sense to anyone... somehow my config is being cached? https://gist.github.com/anonymous/325261ea6407548e0658
[20:06:19] skyjumper: removed everything except routes.rb and the console still loads, can still access the DB
[20:07:20] FailBit: http://apidock.com/ruby/Module/module_function til
[20:08:23] dllama: skyjumper: trying restarting spring
[20:08:56] blackmesa: has joined #RubyOnRails
[20:10:12] jenrzzz: has joined #RubyOnRails
[20:12:14] Scient: tubbo: im using uglifier for js and yui for css
[20:12:22] Scient: trying to figure out if using yui is better than sass
[20:12:56] dikaio: has joined #RubyOnRails
[20:14:39] skyjumper: hahah, completely forgot spring was running
[20:14:52] skyjumper: dllama: thx
[20:15:08] sanjayu: has joined #RubyOnRails
[20:15:23] smathy: Scient, YUI and sass aren't the same sort of thing.
[20:16:31] dllama: i've banged my head against the wall with that one more than once :)
[20:16:32] Scient: both are minifiers
[20:16:41] j_mcnally: has joined #RubyOnRails
[20:16:58] FailBit: the recommended solution is to remove spring from the gemfile
[20:16:58] ascarter: has joined #RubyOnRails
[20:19:14] naftilos76: has joined #RubyOnRails
[20:19:52] xye: has joined #RubyOnRails
[20:19:57] craysiii: has joined #RubyOnRails
[20:20:16] lxsameer: has joined #RubyOnRails
[20:20:29] Guest53: has joined #RubyOnRails
[20:20:37] netzfisch: has joined #RubyOnRails
[20:20:53] darrencauthon: has joined #RubyOnRails
[20:21:04] baweaver: has joined #RubyOnRails
[20:21:28] n1lo: How can I write an ActiveRecord method?
[20:21:38] darrencauthon: has joined #RubyOnRails
[20:21:39] Radar: plzexplain
[20:22:25] EminenceHC: has joined #RubyOnRails
[20:22:27] baweaver: scopes or class methods, both of which are explained in docs
[20:22:48] darrenca_: has joined #RubyOnRails
[20:23:28] FailBit: https://i.imgur.com/WXqv46u.png
[20:23:33] FailBit: that's not as bad as new relic tells me it is
[20:23:59] TheSuper: has joined #RubyOnRails
[20:24:02] FailBit: y is hits, x is ms
[20:25:10] helpa: For maximum webscales, use MongoDB. Also see: !node.js
[20:25:10] benlieb: has joined #RubyOnRails
[20:25:25] n1lo: For example I have forks and plates(has_many :forks) I want to create an ActiveRecord method to show a Plate XYZ - Fork x, Fork y etc.
[20:25:47] TheSuper: So, iterate through all the forks for a given plate?
[20:25:57] Radar: n1lo: !fake
[20:25:57] helpa: n1lo: Please do not use fake values, as they can be confusing or misleading. Sometimes both.
[20:26:02] FailBit: https://i.imgur.com/36iwCAE.png
[20:27:01] n1lo: Radar, -_-
[20:27:14] Radar: n1lo: rules are rules
[20:27:42] rhizome: at least describe what you want to do in plain english
[20:28:14] _djbkd: has joined #RubyOnRails
[20:28:22] rushed: has joined #RubyOnRails
[20:28:49] safety_cut: has joined #RubyOnRails
[20:30:18] TheSuper: So I actually had a question. I already made an SO post: http://stackoverflow.com/questions/32912698/
[20:30:56] TheSuper: I'm basically trying to eager load several records at once, but Rails is making a billion queries
[20:31:00] TheSuper: Which is kind of annoying
[20:31:22] Radar: I really wish I could fix this https://github.com/braintree/braintree-web/issues/69
[20:31:26] TheSuper: (Note: By "A billion", I mean "One for every associated member")
[20:31:31] n1lo: Ok. Just a custom method for a model.
[20:31:31] sar1nk: has joined #RubyOnRails
[20:31:52] TheSuper: If you want a custom method you can just define it on the model directly.
[20:31:54] Radar: n1lo: What does this method do?
[20:32:55] n1lo: Show the relation between him and another model.
[20:33:08] Radar: n1lo: Ok, if you're going to continue to be vague about it then I can't help you.
[20:33:15] Radar: Either show us some real code, or... I dunno.
[20:38:48] baweaver: Radar: yes you do :P
[20:39:18] zendrix: has joined #RubyOnRails
[20:39:50] zendrix: has left #RubyOnRails: ()
[20:40:35] frzn: has joined #RubyOnRails
[20:40:42] CanTonic: has joined #RubyOnRails
[20:41:24] FailBit: I know what's wrong now
[20:41:36] FailBit: check this out
[20:41:39] FailBit: https://i.imgur.com/Z907d6j.png
[20:43:30] EminenceHC: has joined #RubyOnRails
[20:43:35] _djbkd: has joined #RubyOnRails
[20:43:46] pwnd_nsfw: <%= f.input :category, as: :select, collection: Category.all %>
[20:43:56] pwnd_nsfw: Would it be better for me to actually define the collectio in the controller instead?
[20:44:03] TheSuper: Yes it would.
[20:44:09] yes`r: has joined #RubyOnRails
[20:45:18] FailBit: aw, I'm disappointed I can't get anyone to scream in horror at my image
[20:46:00] pwnd_nsfw: FailBit, I'm fapping to it
[20:46:17] FailBit: pwnd_nsfw: lel
[20:46:33] FailBit: HERE'S THE PROBLEM
[20:46:44] rclanan: has joined #RubyOnRails
[20:47:38] tubbo: FailBit: i have no idea
[20:47:52] tubbo: like what you're talking about :D
[20:48:15] TheSuper: FailBit, I blame Mongo DB
[20:48:16] FailBit: it's making the same query 4 times
[20:48:20] FailBit: and paying the price every single time
[20:48:25] FailBit: TheSuper: I don't
[20:48:27] CanTonic: hey there. When using guard-rspec I get doubled outputs in the terminal. Looks like I have conflicting format options for guard, but '.rspec' containt no format options and the guard command also doesn't
[20:48:27] tubbo: haha FailBit i forgot you're working on a brony site
[20:48:40] moeabdol: has joined #RubyOnRails
[20:48:41] FailBit: but that's not even relevant!
[20:48:49] CanTonic: I was able to see that "-f progress" as well as "-f Guard::RSspecFormatter" are being used
[20:49:19] drptbl: has joined #RubyOnRails
[20:50:31] TheSuper: Failbit, I'm sorry, I think I'm legally required to make fun of Mongo. But seriously use whatever works best. Although Mongo probably isn't what works best if you have highly relational data, and???
[20:50:36] bronson: has joined #RubyOnRails
[20:50:36] TheSuper: yeah all you guys know this
[20:50:38] tubbo: FailBit: yeah but it's an actual rails app, not just a my_first_todo_list_app kind of thing
[20:50:43] tubbo: which is better
[20:50:56] hahuang65: has joined #RubyOnRails
[20:50:57] rushed: has joined #RubyOnRails
[20:51:19] FailBit: TheSuper: I'm well aware that mongodb is a giant piece of shit
[20:51:23] FailBit: I wasn't the one who picked it
[20:51:45] atmosx_laptop: has joined #RubyOnRails
[20:51:50] FailBit: tubbo: I do it for the experience and because I like scaled down horses that I am entitled to
[20:52:02] tubbo: entitled? :P
[20:52:18] FailBit: ie, they are mine
[20:52:20] cih: has joined #RubyOnRails
[20:52:39] TheSuper: Fair enough
[20:52:47] TheSuper: Did you get a job or are you strictly volunteering?
[20:53:02] FailBit: https://twitter.com/docsigma/status/193522984122720256
[20:53:23] TheSuper: (kind of a personal question but I'm going to have some time to kill over the next week while my frontend designer does stuff and I'd kind of like to volunteer on a large rails project)
[20:53:28] FailBit: TheSuper: I >do it for free
[20:54:26] cih: has joined #RubyOnRails
[20:55:04] TheSuper: Fair enough
[20:55:05] Spami: has joined #RubyOnRails
[20:55:11] FailBit: to use 8chspeak
[20:55:20] jmallen: has joined #RubyOnRails
[20:56:03] TheSuper: So, can anybody answer the question I posted?
[20:56:15] FailBit: http://knowyourmeme.com/memes/he-does-it-for-free
[20:56:17] TheSuper: Because looking at ways to do this, I think Rails might just have bad behavior in this case
[20:56:27] TheSuper: (I'm aware of the joke, I browse /g/ quite often)
[20:56:48] Radar: maybe don't talk about sketchy things on a public channel?
[20:57:26] bricker: great idea +1
[20:58:20] TheSuper: Also adding a 1 here.
[20:58:30] annlewis: has joined #RubyOnRails
[20:58:32] atmosx_laptop: can someone help me adjust this test: https://gist.github.com/atmosx/a40c4f81fcebb29be6fc ?
[20:58:46] FailBit: just remember to delete system32
[20:59:10] TheSuper: Anyway, back to my original question... if rails does behavior non-optimally in this case, should I just take it to #rails-contrib?
[20:59:14] TheSuper: I bet I could fix it if I tried
[20:59:53] Maletor: has joined #RubyOnRails
[21:00:59] FailBit: https://i.imgur.com/G9zzf2B.png I love what I do
[21:01:38] TheSuper: You should look into using pry instead of irb, it's better in essentially every way.
[21:01:54] FailBit: I already do use pry on dev
[21:02:10] meoblast001: has joined #RubyOnRails
[21:02:52] zibs: has joined #RubyOnRails
[21:03:02] dopie: has joined #RubyOnRails
[21:04:26] dnewkerk: has joined #RubyOnRails
[21:04:28] darrencauthon: has joined #RubyOnRails
[21:04:28] pjammer: has joined #RubyOnRails
[21:06:15] darrenca_: has joined #RubyOnRails
[21:06:57] skyjumper: FailBit: how is gnome these days?
[21:07:10] FailBit: gnome 3.10 is complete shit
[21:07:14] FailBit: 3.18 is awesome sauce
[21:07:31] FailBit: unfortunately for me I still use ubuntu on my main box
[21:07:33] FailBit: so can't upgrade
[21:07:45] skyjumper: no PPA for updated gnome?
[21:07:54] FailBit: it breaks because mir
[21:08:09] FailBit: holy fuck can canonical do anything without reinventing already existing tech
[21:08:27] FailBit: I'm ditching ubuntu as soon as I can really be bothered to
[21:09:02] smathy: TheSuper, answered: http://stackoverflow.com/a/32915897/152786
[21:09:34] blackmesa: has joined #RubyOnRails
[21:10:03] boombadaroomba: has joined #RubyOnRails
[21:10:06] zendrix: has joined #RubyOnRails
[21:10:07] TheSuper: That still runs just as many queries.
[21:10:17] yfeldblum: has joined #RubyOnRails
[21:11:15] tubbo: TheSuper: except for the fact that you have to install it!
[21:11:31] tubbo: something interesting i found...pry is just a "skin" for irb, irb can do practically everything i find useful in pry, it's just really hard.
[21:11:54] TheSuper: That is true, but Pry adds a lot of nice features that I think make it worth it
[21:13:44] gavit: what gem do you use for charts?
[21:13:52] Scient: do you guys use spring at all?
[21:13:57] gavit: I was expecting it to be in bootstrap or a plugin of bootstrap
[21:14:03] gavit: I however see one in jquery...
[21:14:09] Scient: it seems like all these combinations of spring and guard and stuff is like... weird
[21:15:16] linoge: has joined #RubyOnRails
[21:15:52] smathy: TheSuper, it runs two queries.
[21:15:54] Grundell: has joined #RubyOnRails
[21:16:13] TheSuper: For me it is running one for every single tag_group on a given image
[21:17:30] TheSuper: http://i.imgur.com/Kaym0MI.png
[21:17:44] linoge: Thoughts on SpreeCommerce?
[21:17:48] smathy: TheSuper, then something is broken, i.tag_groups.joins(:tags) will run a single query doing an inner join to tag_group_members because of the :through and an inner join to tags because of the `joins(:tags)`
[21:18:04] TheSuper: That's what should be happening, but for some reason it isn't
[21:18:20] smathy: TheSuper, you're not showing something then.
[21:18:21] TheSuper: Although... Hm, wait. Maybe I made a goof here.
[21:18:25] TheSuper: Oh I think I know what I did
[21:18:30] TheSuper: I'm an idiot
[21:18:34] smathy: Maybe a counter cache or something?
[21:18:41] TheSuper: Yeah, something like that
[21:18:42] TheSuper: I just realized
[21:18:45] TheSuper: I'm an idiot
[21:18:52] smathy: ...although the SELECT 1 is an exists?
[21:19:16] TheSuper: I know exactly what I did
[21:19:22] TheSuper: After what you said
[21:19:36] bronson: has joined #RubyOnRails
[21:21:05] Guest53: has joined #RubyOnRails
[21:22:03] tubbo: Scient: i tried to use it with guard but really didn't see much benefit. livereload was kinda nice though (although i wish it was just baked in to rails/sprockets)
[21:22:10] tubbo: Scient: i do use spring and i think it helps a lot
[21:22:26] FailBit: https://i.imgur.com/yFFeDxs.png
[21:22:34] FailBit: niceeeeeeeeee
[21:22:38] Scient: i can see the benefit in guard, but spring mostly seems to annoy me
[21:22:43] Scient: introducing some weird issues at times
[21:23:03] Anubix: has joined #RubyOnRails
[21:23:14] yardenbar: has joined #RubyOnRails
[21:23:20] zendrix: has left #RubyOnRails: ()
[21:23:24] tubbo: Scient: that's because, like good compression, you don't realize it's there when its working.
[21:23:30] rubyonra_: has joined #RubyOnRails
[21:23:37] tubbo: when i turn spring off or disable it, i notice a significantly longer startup time for each command
[21:23:55] FailBit: but that long startup time doesn't really bother me
[21:24:04] FailBit: because I don't really run a lot of commands
[21:24:10] tubbo: if i'm running `rspec my/tests/test.rb:25` then `rspec my/tests/test.rb` and then `rspec my/tests/` and finally `rspec`, it is annoying to have to wait for the rails app to boot a bunch of times
[21:24:10] FailBit: and reload! is always a thing
[21:24:18] tubbo: FailBit: so you don't write tests huh
[21:24:23] FailBit: not enough
[21:24:30] tubbo: well, that might be why your shit is broken
[21:26:43] FailBit: it's not broken enough either
[21:27:39] Scient: well thats what im thinking.. doesnt guard sort of solve the problem with running tests often?
[21:27:40] havenn: has joined #RubyOnRails
[21:28:03] baweaver: has joined #RubyOnRails
[21:28:58] tubbo: Scient: yeah, i mean...i don't feel like you need both. just one or the other. same with zeus (which literally does the same thing as spring and IMHO is a lot easier to understand)
[21:31:01] DanKnox: has joined #RubyOnRails
[21:31:10] darrencauthon: has joined #RubyOnRails
[21:31:25] Radar: spring </3
[21:31:58] cac: has joined #RubyOnRails
[21:34:20] RegulationD: has joined #RubyOnRails
[21:34:25] sonofdirt: has joined #RubyOnRails
[21:35:08] workmad3: has joined #RubyOnRails
[21:36:26] rubyonrailed: has joined #RubyOnRails
[21:39:34] smathy: Hmm, 95 open issues vs 55 in spring. Neither really has an air of production-quality.
[21:39:42] TheSuper: Thanks for the help, guys
[21:40:02] Radar: smathy: I don't swear and curse as much at zeus as I have at Spring.
[21:40:17] bricker: smathy: well, neither of them are production tools
[21:40:20] bricker: so that makes sense
[21:41:19] smathy: bricker, production-quality is not the same as something that's deployed to production. I meant something for professionals doing work that's being shipped to production.
[21:42:18] bricker: software is rarely perfect
[21:42:31] Radar: except when DHH writes it
[21:42:41] smathy: Never said it had to be perfect.
[21:42:46] cac: has joined #RubyOnRails
[21:43:08] smathy: Just of a quality that someone beyond a hobbyist expects.
[21:43:39] VeryBewitching: I don't want software to be perfect, it would eliminate room to improve.
[21:43:46] chipotle: i have a stupid qution: rails has their own webserver bunded into rails, right? if not,c cna you use and webserver, specifically nginx?
[21:43:48] smathy: Radar, that zeus has a Limitations section in the readme is a step forward, but really I think the biggest problem with spring is that it's auto-loaded/run/etc.
[21:44:07] chipotle: and are there downsides to using nginx over antoher web serve
[21:44:13] Anubix: What is best server for rails for production?
[21:44:18] smathy: chipotle, yes it does, WEBrick
[21:44:40] chipotle: are you tied to using WEBrick?
[21:44:40] smathy: Anubix, depends on your app.
[21:44:41] Radar: chipotle: WEBrick is a built-in-to-Ruby webserver that Rack uses by default if no other options are available.
[21:44:50] rushed: chipotle: the built in server is primarly provided for development, you would usually not use it in production
[21:44:51] Radar: chipotle: Rack is used by Rails to handle the requests.
[21:44:53] smathy: chipotle, no.
[21:45:12] Anubix: smathy: How it depends?
[21:45:31] Radar: Anubix: !best
[21:45:31] helpa: Anubix: "Best" and "better" are subjective. Try to use a different term.
[21:45:32] smathy: Anubix, different web and app servers have different pros and cons.
[21:45:34] chipotle: Radar: good book! i began it but i'm going slow because i ended up in the ICU again. two weeks ago i was there a week, then i got admitted again friday
[21:45:46] Radar: thanks chipotle :D
[21:45:49] chipotle: but i brought the book to the hospital!
[21:45:49] smathy: Anubix, no single stack suits all situations.
[21:45:52] Radar: I'm back from holiday now
[21:46:09] Anubix: smathy: Okey :)
[21:46:27] Anubix: smathy: One of the most used server?
[21:46:54] smathy: Anubix, the real answer is that you really have two choices, learn enough about setting up a production server that you can answer these questions yourself, or, use Heroku.
[21:47:08] chipotle: so how is nginx different for ror? i mainly work with drupal, i create a vhost, point it to port 80 and 443 for encryption. then call whatever include's i need to from the include folder, and, of course i create logs and edit the server config.
[21:47:16] chipotle: is it the same way as ruby?
[21:47:27] Scient: rails apps need an appserver running in front of them
[21:47:28] Radar: Isn't drupal PHP?
[21:47:32] Anubix: smathy: Ok but webrick isnt good for production right?
[21:47:37] yardenbar: has joined #RubyOnRails
[21:47:37] Radar: which uses mod_php or whatever it is these days?
[21:47:38] Scient: its like php-fpm basically
[21:47:38] smathy: Anubix, definitely not.
[21:47:43] chipotle: Radar: yes it is
[21:47:46] Scient: you run php-fpm and point your server at it
[21:47:48] Anubix: smathy: okey
[21:47:56] Scient: with rails you run unicorn/passenger and point nginx at it
[21:48:00] chipotle: php-fmp has been in stable for at least wo years now. fastcgi sucks
[21:48:12] chipotle: Scient: what is an app server?
[21:48:15] Scient: Radar: only nabs use mod_php, and thats only apache :D
[21:48:23] Scient: chipotle: application server, like php-fpm
[21:48:29] smathy: "nabs" :)
[21:48:35] smathy: Glad we cleared that up.
[21:48:38] Scient: passenger is quite literally the same thing as fpm
[21:48:48] chipotle: and the package name is called appserver?
[21:48:56] Scient: google unicorn
[21:48:58] Scient: or passenger
[21:49:10] Scient: passenger might be easier to get going with for you
[21:49:23] Scient: phusion passenger that is
[21:49:28] Radar: Passenger is definitely easier to get going with
[21:49:38] Radar: Unicorn requires upstart config and so on
[21:50:15] CanTonic: has joined #RubyOnRails
[21:51:25] chipotle: gems are like modules in drupal?
[21:51:50] _djbkd: has joined #RubyOnRails
[21:52:19] eggie5: has joined #RubyOnRails
[21:53:46] chipotle: and rubygems.is the "official" place to get gems that have been tested somewhat (like you can find modules for drupal and github for example. is it jus a website to find the gem you need and then a download link? or do gems do more...? this is the drupal module search page... https://www.drupal.org/download
[21:53:49] Lytol: has joined #RubyOnRails
[21:56:05] Radar: Typically you'd ask other people what they're using for X and they'll tell you.
[21:56:25] chipotle: what people? like in this channel?
[21:57:36] based_pdev: has joined #RubyOnRails
[21:58:17] atmosx: we are the world
[21:58:19] atmosx: we are the people
[21:59:18] waseem_: chipotle: You can also find a list here: https://www.ruby-toolbox.com/
[21:59:41] snockerton1: has joined #RubyOnRails
[22:00:37] CanTonic: has joined #RubyOnRails
[22:01:05] chipotle: too bad there isn't a directory and search drupal.org/download
[22:01:26] chipotle: i just don't know what gems are out there at all, so i'd like to research what i actually nee
[22:01:28] das3in: has joined #RubyOnRails
[22:01:35] chipotle: i don't wanna flood this channel with newbie questions
[22:01:46] Radar: chipotle: other people have no such concerns ;)
[22:02:02] rubyonrailed: has joined #RubyOnRails
[22:02:48] das3in: What's the proper way to interpolate a variable in a script tag? https://gist.github.com/das3in/2fb3799b37f8eabda3a4 keep getting "Uncaught SyntaxError: Unexpected token ILLEGAL" in the console
[22:02:50] one_zero: has joined #RubyOnRails
[22:03:24] petricore: has joined #RubyOnRails
[22:03:41] smathy: das3in, using the ERB tags, many examples here: http://devdocs.io/rails/erb/util
[22:06:22] VeryBewitching: chipotle: You can browse rubygems at https://rubygems.org/
[22:08:35] snockerton: has joined #RubyOnRails
[22:08:37] Radar: das3in: You're missing quotes here https://gist.github.com/das3in/2fb3799b37f8eabda3a4#file-_stats-html-erb-L7
[22:09:17] waseem_: chipotle: I think you're moving in opposite direction. As you progress and develop application, you'll feel the need to do something. At that point you'll probably search how to do that thing and you will stumble upon gems/libraries that help yo do that specific thing.
[22:09:58] snockerton: has left #RubyOnRails: ()
[22:10:11] Inoperable: has joined #RubyOnRails
[22:10:16] waseem_: chipotle: Several gems are released everyday, you can't keep everything in your brain. Well, you could but then you'd be in wrong profession.
[22:10:21] VeryBewitching: chipotle: I haven't encountered much there isn't a gem for.
[22:12:04] eggie5: has joined #RubyOnRails
[22:12:35] blackmesa: has joined #RubyOnRails
[22:13:52] ivanskie: has joined #RubyOnRails
[22:16:34] j_mcnally: has joined #RubyOnRails
[22:17:53] chipotle: so can you run your own appserver? or is it not recommended? phusion runs the webserver and appserver for rails apps, according to the frontpage, and i'm sure it cost smoney
[22:19:15] Radar: it's free
[22:19:53] Radar: If you're starting out, I recommend using Heroku which does it all for you. If you're possessed by something that is forcing you to do it yourself, then Passenger (with the nginx option selected) is the best way
[22:20:15] jgt: has joined #RubyOnRails
[22:20:37] chipotle: and why not unicorn?
[22:20:49] Radar: because it is more complicated to set up
[22:21:13] ngscheurich: has joined #RubyOnRails
[22:22:04] chipotle: phusion says they are 4x as fast as unicorn, is that true?
[22:22:27] Radar: Depends on the configuration.
[22:22:58] atmosx: Radar: hm, that should be a straight forward comparison: same hardware, test the load (same number of requests).
[22:23:07] atmosx: isn't puma faster than univorn anyway?
[22:23:13] ivanskie: has joined #RubyOnRails
[22:23:25] chipotle: yeah that's what i figure Radar
[22:23:29] Radar: *shrugging intensifies*
[22:24:11] blackmesa: has joined #RubyOnRails
[22:25:27] waseem_: Well, Vim is better than Emacs.
[22:25:34] yfeldblum: has joined #RubyOnRails
[22:25:41] Radar: That might be true but Sublime Text 3 is better than both :)
[22:26:08] deavid: has joined #RubyOnRails
[22:26:11] Radar: Well, at least I know that Stripe's support won't leave me hanging for TWO WHOLE WEEKS.
[22:26:18] Radar: Fucking hell, Braintree. Getting more PayPal'ish everydayl
[22:26:46] Inoperable: has joined #RubyOnRails
[22:27:04] Radar: I could just rm -rf the Braintree chapter from MTWRv2 right now and not give any shits.
[22:27:14] pjammer: has joined #RubyOnRails
[22:27:14] a1fa: :popcorn
[22:27:43] Radar: "Hi, I would like to advise almost 2,000 people to use your platform for their SaaS systems. Could you please help me with this minor thing?"
[22:27:59] Radar: *silence*
[22:32:07] michael_mbp: has joined #RubyOnRails
[22:32:41] mary5030_: has joined #RubyOnRails
[22:32:44] chipotle: Radar: i love sublime but a lot of people have jumped ship and gone to atom
[22:32:50] chipotle: i dont get why they'd want to use it, it is SLOW
[22:32:55] Radar: chipotle: I'd like atom if it didn't hang when I was trying to type.
[22:33:07] Radar: Must be because I don't have a 64-core machine
[22:33:18] chipotle: they defintely have more plugins
[22:33:24] Radar: If it was written in a real language like Elixir then it wouldn't be slow.
[22:33:34] Radar: You don't need all the fancy bells and whistles. It's a text editor!
[22:34:14] shinnya: has joined #RubyOnRails
[22:34:21] rakm: has joined #RubyOnRails
[22:35:50] baweaver: has joined #RubyOnRails
[22:36:57] podman: has joined #RubyOnRails
[22:37:56] mary5030: has joined #RubyOnRails
[22:39:29] Papierkorb: has joined #RubyOnRails
[22:39:38] hooper1: has joined #RubyOnRails
[22:39:52] arBmind: has joined #RubyOnRails
[22:40:52] xcv: has joined #RubyOnRails
[22:41:14] model-help: has joined #RubyOnRails
[22:41:35] safety_cut: has joined #RubyOnRails
[22:41:46] darrencauthon: has joined #RubyOnRails
[22:42:10] moeabdol: has joined #RubyOnRails
[22:42:27] [gmi]: has joined #RubyOnRails
[22:42:50] abolishme: has joined #RubyOnRails
[22:45:55] model-help_: has joined #RubyOnRails
[22:47:22] rushed: has joined #RubyOnRails
[22:48:04] xcv: has joined #RubyOnRails
[22:49:02] VeryBewitching: Atom is a lot of software to save text/plain I have to agree.
[22:49:19] zendrix: has joined #RubyOnRails
[22:49:38] EminenceHC: has joined #RubyOnRails
[22:50:14] gizmore: has joined #RubyOnRails
[22:50:19] johnflux: has joined #RubyOnRails
[22:50:19] johnflux: has joined #RubyOnRails
[22:50:55] johnflux: has joined #RubyOnRails
[22:51:41] benlieb: has joined #RubyOnRails
[22:52:16] gizmore: i have a table of tracked working times... userid, begin_at, leave_at .... i want to query the closest time to a given day... like this
[22:52:16] gizmore: Businesstime.select('users.id, username').select("abs(begin_at - '#{date}') as dist1").select("abs(leave_at - '#{date}') as dist2").select("min(dist1, dist2) as dist3").joins(:user).group(:user_id).order('dist3')
[22:52:47] gizmore: any better ideas... and would it work at all? :P
[22:53:17] mary5030_: has joined #RubyOnRails
[22:54:11] zendrix: has joined #RubyOnRails
[22:54:29] benlieb: has left #RubyOnRails: ()
[22:55:30] diegoviola: has joined #RubyOnRails
[22:55:40] baweaver: date = "');DROP TABLE Users;--"
[22:56:06] diegoviola: https://github.com/diegoviola/movies/commit/a7a7cb7e71f014b811f7f59096f65bc8bacb1dce <-- is this ok to do or acceptable? or is there a better place to have those links?
[22:56:12] gizmore: date = DateTime.parse(params[:date]).at_midday
[22:57:07] gizmore: baweaver: i guess it??s time for a language where );DROP TABLE Users;--" turns into 12.Mar.1998
[22:57:25] gizmore: and the other way round!
[22:57:36] a1fa: mah baby tables
[22:58:10] baweaver: I'm saying if date is a user param at all, you're wide open for an injection attack like that.
[22:58:23] baweaver: besides, mysql dates start with year
[22:59:30] baweaver: the only thing in that query is that you can use multiple strings in one select as comma seperated
[22:59:53] rromanch_: has joined #RubyOnRails
[23:00:21] sanjayu: has joined #RubyOnRails
[23:00:48] njero: has joined #RubyOnRails
[23:00:53] diegoviola: any ideas please?
[23:01:21] stannard: has joined #RubyOnRails
[23:01:31] ruby-lang045: has joined #RubyOnRails
[23:03:03] ruby-lang045: Say that I have products and they can fall into 3 tiers of pricing ($10, $20, $30). What's the best way to model that?
[23:03:05] OnkelTem: has joined #RubyOnRails
[23:03:50] ruby-lang045: I was thinking something like Product has_one price and Price belongs_to product
[23:03:53] mary5030: has joined #RubyOnRails
[23:04:08] simplyianm: has joined #RubyOnRails
[23:04:11] atmosx: ruby-lang045: you sure you want to do that at model level?
[23:04:28] ruby-lang045: where would you suggest doing it?
[23:04:35] atmosx: ruby-lang045: controller helper
[23:04:54] ruby-lang045: how would that method look?
[23:05:00] gizmore: this might work in raw mysql: SELECT users.id, users.username, LEAST(ABS(DATEDIFF(begin_at, '2015-10-02')), ABS(DATEDIFF(leave_at, '2015-10-02'))) dist FROM `businesstimes` b JOIN users ON users.id = b.user_id GROUP BY users.id ORDER BY dist ... now to activerecord it :)
[23:05:05] Radar: How is this a controller method?
[23:05:06] ruby-lang045: like def price
[23:05:12] atmosx: ruby-lang045: it's just that this, looks like something that might change at any point
[23:05:27] Radar: ruby-lang045: ALL products are either 10, 20 or 30?
[23:05:40] ruby-lang045: that may or may not change
[23:05:46] gizmore: ruby-lang045: maybe you should create a table price ranges with min,max
[23:05:53] RegulationD: has joined #RubyOnRails
[23:06:02] ruby-lang045: and there may be other attributes beside price that is associated with the tier
[23:06:14] ruby-lang045: like if a product is tier 3, maybe it has free shipping
[23:06:22] ruby-lang045: and it costs $30
[23:07:03] lbs2015: has joined #RubyOnRails
[23:07:21] stannard: has joined #RubyOnRails
[23:07:40] ruby-lang045: thoughts @radar @atmosx?
[23:08:09] Radar: just assign products a price as a field
[23:09:05] chipotle: people here recommend http://jekyllrb.com/ for a blog, but what if you want dynamic blocks on the page, like comments, or recent posts or top posts, etc?
[23:09:19] ruby-lang045: but the tier of product may have lots of additional stuff on it beyond just price
[23:09:43] ruby-lang045: and what if I wanted to mass update price? would I do a look up on all the 30s and update them to say, 50?
[23:10:04] Radar: ruby-lang045: !g yagni
[23:10:17] Radar: Sorry my crystal ball is broken right now
[23:10:28] ruby-lang045: I guess my real question is how to handle the association of tiers to products
[23:10:35] atmosx: chipotle: comments can be added using an external plugin (disqus for example) and the other things you mentioned are build upon creation... it's a static site generator.
[23:10:36] mloy: Maybe apply a price to each tier and store a price modifier for each product in the tier?
[23:10:47] diegoviola: https://github.com/diegoviola/movies/blob/master/app/helpers/application_helper.rb#L2-L8 <-- is there a better way to do this? I'm using this method in my layout
[23:10:49] atmosx: chipotle: if jekyllrb is too barebones try middleman or octopress
[23:11:01] Radar: diegoviola: seems fine to me
[23:11:06] diegoviola: Radar: thanks
[23:11:56] mloy: ruby-lang045, wouldn't each product belong_to one tier and each tier has_many products?
[23:12:14] atmosx: ruby-lang045: I have the feeling that you're over-engineering :-)
[23:12:34] zendrix: has joined #RubyOnRails
[23:12:52] ruby-lang045: yea @mloy that's what I was originally thinking. You're right on the has_many
[23:13:06] ruby-lang045: @atmosx haha, maybe
[23:13:57] Radar: ruby-lang045: definitely
[23:14:00] Radar: products have prices
[23:14:04] Radar: or at best, tiers have prices
[23:15:19] ruby-lang045: if tiers have prices, is there an easy way to access the price through the tier? would the :through keyword work?
[23:15:36] devdazed: has joined #RubyOnRails
[23:15:43] ruby-lang045: product has_one tier, tier has_many products
[23:15:58] atmosx: ruby-lang045: yes
[23:15:58] ruby-lang045: product has_one price, :through => tier?
[23:15:58] Trynemjoel: has joined #RubyOnRails
[23:16:12] ascarter: has joined #RubyOnRails
[23:16:23] Radar: tier has a field
[23:16:24] Radar: called price
[23:16:27] Radar: which has an amount
[23:16:34] smathy: ruby-lang045, !associations
[23:16:34] helpa: ruby-lang045: http://guides.rubyonrails.org/association_basics.html - Active Record Association Basics by Mike Gunderloy
[23:16:47] abolishme: has left #RubyOnRails: ("Textual IRC Client: www.textualapp.com")
[23:17:49] ascarter: has joined #RubyOnRails
[23:17:54] ruby-lang045: If I have an instance of a product in that case, what's the easiest way to get the price through its tier association?
[23:18:11] Radar: ruby-lang045: product.tier.price
[23:18:39] ruby-lang045: got it, thanks!
[23:18:46] Synthead: I created an ActiveJob using the guide: http://edgeguides.rubyonrails.org/active_job_basics.html
[23:19:32] Synthead: In the rails console, when I run GuestsCleanupJob.perform_later (like instructed), I get "undefined method `????queue_as' for GuestsCleanupJob:Class"
[23:19:37] Synthead: why is this?
[23:20:12] smathy: Synthead, you did something wrong.
[23:20:27] Synthead: smathy: clearly
[23:20:41] ruby-lang045: do you have a self.queue_as method?
[23:20:47] ruby-lang045: you might have forgotten the self
[23:21:12] smathy: Synthead, are you using Rails edge?
[23:21:15] Synthead: ruby-lang045: no. the guide doesn't mention it, though; do I have to use it?
[23:21:42] Synthead: smathy: no, just rails
[23:21:48] Synthead: smathy: 4.2.0
[23:22:01] smathy: Synthead, well then for starters, you should have been using http://guides.rubyonrails.org/active_job_basics.html not the edge guides.
[23:22:22] xcv: ruby-lang05: So you want to update all products with a price > n?
[23:22:30] smathy: Synthead, but none of that would really explain why/how something was looking for a method with two leading spaces in its name.
[23:23:15] workmad3: has joined #RubyOnRails
[23:23:17] ruby-lang045: @xcv, if I did, what would you recommend?
[23:23:42] charliesome: has joined #RubyOnRails
[23:24:02] Synthead: smathy: this is app/jobs/update_cache.rb: http://pastie.org/10457197
[23:24:53] diegoviola: has joined #RubyOnRails
[23:25:05] xcv: ruby-lang045: I'd do it via a single UPDATE, e.g. via http://apidock.com/rails/ActiveRecord/Base/update_all/class.
[23:25:16] xcv: The problem with that is if you have post-save callbacks on your model.
[23:25:33] xcv: Since that requires instantiating each one to trigger the callbacks.
[23:25:46] ruby-lang045: ah...good point
[23:26:04] xcv: But if you haven't written a lot of code around that, I recommend putting it in a static method that takes an array of product ids and can perform the post-save operations in bulk.
[23:26:31] smathy: Synthead, did you actually paste the error you mentioned above?
[23:26:42] smathy: Synthead, like it really has: ` queue_as`
[23:26:43] xcv: The coupling of the callback logic to the particular lifecycle operation of a single model turns out to be a bit problematic once things grow in complexity and you'd like to utilize that code elsewhere without touching each instance.
[23:26:49] Synthead: smathy: yes
[23:27:05] smathy: Synthead, ok, then maybe there's some character that looks like a space but really isn't.
[23:27:14] smathy: Synthead, delete the queue_as line and type it again in your editor.
[23:27:55] smathy: Sometimes when you copy from some programs things that look like spaces but aren't are copied. Skype does this.
[23:27:59] smathy: (or used to at least)
[23:28:06] Synthead: smathy: oh my god... that was it. "retab" didn't even do it (vim).
[23:28:22] Synthead: smathy: I selected a non-whitespace "space" and replaced it with space
[23:28:25] Synthead: smathy: it works now :)
[23:28:28] smathy: Synthead, cool :)
[23:28:47] Synthead: smathy: by the way, this was copy/pasted from http://edgeguides.rubyonrails.org/active_job_basics.html
[23:28:48] smathy: Synthead, you're the poster child for why we like actual pasted errors.
[23:29:00] Synthead: smathy: seems like they have some funky formatting there
[23:29:05] jgt: has joined #RubyOnRails
[23:29:27] smathy: Synthead, yeah, some &nbsp;s maybe.
[23:29:51] Synthead: smathy: yeah, that's it. seems like it should be copied as spaces... maybe it's some wacky utf8 stuff
[23:30:09] blackhuey: has joined #RubyOnRails
[23:31:09] highcup: has joined #RubyOnRails
[23:31:45] xcv: ruby-lang045: Also, f you ever need to dynamically generate complex queries with lots of joins and subqueries e.c., I highly recommend Sequel: http://sequel.jeremyevans.net/
[23:32:57] xcv: *e.t.c.
[23:33:50] charliesome: has joined #RubyOnRails
[23:34:05] thejamespinto_: has joined #RubyOnRails
[23:37:11] yaymukund: has joined #RubyOnRails
[23:39:11] ruby-lang045: Radar: for products, if I want them to either have a % off or flat value off, what's the best way to represent that?
[23:39:17] simplyianm: has joined #RubyOnRails
[23:39:29] ruby-lang045: let's assume that there are no tiers and I simply have the base_price on the Product now
[23:39:36] charliesome: has joined #RubyOnRails
[23:39:52] charliesome: has joined #RubyOnRails
[23:39:59] atomical: has joined #RubyOnRails
[23:41:11] smathy: discount_amount discount_type
[23:41:38] ruby-lang045: would discount_type be a string or an enum?
[23:41:54] ruby-lang045: and what would the method be like to calculate the right price?
[23:42:04] diegoviola: has joined #RubyOnRails
[23:42:15] yfeldblum: has joined #RubyOnRails
[23:42:53] manfrin`laptop: has joined #RubyOnRails
[23:43:11] smathy: Yes, a string or an enum (or both).
[23:43:51] yfeldblum: has joined #RubyOnRails
[23:44:18] smathy: def discount; discount_type == :percentage ? price * discount_amount : discount_amount; end
[23:45:05] ruby-lang045: smathy: don't you think `discount_amount` would be confusing for other developers if 50 could represent either a percent or a dollar amount?
[23:45:26] ruby-lang045: thanks for that example though!
[23:46:49] Maletor: has joined #RubyOnRails
[23:48:03] smathy: ruby-lang045, if you're afraid it will be interpreted always as the non-percentage then call it discount_quantity or discount_value or something less "amount"-ish.
[23:48:22] chipotle: who posted whatdoitest.com for ruby testing? they did it about an hour ago but can't find it in scrollback
[23:48:22] ruby-lang045: yea, I like that, thanks
[23:48:35] chipotle: atmnvm, it was in offtopic
[23:49:29] simkessy: Hi everyone, i'm running into the Cookie Overflow exception preventing me from logging in using Google auth. Is "active_record_store" still the best solution to fix this?
[23:52:13] smathy: simkessy, yes.
[23:52:42] simkessy: smathy: great thx
[23:55:07] pwnd_nsfw: I love when things are working correctly, but tests aren't passing
[23:55:30] bricker: pwnd_nsfw: you love that?
[23:55:35] bricker: that's a weird thing to love
[23:56:00] FailBit: I love how you perceive sarcasm
[23:56:02] pwnd_nsfw: I'm a little.... "weird"
[23:56:02] smathy: I've been working through that for a week now.
[23:56:16] smathy: 90% of the problems, too much coupling in factories.
[23:56:47] idd2d: has joined #RubyOnRails
[23:57:08] FailBit: I've been fucking around with my rails app and poking things to see if that makes it faster
[23:57:17] FailBit: (so far I've been fruitful)
[23:58:22] Cervajz: has joined #RubyOnRails
[23:58:37] rickmasta: has joined #RubyOnRails
[23:59:03] pwnd_nsfw: FailBit, I heard if you put fire on the end of your poking stick, it sort of works
[23:59:51] xcv_: has joined #RubyOnRails