Activity Graph

Page 1 of 1


[01:24:10] newton: Ping timeout: 276 seconds
[01:29:06] newton: has joined #RubyOnRails


[06:50:38] newton: *.net *.split
[07:16:18] newton: has joined #RubyOnRails
[08:26:26] newton: *.net *.split
[08:36:47] newton: has joined #RubyOnRails


[06:08:03] newton: *.net *.split
[06:18:25] newton: has joined #RubyOnRails


[04:23:59] newton: has joined #RubyOnRails


[22:09:35] newton: has left #RubyOnRails: ("RuntimeError")


[16:49:51] newton: *.net *.split


[22:52:38] newton: *.net *.split


[23:24:04] newton: could someone point me in the right direction with inverse_of? should I be expecting the query to not make the second Person called?
[23:24:24] newton: s/called/call
[23:26:22] newton: lol nvm. there was another has_many :listings hidden in some other code messing itup


[21:09:50] newton: has joined #RubyOnRails
[21:11:33] newton: is there something different from `as` where I can tell a nested resources to generate routes like "new_y_path" rather than "new_x_y_path"?


[08:23:05] newton: has left #RubyOnRails: ("RuntimeError")


[19:21:51] newton: is there a place I could learn more about the differences between using Rails.cache and the `cache` helper inside of a view?
[19:33:06] newton: (nvm read the context helper doc and learned more about the stuff it does)


[19:50:17] newton: with eager loading (I'm assuming it's related) is there any reliable way to get the instance methods of a model?
[19:50:54] newton: doing Model.instance_methods(false) returns an empty array in a lot of cases, unsure if there is another way I can go about this


[02:42:51] newton: *.net *.split
[18:03:04] newton: has joined #RubyOnRails


[22:35:01] newton: timwis, instance method sounds fine considering the scope is that user anyway
[22:35:08] newton: Quit: :wave:
[22:35:26] newton: has joined #RubyOnRails
[22:36:43] newton: timwis, it's also available on the instance
[22:36:47] newton: context matters a little
[22:38:11] newton: oh jeez - I'm wrong, I don't know where my head is :(
[22:39:28] newton: you could do it either way really then. you could implement it on the user and have it just call to handle the query, or make it a class method you pass the user to
[22:53:50] newton: not sure if there is a name for the problem - I'd assume stuff like this is pretty opinionated. If the logic is big or complex, you might consider turning it into a service (another class) that handles it


[06:44:19] newton: Remote host closed the connection
[06:44:35] newton: has joined #RubyOnRails


[00:07:28] newton: *.net *.split
[00:15:24] newton: has joined #RubyOnRails


[04:29:25] newton: Ping timeout: 245 seconds
[16:53:46] newton: has joined #RubyOnRails


[02:46:55] newton: *.net *.split
[02:47:45] newton: has joined #RubyOnRails
[02:50:04] newton: *.net *.split
[02:50:33] newton: has joined #RubyOnRails


[19:45:22] newton: Quit: :wave:
[19:45:39] newton: has joined #RubyOnRails


[12:13:38] newton: Ping timeout: 276 seconds
[20:08:50] newton: has joined #RubyOnRails


[12:25:58] newton: *.net *.split
[12:27:34] newton: has joined #RubyOnRails
[15:01:29] newton: *.net *.split
[15:03:04] newton: has joined #RubyOnRails


[03:05:56] newton: Ping timeout: 276 seconds
[03:07:20] newton: has joined #RubyOnRails


[05:34:22] newton: Ping timeout: 245 seconds
[05:35:27] newton: has joined #RubyOnRails


[17:46:52] newton: is it possible to have ActionCable broadcasts be different depending on the subscriber it's sending to? eg anonymize input for only some subscribers


[17:48:23] newton: Remote host closed the connection
[17:48:47] newton: has joined #RubyOnRails


[20:14:27] newton: has joined #RubyOnRails
[20:15:07] newton: is there a way I can have find not convert a string like '9abcd' to 9 and treat it like the actual id being requested?
[20:17:54] newton: havenwood: yes, like the usual RecordNotFound
[20:20:49] newton: thank you
[20:24:41] newton: it's funny because find_by!('9abc') is actually giving me what I want but the query is clearly weird
[20:26:35] newton: oh lol nvm


[18:07:20] newton: Ping timeout: 256 seconds


[17:29:48] newton: has joined #RubyOnRails


[03:30:05] newton: *.net *.split
[03:31:30] newton: has joined #RubyOnRails


[19:13:09] newton: Ping timeout: 250 seconds
[19:42:14] newton: has joined #RubyOnRails


[20:31:14] newton: *.net *.split
[20:47:57] newton: has joined #RubyOnRails


[10:09:58] newton: *.net *.split
[10:15:25] newton: has joined #RubyOnRails


[11:54:58] newton: Ping timeout: 264 seconds
[11:55:49] newton: has joined #RubyOnRails


[23:52:30] newton: if I have a rails app on, is it possible to have `Request#subdomain` treat sub as a subdomain?
[23:52:45] newton: `Rack::Request` even
[23:53:41] newton: *not treat :^)


[06:26:47] newton: has joined #RubyOnRails


[21:46:33] newton: Ping timeout: 252 seconds
[21:49:02] newton: has joined #RubyOnRails


[18:38:25] newton: *.net *.split


[23:51:23] newton: *.net *.split
[23:56:32] newton: has joined #RubyOnRails


[09:16:15] newton: has joined #RubyOnRails
[09:16:15] newton: Ping timeout: 276 seconds


[05:22:24] newton: Ping timeout: 240 seconds


[17:56:53] newton: EPic_Null: your css is invalid
[17:57:46] newton: EPic_Null: "headr" means the element "headr" vs doing ".headr" which is a proper css class


[00:17:40] newton: *.net *.split
[00:22:43] newton: has joined #RubyOnRails


[08:30:47] newton: has joined #RubyOnRails
[16:35:41] newton: Remote host closed the connection
[16:37:50] newton: has joined #RubyOnRails


[16:41:13] newton: *.net *.split
[16:52:26] newton: has joined #RubyOnRails


[15:10:52] newton: *.net *.split
[17:00:54] newton: has joined #RubyOnRails


[08:41:21] newton: has left #RubyOnRails: ()


[01:04:04] newton: *.net *.split
[23:10:45] newton: Ping timeout: 240 seconds


[18:27:24] newton: has joined #RubyOnRails


[10:25:09] newton: Ping timeout: 250 seconds
[10:45:00] newton: has joined #RubyOnRails
[18:13:56] newton: Ping timeout: 240 seconds


[17:42:16] newton: *.net *.split


[15:38:39] newton: *.net *.split
[16:47:59] newton: has joined #RubyOnRails
[19:59:17] newton: Read error: Connection reset by peer
[20:06:14] newton: has joined #RubyOnRails


[08:13:11] newton: has joined #RubyOnRails
[08:24:53] newton: has joined #RubyOnRails
[08:24:53] newton: Changing host
[08:37:53] newton: Ping timeout: 240 seconds
[19:01:58] newton: *.net *.split


[01:43:42] newton: Ping timeout: 252 seconds
[01:45:15] newton: has joined #RubyOnRails
[16:17:07] newton: Ping timeout: 240 seconds


[02:41:36] newton: Remote host closed the connection
[12:29:38] newton: has joined #RubyOnRails


[15:35:21] newton: *.net *.split
[16:21:37] newton: has joined #RubyOnRails


[19:05:41] newton: Ping timeout: 268 seconds
[19:07:20] newton: has joined #RubyOnRails


[00:16:35] newton: has joined #RubyOnRails


[22:22:33] newton: Remote host closed the connection
[23:19:46] newton: has joined #RubyOnRails


[07:43:52] newton: has joined #RubyOnRails


[03:28:15] newton: Ping timeout: 246 seconds
[03:31:09] newton: has joined #RubyOnRails


[23:37:36] newton: Ping timeout: 250 seconds
[23:39:20] newton: has joined #RubyOnRails


[00:14:17] newton: is there a way to "find by subject" when subject is polymorphic?
[00:19:45] newton: bricker: figured. thanks.


[17:53:02] newton: has joined #RubyOnRails
[17:54:43] newton: I have a controller (resources) called BookmarksController, and only need index, create, and destroy. Is it possible to have destroy NOT need to be bookmarks/:id? Just be on /bookmarks like destroy does on a singular resource?
[17:56:03] newton: smathy: using ajax, so the data passes as params in DESTROY would contain the info I need
[17:56:21] newton: smathy: and that data won't really know the bookmark id, it just knows the subject info (polymorphic assoc) so we can find it
[17:57:09] newton: wouldn't I kind of be bsing the id in the call then?
[17:57:49] newton: ah sorry :)
[18:03:08] newton: tfitts: I guess that's an option, but I'd to keep it condensed down to interacting with the bookmarks controller if possible.
[18:03:25] newton: because the subject(s) in general don't really know about bookmarks


[05:34:42] newton: with TCPSocket, is there a way to specify socket.puts length when sending?


[20:55:44] newton: if I have a resource's path set to /, and a root - will I really be looking at any clashing issues? (root goes to the resource's index anyway)


[01:28:22] newton: I've got a strange issue with sqlite-ruby making a query: - has anyone seen something like this? if I nick = 'newton', it also works. :s
[01:30:39] newton: I put it in the db before running :(
[05:32:56] newton: redmaverick: this might help a bit more with ruby sandboxing
[05:33:12] newton: er, protecting from unsafe stuff, not sandboxing persay
[14:54:35] newton: Brycetron: have you read
[14:55:15] newton: how are you having trouble with it
[14:56:39] newton: Brycetron: you need to add gem 'devise' to your Gemfile, then run `bundle` in the rails app root directory via console
[14:58:18] newton: if you haven't used rails new <your project name> then yes, you need to do that first
[14:59:01] newton: lower case b
[15:01:48] newton: I'm not sure how to deal with that error on windows :(
[15:02:06] newton: yeah, when you run bundle it'll read the Gemfile to know what to install
[15:02:16] newton: is your console cd'd into the rails app?
[15:02:34] newton: yeah, you need to do these commands /inside/ your rails app
[15:02:57] newton: so if your app is in C:\someguy\todoapp cd into that and run bundle


[09:01:21] newton: use scaffolding!
[09:01:23] newton: ACTION runs


[19:56:52] newton: bricker's street cred is on the line now


[17:31:44] newton: is there a config option for simply changing the rails log directory? or is it really as complicated as google makes it look?


[18:22:34] newton: is there a method somewhere like python's urllib.quote that'll change stuff like #hashtag to %23hashtag etc?
[18:24:16] newton: apeiros: any idea what the method is off the top of your head :)?
[18:26:21] newton: Rylee: bingo


[20:24:58] newton: phelps: +1 newton
[20:25:07] newton: ... +1 phelps
[20:26:39] newton: I bet w2schools would use scaffolding to teach rails


[17:39:26] newton: what's the syntax instance.(...) typically used for?
[17:39:58] newton: I know this is calling on 'call', but is this a different kind of call then
[17:41:00] newton: jhass: does traditionally have a specific use?
[17:41:07] newton: er,
[17:43:04] newton: slowcon: example of jbuilder using it
[22:59:22] newton: vim right? right!


[20:00:32] newton: is there any way to execute something before Model#where is called?
[20:03:06] newton: bricker: is there any way to override where within a Model to make it do stuff then continue
[20:06:46] newton: chrislerum: in general, I'd just like to do something before where does the rest of it's business
[20:06:54] newton: not nessicarily anything database related
[20:07:05] newton: for the sake of example, setting a variable I could access somewhere else in the mode
[20:08:08] newton: pipework, chrislerum: the goal here is to literally get into where
[20:09:33] newton: I guess I can't just get feedback on this without opinions on "how else to do it"
[20:10:39] newton: chrislerum: basically I want to def where(*args); do_something; super; end, but so far it doesn't look like it's that easy
[20:10:43] newton: chrislerum: or I'm doing something wrong :)
[20:15:34] newton: rhizome: yeah


[21:16:53] newton: in scope (for routing), it's doing scope(options) { yield } in namespace - this is yielding the block passed to namespace to scope right?


[08:44:57] newton: lxsameer: there is stuff like jekyll, octopress, refinery
[08:47:03] newton: lxsameer: refinery falls under that
[08:48:36] newton: lxsameer: also radiant cms
[09:10:51] newton: yeah, resources can take a path option
[09:11:55] newton: you could do match '/:id', to: 'campaigns#show' or similar
[09:12:28] newton: s/match/get
[09:14:14] newton: dsftw: ^ and I guess you could hit up stackoverflow
[09:14:35] newton: dsftw: also if you posted what your issue was in general :P
[09:18:13] newton: dseitz: I think that is pretty subjective, lol
[09:19:00] newton: I figured just take out the "not too" ;P
[09:19:30] newton: n88: content_for mayhaps


[03:15:32] newton: I've got a bit of js (coffee) written to 'save' a blog post when I stop typing, and for some reason seeing it saved multiple times - looking further I found that for some reason the ajax request is being processed twice, one as js and once as json
[03:15:40] newton: would anyone have input on the double-processing?
[03:16:40] newton: tubbo: json
[03:20:25] newton: tubbo: ah, okay. thanks for pointing that out - will refactor that whole bit and see if it helps.
[03:20:41] newton: what I had in my head was setup event -> submit form -> get rid of event
[03:23:09] newton: tubbo: I got rid of the submit binding altogether and it works - thanks again.


[05:56:07] newton: anyone happen to know if there is a shortcut to make a specific coffee file not do the (function() bit around code in the file?


[04:39:46] newton: Has anyone recently doing anything with devise & a custom FormBuilder? I'm trying to figure out if it's possible to get the submission errors in the FormBuilder. (currently object.errors has nothing after a failed submission :()
[04:40:34] newton: sevenseacat: specifically sign in
[04:40:39] newton: sec @ code, will gist
[04:41:19] newton: wasn't planning on being specific
[04:41:51] newton: that's not really relevant to the question
[04:42:08] newton: but the sign in not setting form errors makes sense, so thanks


[21:02:00] newton: Does anyone know what == does in HAML? I'm having issues finding it in their documentation. (ex: %span== ...)
[21:04:40] newton: t27duck: awesome, thanks
[21:05:27] newton: in this case - I'm using HAML in jekyll and have to use == for the liquid bits


[02:33:21] newton: (rails 4): if I have lib/name_space/file.rb, wouldn't it load as NameSpace::File in the application by default?
[02:59:29] newton: what would the most appropriate place to put something like a utility module (like App::Regex containing a bunch of methods, that would be used in various places in the app) be best put?
[03:01:29] newton: ciopte7: this would be used in models mainly


[04:32:55] newton: butblack, I'm about to run so I can't help much on this - but you're going to have to use js if you want to have the time change depending on the TZ of who is viewing
[17:27:03] newton: zomg, could you gist the test?


[19:54:22] newton: scottschulthess, try using resource_params rather then params[:resource] in @resource
[19:58:46] newton: scottschulthess, if you look at the comments in the example, you'll see that they say PeopleController#create is going to error
[19:58:56] newton: scottschulthess, the same error you're getting
[20:00:31] newton: scottschulthess, it happens :)


[21:48:07] newton: GreekFreak, you could still probably run passenger-install-nginx-module
[21:49:45] newton: GreekFreak, as in try running it anyway? :P
[22:01:34] newton: GreekFreak, okay, cool, that is good to know.