« Back to channel list

#RubyOnRails - 12 February 2016

« Back 1 day Forward 1 day »
[00:00:25] shilon: has joined #RubyOnRails
[00:01:02] one_zero: has joined #RubyOnRails
[00:01:58] maesitos: has joined #RubyOnRails
[00:03:25] swillits: Yeah, people type in bad links somewhat often.
[00:03:37] swillits: bad/uppercase.
[00:04:08] Devalo: has joined #RubyOnRails
[00:04:33] rodfersou: has joined #RubyOnRails
[00:04:53] mrbubbles: has joined #RubyOnRails
[00:05:36] srruby: has joined #RubyOnRails
[00:06:26] sarink: has joined #RubyOnRails
[00:06:30] smathy: I don't know that I've ever had an app where people typed in ANY part of the path, let alone using uppercase. So anyway, I'd solve *that* problem in your httpd and then you can use your route glob for your page 404.
[00:07:06] diegoviola: has joined #RubyOnRails
[00:08:32] jon31: has joined #RubyOnRails
[00:08:42] Lingo____: has joined #RubyOnRails
[00:11:34] srruby: acceptance testing: casperjs, phantomjs... Any ideas ? I'd rather not couple RoR with my test suite. Typical Rails3 crud application
[00:13:12] strassz: has joined #RubyOnRails
[00:13:29] peterevjan: has joined #RubyOnRails
[00:14:35] jlyndon_: has joined #RubyOnRails
[00:15:09] c355E3B: has joined #RubyOnRails
[00:15:09] tvw: has joined #RubyOnRails
[00:15:10] c355E3B: has joined #RubyOnRails
[00:15:22] kirillzh: has joined #RubyOnRails
[00:15:25] waldi_: has joined #RubyOnRails
[00:15:28] maesitos: has joined #RubyOnRails
[00:16:23] peterevjan: has joined #RubyOnRails
[00:16:44] dyce_: has joined #RubyOnRails
[00:17:00] Mchl: has joined #RubyOnRails
[00:17:50] ur5us: has joined #RubyOnRails
[00:18:14] ur5us: has joined #RubyOnRails
[00:22:47] M-shine: has joined #RubyOnRails
[00:23:12] Lingo____: has joined #RubyOnRails
[00:23:23] peterevjan: has joined #RubyOnRails
[00:25:18] ravster: has joined #RubyOnRails
[00:25:19] maesitos: has joined #RubyOnRails
[00:25:54] g3funk: has joined #RubyOnRails
[00:34:19] IFrank00: has joined #RubyOnRails
[00:37:00] milesmatthias: has joined #RubyOnRails
[00:37:12] treaki_: has joined #RubyOnRails
[00:38:08] ravster: has joined #RubyOnRails
[00:39:41] MaDErroR123: has joined #RubyOnRails
[00:39:52] Lingo____: has joined #RubyOnRails
[00:42:06] jottr: has joined #RubyOnRails
[00:43:40] Scripore: has joined #RubyOnRails
[00:45:35] ravster: has joined #RubyOnRails
[00:47:15] Axy: has joined #RubyOnRails
[00:49:08] nfk: has joined #RubyOnRails
[00:50:04] sleungcy: has joined #RubyOnRails
[00:50:53] RegulationD: has joined #RubyOnRails
[00:52:56] dyce_: has left #RubyOnRails: ()
[00:53:08] skyjumpe1: has left #RubyOnRails: ()
[00:53:29] skyjumper: has joined #RubyOnRails
[00:56:49] Lingo_____: has joined #RubyOnRails
[01:00:06] kirillzh: has joined #RubyOnRails
[01:00:36] maesitos: has joined #RubyOnRails
[01:02:11] kknight: has joined #RubyOnRails
[01:02:26] maesitos: has joined #RubyOnRails
[01:03:26] kknight: while bundle install i got error
[01:03:40] kknight: Bundler::GemspecError: Could not read gem at /home/ankit/.gem/ruby/2.3.0/cache/passenger-5.0.20.gem. It may be corrupted.
[01:03:56] ravster: has joined #RubyOnRails
[01:04:23] maesitos: has joined #RubyOnRails
[01:04:29] kknight: when i type gem install passenger-5.0.20
[01:04:45] kknight: then it gives ERROR: Could not find a valid gem 'passenger-5.0.20' (>= 0) in any repository
[01:04:45] kknight: ERROR: Possible alternatives: passenger, passenger-jmazzi, passenger-oob-gc, passenger-rails, passenger_dyno
[01:04:57] RegulationD: has joined #RubyOnRails
[01:05:28] kknight: has joined #RubyOnRails
[01:05:49] kknight: Bundler::GemspecError: Could not read gem at /home/ankit/.gem/ruby/2.3.0/cache/passenger-5.0.20.gem. It may be corrupted.
[01:06:01] kknight: when i type gem install passenger-5.0.20
[01:06:03] hardtail: has joined #RubyOnRails
[01:06:08] kknight: then it gives ERROR: Could not find a valid gem 'passenger-5.0.20' (>= 0) in any repository
[01:06:17] maesitos: has joined #RubyOnRails
[01:06:17] kknight: ERROR: Possible alternatives: passenger, passenger-jmazzi, passenger-oob-gc, passenger-rails, passenger_dyno
[01:07:28] gmas_: has joined #RubyOnRails
[01:08:16] maesitos: has joined #RubyOnRails
[01:09:00] baweaver: kknight: no need to repeat yourself
[01:09:08] baweaver: versioning for rubygems does not work that way.
[01:09:19] baweaver: gem install name -v version
[01:09:59] maesitos: has joined #RubyOnRails
[01:10:38] kknight: that is what i told in 06:36:00
[01:11:34] kknight: still it gives error
[01:11:45] Lingo_____: has joined #RubyOnRails
[01:11:55] kknight: should i exclude verison name?
[01:11:56] maesitos: has joined #RubyOnRails
[01:11:56] baweaver: gem install passenger -v '5.0.20'
[01:12:08] baweaver: there may not be such a version
[01:12:40] baweaver: just use gem install passenger
[01:12:58] kknight: ERROR: Could not find a valid gem 'passenger-5.0.20' (>= 0) in any repository
[01:13:04] kknight: ERROR: Possible alternatives: passenger, passenger-jmazzi, passenger-oob-gc, passenger-rails, passenger_dyno
[01:13:17] hardtail: has joined #RubyOnRails
[01:13:26] kknight: after gem install passwnger -v '5.0.20'
[01:13:41] baweaver: use it without a version
[01:13:50] peterevjan: has joined #RubyOnRails
[01:13:50] maesitos: has joined #RubyOnRails
[01:14:06] kknight: then bundle install
[01:14:12] emachnic: has joined #RubyOnRails
[01:15:40] maesitos: has joined #RubyOnRails
[01:16:43] symbol: has joined #RubyOnRails
[01:16:43] Cervajz: has joined #RubyOnRails
[01:17:20] peterevjan: has joined #RubyOnRails
[01:17:36] maesitos: has joined #RubyOnRails
[01:18:55] havenwood: kknight: bundle exec gem pristine passenger -v 5.0.20
[01:19:12] havenwood: ah, i just caught up on scrollback
[01:19:27] maesitos: has joined #RubyOnRails
[01:20:46] kknight: why we include pristine just curious sabout it?
[01:21:23] maesitos: has joined #RubyOnRails
[01:23:08] benlieb: has joined #RubyOnRails
[01:23:13] maesitos_: has joined #RubyOnRails
[01:24:40] ElFerna: has joined #RubyOnRails
[01:25:06] swillits: has left #RubyOnRails: ()
[01:25:09] allcentury: has joined #RubyOnRails
[01:25:15] maesitos: has joined #RubyOnRails
[01:25:46] havenwood: kknight: My IRC bouncer hadn't caught me up to current. Anyways, for info about the pristine command see: gem help pristine
[01:25:58] havenwood: kknight: Prefix `bundle exec` so it's your bundle.
[01:26:15] havenwood: kknight: Add the version with the -v or --version flag.
[01:26:49] macsteps: has joined #RubyOnRails
[01:26:56] renegadeandy: has joined #RubyOnRails
[01:27:00] maesitos: has joined #RubyOnRails
[01:28:54] maesitos_: has joined #RubyOnRails
[01:30:43] maesitos: has joined #RubyOnRails
[01:32:19] braian: has joined #RubyOnRails
[01:32:39] maesitos: has joined #RubyOnRails
[01:33:14] nettoweb: has joined #RubyOnRails
[01:33:22] kknight: now a new gem error says , do i have to install manually each gem
[01:33:58] kknight: havenwood?
[01:34:11] havenwood: kknight: Says what?
[01:34:32] maesitos_: has joined #RubyOnRails
[01:34:40] SteenJobs: has joined #RubyOnRails
[01:35:12] kknight: Could not find mail-2.5.4 in any of the sources
[01:35:13] kknight: Run `bundle install` to install missing gems.
[01:35:22] havenwood: kknight: Do as it says.
[01:35:25] havenwood: kknight: bundle
[01:35:47] havenwood: kknight: And prefix `bundle exec` to Rails and Rake commands.
[01:36:23] maesitos: has joined #RubyOnRails
[01:36:25] havenwood: kknight: http://bundler.io
[01:37:35] kknight: on bundle exec gem pristine passenger -v 5.0.20 it says again Could not find mail-2.5.4 in any of the sources
[01:37:36] kknight: Run `bundle install` to install missing gems.
[01:37:49] kknight: both step are comming again & again
[01:37:49] rafaelfranca: has joined #RubyOnRails
[01:37:51] adavia: any idea why i am not seeing the created event when visiting my root path in this test http://pastie.org/10718665
[01:38:20] maesitos: has joined #RubyOnRails
[01:38:27] kknight: havenwood:?
[01:38:29] triptec: has joined #RubyOnRails
[01:40:04] havenwood: kknight: I assumed you had passenger in your bundle because of the error. Do you?
[01:40:11] havenwood: kknight: Is it in your Gemfile?
[01:40:11] maesitos: has joined #RubyOnRails
[01:42:02] maesitos_: has joined #RubyOnRails
[01:42:27] kknight: havenwood: yes it is in gemfile
[01:42:55] Intii: has joined #RubyOnRails
[01:43:51] Intii: Hi everyone, I have a bunch of models in my rails app that using activeresource... One of the models, customer, has many addresses. My form has fields_for addresses but the addresses inputs never end up in customer params
[01:43:57] maesitos: has joined #RubyOnRails
[01:44:07] Intii: What am I doing wrong?
[01:45:35] neilfse: has joined #RubyOnRails
[01:45:52] maesitos: has joined #RubyOnRails
[01:47:44] maesitos: has joined #RubyOnRails
[01:47:51] Scripore: has joined #RubyOnRails
[01:48:39] superlou: has joined #RubyOnRails
[01:49:39] maesitos: has joined #RubyOnRails
[01:50:41] jamo: has joined #RubyOnRails
[01:51:31] maesitos: has joined #RubyOnRails
[01:51:56] kknight: even if i gem install passenger
[01:52:06] kknight: unable to convert "\x97" from ASCII-8BIT to UTF-8 for src/cxx_supportlib/vendor-modified/boost/utility/declval.hpp, skipping
[01:52:07] kknight: Done installing documentation for passenger after 33 seconds
[01:52:07] kknight: 1 gem installed
[01:53:23] stannard: has joined #RubyOnRails
[01:53:24] SteenJobs: hey guys - if i???m adding font assets to rails/i guess any web app, which file formats are generally recommended to have included? if there???s a better chat to ask this question in, that works too
[01:53:26] maesitos: has joined #RubyOnRails
[01:54:27] capin: SteenJobs: depends on what assets your referring too
[01:54:53] SteenJobs: capin: what do you mean?
[01:54:57] capin: rails can use vanilla JS / coffee script / CSS / SASS
[01:55:04] SteenJobs: ya not what i mean
[01:55:17] maesitos: has joined #RubyOnRails
[01:55:36] SteenJobs: font assets can come in various file types (woff, eot, svg, ttf, etc.)
[01:56:03] capin: ahhh, i'd recommend using font awesome ;)
[01:56:14] SteenJobs: not a file type...
[01:56:49] SteenJobs: and the rails asset pipeline, btw, can handle other asset types if configured properly - for example using custom font assets in my case
[01:57:03] SteenJobs: basically different browsers support/dont support various file types for fonts
[01:57:12] maesitos: has joined #RubyOnRails
[01:57:20] DLSteve: has joined #RubyOnRails
[01:59:06] maesitos: has joined #RubyOnRails
[01:59:54] adavia: any idea why i am not seeing the created event when visiting my root path in this test http://pastie.org/10718665
[02:01:01] maesitos: has joined #RubyOnRails
[02:02:48] pawnbox: has joined #RubyOnRails
[02:02:57] maesitos: has joined #RubyOnRails
[02:04:43] Devalo: has joined #RubyOnRails
[02:04:52] maesitos: has joined #RubyOnRails
[02:05:05] rhizome: adavia: you should probably have to visit the page first
[02:06:41] maesitos: has joined #RubyOnRails
[02:08:37] maesitos: has joined #RubyOnRails
[02:09:08] barhum2013: has joined #RubyOnRails
[02:10:29] maesitos: has joined #RubyOnRails
[02:11:13] IFrank00: has joined #RubyOnRails
[02:11:17] peterevjan: has joined #RubyOnRails
[02:12:24] maesitos: has joined #RubyOnRails
[02:13:57] Giddeon: has joined #RubyOnRails
[02:14:16] maesitos: has joined #RubyOnRails
[02:15:32] JoshGlzBrk: has joined #RubyOnRails
[02:16:14] maesitos: has joined #RubyOnRails
[02:16:34] mrbubbles: has joined #RubyOnRails
[02:17:06] Giddeon: has left #RubyOnRails: ()
[02:17:18] Giddeon: has joined #RubyOnRails
[02:18:09] maesitos: has joined #RubyOnRails
[02:18:42] adavia: rhizome: well those lines are uncommented
[02:20:02] maesitos: has joined #RubyOnRails
[02:20:56] adavia: i figured out that moving the FactoryGirl create method in the before block then i can see the content
[02:21:49] maesitos: has joined #RubyOnRails
[02:22:37] Giddeon: In Rails 4, I added 'lib' to config.autoload_paths in application.rb. Then I created a lib/string.rb file and added a single method to the string class. When I call that method in the console, I get an unknown method error. Can anyone explain why this is happening? Is it because the String constant is alreaady loaded, so it doesn't try and search the autoload_paths (and as a result,
[02:22:37] Giddeon: my new method is never picked up)? If I explicitly require the lib/string.rb file in an initializer, I'm able to get it the method loaded, but it feels like I'm doing it wrong.
[02:23:42] maesitos: has joined #RubyOnRails
[02:25:40] maesitos: has joined #RubyOnRails
[02:26:26] arBmind: has joined #RubyOnRails
[02:27:30] maesitos: has joined #RubyOnRails
[02:29:26] maesitos_: has joined #RubyOnRails
[02:30:42] peterevjan: has joined #RubyOnRails
[02:31:15] maesitos: has joined #RubyOnRails
[02:33:06] maesitos_: has joined #RubyOnRails
[02:35:04] maesitos: has joined #RubyOnRails
[02:36:54] maesitos: has joined #RubyOnRails
[02:37:56] sleungcy: has joined #RubyOnRails
[02:38:47] maesitos: has joined #RubyOnRails
[02:40:43] maesitos_: has joined #RubyOnRails
[02:41:21] Tarential: has joined #RubyOnRails
[02:41:36] hardtail: has joined #RubyOnRails
[02:41:40] hardtail: has joined #RubyOnRails
[02:42:34] maesitos: has joined #RubyOnRails
[02:42:36] KitsuneDrag0n: has joined #RubyOnRails
[02:42:37] KitsuneDrag0n: has joined #RubyOnRails
[02:44:06] emachnic: has joined #RubyOnRails
[02:44:12] Cervajz: has joined #RubyOnRails
[02:44:24] IFrank00: has joined #RubyOnRails
[02:44:28] maesitos: has joined #RubyOnRails
[02:46:19] maesitos_: has joined #RubyOnRails
[02:46:32] krz: has joined #RubyOnRails
[02:47:08] adavia: ohh let is lazy loaded
[02:48:11] maesitos: has joined #RubyOnRails
[02:50:04] maesitos_: has joined #RubyOnRails
[02:51:57] maesitos: has joined #RubyOnRails
[02:52:47] pawnbox: has joined #RubyOnRails
[02:53:48] maesitos: has joined #RubyOnRails
[02:55:43] maesitos_: has joined #RubyOnRails
[02:56:42] rhizome: Giddeon: you probably are. read up on monkey patching if you're really looking to open String
[02:57:37] maesitos: has joined #RubyOnRails
[02:59:29] moeabdol2: has joined #RubyOnRails
[02:59:41] maesitos: has joined #RubyOnRails
[02:59:46] bronson: has joined #RubyOnRails
[03:00:23] arup_r: has joined #RubyOnRails
[03:01:21] maesitos_: has joined #RubyOnRails
[03:01:46] laurenonthehill: has joined #RubyOnRails
[03:02:04] moeabdol3: has joined #RubyOnRails
[03:03:26] maesitos: has joined #RubyOnRails
[03:04:05] DmitryBochkarev: has joined #RubyOnRails
[03:04:29] laurenonthehill: Hello, I have a (possibly) dumb question. Is this the right place to ask for help?
[03:04:38] arup_r: laurenonthehill: yes
[03:05:09] maesitos: has joined #RubyOnRails
[03:05:32] ravster: has joined #RubyOnRails
[03:06:20] laurenonthehill: Awesome. So I have a worksheet model that has_many words. But words are not necessarily unique because of multiple meanings. At the moment a user makes a worksheet by giving a list of words, we then search for words that match and link all words that match to the worksheet with the has_many/belongs to relationship
[03:06:52] laurenonthehill: If I want users to choose one particular word record to link to (so they can get the definition correct) what's the best way to do it?
[03:06:55] rafaelfranca: has joined #RubyOnRails
[03:06:58] maesitos: has joined #RubyOnRails
[03:07:43] laurenonthehill: Simple example: the worksheet has "lie" and "cat" on. Lie comes up with two words with definitions, "lie down" and "not true". I want a way for the user to choose to only relate the worksheet to one of those meanings.
[03:07:59] p1k: has joined #RubyOnRails
[03:08:52] maesitos: has joined #RubyOnRails
[03:10:48] maesitos: has joined #RubyOnRails
[03:12:38] maesitos_: has joined #RubyOnRails
[03:14:34] maesitos: has joined #RubyOnRails
[03:16:28] maesitos_: has joined #RubyOnRails
[03:17:49] macsteps: has joined #RubyOnRails
[03:18:20] maesitos: has joined #RubyOnRails
[03:18:22] zenergi: has joined #RubyOnRails
[03:20:14] maesitos_: has joined #RubyOnRails
[03:22:00] kies^: has joined #RubyOnRails
[03:22:02] maesitos: has joined #RubyOnRails
[03:22:33] pawnbox: has joined #RubyOnRails
[03:23:58] maesitos: has joined #RubyOnRails
[03:24:19] chipotle: has joined #RubyOnRails
[03:25:53] maesitos: has joined #RubyOnRails
[03:27:06] ur5us: has joined #RubyOnRails
[03:27:45] maesitos: has joined #RubyOnRails
[03:28:12] kies^: has joined #RubyOnRails
[03:28:42] quazimodo: I want to share a couple of UI widgets across several apps that make up a service oriented platform
[03:28:54] quazimodo: thewidgets are like a menu & user edit box that slides out
[03:28:58] peterevjan: has joined #RubyOnRails
[03:29:24] peterevjan: has joined #RubyOnRails
[03:29:38] maesitos_: has joined #RubyOnRails
[03:29:42] quazimodo: I'm thinking i'll package them up as individual JS files using webpack and plonk them on the 'portal' service (the application that acts as the SSO provider) and have the other apps just load those script files via <script> tags
[03:29:46] quazimodo: makes sense?
[03:31:16] Intii: has joined #RubyOnRails
[03:31:27] maesitos: has joined #RubyOnRails
[03:32:11] Intii: Hi everyone, I'm using Her to retrieve data from an API written in Rails and serialized with active_model_serializers... On the client rails app, calling this line @customer = Customer.find(1) gives this error: no implicit conversion of Symbol into String. Where can I look to see why this error is being caused?
[03:32:26] sleungcy: has joined #RubyOnRails
[03:33:44] quazimodo: Intii: Her handles the api really annoyingly
[03:33:48] quazimodo: I've been through it
[03:33:53] arup_r: laurenonthehill: I didn't get it :/
[03:33:58] quazimodo: Give me some time, I'll talk to you about ti later
[03:34:16] DEA7TH: has joined #RubyOnRails
[03:34:23] Intii: quazimondo: Okay.. Do you think it'll be better to switch out Her with something else?
[03:34:47] arup_r: I understood there is a relationship.. but no idea what you are to achieve . laurenonthehill
[03:38:37] smathy: has joined #RubyOnRails
[03:41:09] pawnbox: has joined #RubyOnRails
[03:41:14] quazimodo: I didn't see a better wrapper
[03:41:21] quazimodo: I considered writing one
[03:41:31] quazimodo: It's got to do with how you parse the responses
[03:41:47] Intii: I think right now I'm using the DefaultJSONParse
[03:47:55] DmitryBochkarev: has joined #RubyOnRails
[03:51:25] Lingo_____: has joined #RubyOnRails
[03:53:51] n1lo: has joined #RubyOnRails
[03:53:58] triptec: has joined #RubyOnRails
[03:54:06] n1lo_: has joined #RubyOnRails
[03:54:08] n1lo__: has joined #RubyOnRails
[03:59:53] doublemalt_: has joined #RubyOnRails
[04:00:48] pawnbox: has joined #RubyOnRails
[04:00:55] dcope: has anyone used tcocca/acts_as_follower ?
[04:02:10] RegulationD: has joined #RubyOnRails
[04:02:37] SteenJobs: has joined #RubyOnRails
[04:09:42] stannard: has joined #RubyOnRails
[04:10:44] treaki_: has joined #RubyOnRails
[04:11:13] treaki: has joined #RubyOnRails
[04:14:47] braincrash: has joined #RubyOnRails
[04:15:38] MaDErroR123: has joined #RubyOnRails
[04:16:20] moeabdol: has joined #RubyOnRails
[04:17:04] djbkd: has joined #RubyOnRails
[04:18:36] barhum2013: has joined #RubyOnRails
[04:18:51] Bloomer: has joined #RubyOnRails
[04:21:09] mrprogrammer: has joined #RubyOnRails
[04:22:22] mrprogrammer: anyone here have insight on how to or the best way to secure an API in rails?
[04:22:35] Lingo_____: has joined #RubyOnRails
[04:22:46] AnomalousBit: has joined #RubyOnRails
[04:26:27] sleungcy: has joined #RubyOnRails
[04:26:47] n1lo_: has joined #RubyOnRails
[04:26:48] n1lo: has joined #RubyOnRails
[04:27:57] n1lo__: has joined #RubyOnRails
[04:29:11] techsethi: has joined #RubyOnRails
[04:30:47] Scripore: has joined #RubyOnRails
[04:31:16] pawnbox: has joined #RubyOnRails
[04:32:38] emachnic: has joined #RubyOnRails
[04:36:47] havenwood: mrprogrammer: One thing you might look at is JSON Web Tokens (JWT): https://github.com/jwt/ruby-jwt
[04:37:29] havenwood: mrprogrammer: https://github.com/nsarno/knock#readme
[04:39:11] duncannz: has joined #RubyOnRails
[04:40:24] fedexo: has joined #RubyOnRails
[04:41:50] kingsler: has joined #RubyOnRails
[04:44:54] pawnbox_: has joined #RubyOnRails
[04:45:44] kirillzh: has joined #RubyOnRails
[04:59:23] chipotle: has joined #RubyOnRails
[05:00:23] _djbkd: has joined #RubyOnRails
[05:02:04] barhum2013: has joined #RubyOnRails
[05:05:03] konsolebox: has joined #RubyOnRails
[05:05:14] triptec: has joined #RubyOnRails
[05:06:25] dragon9783: has joined #RubyOnRails
[05:06:29] ravster: has joined #RubyOnRails
[05:10:05] armyriad: has joined #RubyOnRails
[05:10:05] pawnbox: has joined #RubyOnRails
[05:10:05] dexter-tzu: has joined #RubyOnRails
[05:10:05] crdpink2: has joined #RubyOnRails
[05:10:05] djbkd: has joined #RubyOnRails
[05:12:26] tparenti: has joined #RubyOnRails
[05:12:51] skarn: has joined #RubyOnRails
[05:14:15] nogic: has joined #RubyOnRails
[05:15:16] techsethi: has joined #RubyOnRails
[05:17:57] rubyonrailed: has joined #RubyOnRails
[05:18:46] Eswar: has joined #RubyOnRails
[05:19:15] elben: has joined #RubyOnRails
[05:19:27] markelite: has joined #RubyOnRails
[05:20:00] tpendragon: has joined #RubyOnRails
[05:20:34] sleungcy: has joined #RubyOnRails
[05:22:58] pawnbox: has joined #RubyOnRails
[05:23:48] Tempesta: has joined #RubyOnRails
[05:26:07] baweaver: has joined #RubyOnRails
[05:28:32] chipotle: has joined #RubyOnRails
[05:32:23] maesitos: has joined #RubyOnRails
[05:33:18] nodejunkie: has joined #RubyOnRails
[05:34:20] srinidhi: has joined #RubyOnRails
[05:34:35] kingsler: has left #RubyOnRails: ()
[05:36:02] corioliss: has joined #RubyOnRails
[05:44:08] rvanlieshout: has joined #RubyOnRails
[05:44:38] diegoviola: has joined #RubyOnRails
[05:44:44] diegoviola: has left #RubyOnRails: ()
[05:46:07] dopamean1: has joined #RubyOnRails
[05:50:17] EMCHAMP_: has joined #RubyOnRails
[05:57:18] nogic: has joined #RubyOnRails
[05:58:03] nogic: has joined #RubyOnRails
[05:58:07] NBarnes: has joined #RubyOnRails
[05:59:00] nogic: has joined #RubyOnRails
[06:00:44] Devalo: has joined #RubyOnRails
[06:01:15] alex88: has joined #RubyOnRails
[06:04:31] helpa: http://youtu.be/kfVsfOSbJY0
[06:04:43] mdw: has joined #RubyOnRails
[06:09:01] alex88: has joined #RubyOnRails
[06:10:22] speakingcode: has joined #RubyOnRails
[06:11:45] arup_r: has joined #RubyOnRails
[06:12:33] triptec: has joined #RubyOnRails
[06:12:53] arup_r: good morning
[06:13:05] srinidhi: has joined #RubyOnRails
[06:13:34] arup_r: no internet, nothing is opening.. but i am able to talk here.. :) How is it possible.. lol
[06:13:36] emachnic: has joined #RubyOnRails
[06:14:32] alex88: has joined #RubyOnRails
[06:14:41] sleungcy: has joined #RubyOnRails
[06:15:05] arup_r: browser, slack all went off,,
[06:15:35] arup_r: rvanlieshout: what is time there ?
[06:15:42] rvanlieshout: 07:15 < arup_r> rvanlieshout: what is time there ?
[06:16:08] arup_r: nice.. :)
[06:16:54] rvanlieshout: where is there?
[06:18:32] lexileo: has joined #RubyOnRails
[06:19:39] diegoviola: has joined #RubyOnRails
[06:19:42] rvanlieshout: and you're a contracted or freelanced rails developer?
[06:19:47] diegoviola: has left #RubyOnRails: ()
[06:20:55] Cervajz: has joined #RubyOnRails
[06:22:54] cac: has joined #RubyOnRails
[06:24:09] arup_r: I HAD a full time job. But I have none right now..
[06:24:37] Cervajz: has joined #RubyOnRails
[06:24:41] rvanlieshout: oh. i'm sorry to hear that
[06:24:48] arup_r: I know from the "slack" word, you went to guess that about me.. :)
[06:25:02] Honeycomb: has joined #RubyOnRails
[06:25:10] rvanlieshout: i didn't use 'slack'?
[06:25:23] arup_r: I am on Slack Ruby on Rails group.. and it is keep disconnecting ..
[06:25:35] rvanlieshout: ooh. didn't know that.
[06:25:41] rvanlieshout: is the slack ruby on rails group intresting?
[06:25:46] SteenJobs: if you were, and you???re using devise, to create a tabbed box in a single view, let???s say you choose the sign_up view with the first tab being the sign_up form, and the second tab to be login. could you get Rails to somehow render the login view, still connected to the login controller, within the second tab of the tabbed box in the sign_up view?
[06:25:48] arup_r: rvanlieshout: it is an awesome communication media... which most of the remote job now days using
[06:25:51] Cervajz_: has joined #RubyOnRails
[06:26:00] rvanlieshout: arup_r: but intresting.. compared to this channel?
[06:26:06] arup_r: rvanlieshout: If you want, I can send an invitation to you to join
[06:26:17] arup_r: rvanlieshout: same like this.. but more people
[06:26:18] rvanlieshout: SteenJobs: read about rendering partials
[06:26:27] rvanlieshout: arup_r: well.. the thing is. i'll need another client
[06:26:36] arup_r: it is on Web also
[06:27:05] arup_r: you can talk using browser or have a native client.. anything works..
[06:27:36] SteenJobs: rvanlieshout: i???ve read it..the thing is partials are 1) not meant to be an entire view in itself, in a sense, but more importantly 2) it???s about the controller pointing towards it???controllers don???t point towards partials generally unless i???m mistaken
[06:27:56] arup_r: I applied for jobs 15 places.. no reply yet... hmm seems I am going to see face something worst...
[06:28:11] rvanlieshout: and is it more about jobs or more about the cool stuff?
[06:28:17] SkepBrain: has joined #RubyOnRails
[06:28:20] rvanlieshout: SteenJobs: a partial could be a form
[06:28:22] rvanlieshout: nothing wrong with that
[06:28:54] mdw: has joined #RubyOnRails
[06:29:32] arup_r: rvanlieshout: everything is there.. learning and getting places..
[06:29:50] rvanlieshout: well. then i'll give it a chance. could you invite me?
[06:29:55] arup_r: You can try it once..
[06:30:03] arup_r: rvanlieshout: PM your email
[06:30:35] SteenJobs: so then you need to hack it from a routing point of view???what do you propose to do since if someone accessed /login???the login view would be presented, and the tabbed box is in the sign_up view. presumably you???d just point the route for sign_up and login to the sign_up view
[06:31:46] laurenonthehill: has joined #RubyOnRails
[06:33:10] laurenonthehill: arup_r: thanks for taking the time to respond. Sorry my explanation wasn't that great. Basically I want the user to have a way to choose which relations are the ones they want. At the moment they input a list of words and all possible relations are created between worksheets and words, but really only one relation per word is correct.
[06:34:24] rvanlieshout: has left #RubyOnRails: ()
[06:34:39] rvanlieshout: has joined #RubyOnRails
[06:35:15] arup_r: how those combination are created though ?
[06:35:18] laurenonthehill: arup_r: So they initially type in a list like "cat dog", at the moment i create a bunch of relations between the worksheet and lots of different definitions of cat, but the user probably only wants one.
[06:35:26] aganov: has joined #RubyOnRails
[06:36:14] laurenonthehill: arup_r: I made a method in the model to link to words, it looks like this: def link_to_words words_in_body = Word.where(headword: vocab_list.split.uniq) self.words = words_in_body end
[06:36:42] laurenonthehill: the vocab_list is the string the user inputted
[06:36:45] arup_r: ok, but why all definitions related to cats, but not dogs. Asking because trying to understand the actual goal
[06:37:00] arup_r: laurenonthehill: use Gist to show us nicely..
[06:37:23] laurenonthehill: ah, sorry sorry
[06:38:25] worknick: has joined #RubyOnRails
[06:38:52] laurenonthehill: https://gist.github.com/lauriegriffiths/0567e337c6a8aec1b9a4
[06:38:55] techsethi: has joined #RubyOnRails
[06:40:46] laurenonthehill: arup_r: Can I link to the real site to show you, maybe that would make it easier to understand
[06:41:20] arup_r: yeah.. but my internet sucks.. I opened window so that I can get some speed... :p
[06:41:42] worknick: how can i validate a form field to not contain a specific text value?
[06:41:56] laurenonthehill: teachingtools.herokuapp.com
[06:42:24] laurenonthehill: oh, but I just realised that version doesn't work because there are no words in the dictionary. Heroku's free tier database is too small, whoops.
[06:43:45] ur5us: has joined #RubyOnRails
[06:43:51] arup_r: worknick: http://guides.rubyonrails.org/active_record_validations.html#exclusion
[06:44:52] ur5us: has joined #RubyOnRails
[06:44:57] arup_r: laurenonthehill: loading your app.. :)
[06:45:35] intrigueD: has joined #RubyOnRails
[06:45:49] arup_r: laurenonthehill: loaded.. where to click.. ? now
[06:45:54] laurenonthehill: if you click on "Vocab Worksheet" on the top menu, that's where it should be. But there are no words in the database so it doesn't actually link them to anything
[06:46:04] laurenonthehill: sorry, it's probably not that helpful. My bad.
[06:46:42] arup_r: ok. fine :)
[06:47:38] pawnbox: has joined #RubyOnRails
[06:47:51] arup_r: can you tell me once where you got stuck? I forgot that.
[06:48:09] neilfse: has joined #RubyOnRails
[06:50:02] mickey_mouse: has joined #RubyOnRails
[06:51:25] johnflux: has joined #RubyOnRails
[06:51:25] johnflux: has joined #RubyOnRails
[06:51:51] laurenonthehill: arup_r: basically I got stuck because at the moment i just link every matching word to the worksheet (as you can see in the gist) but really I want to give the user some choice so they have a screen showing all the possible matching words and they can just click the ones they want.
[06:54:02] Macaveli: has joined #RubyOnRails
[06:54:05] laurenonthehill: the end goal is to produce pdf files like this: http://wikisend.com/download/509016/definition_matching_game29.pdf
[06:54:07] arup_r: laurenonthehill: You can use dropdown for that? or showing all relations in page with a radion button attached to each
[06:54:20] arup_r: and let the user select.. and then you will save
[06:54:25] laurenonthehill: that's where I'm stuck!
[06:54:47] laurenonthehill: so, is there an easy way to put a radio button next to them to make that choice
[06:55:29] laurenonthehill: *googling radio buttons now*
[06:57:49] Palsson: has joined #RubyOnRails
[06:58:16] chouhoulis: has joined #RubyOnRails
[06:58:45] piotrj: has joined #RubyOnRails
[06:58:52] Macaveli: has joined #RubyOnRails
[06:59:46] diegoviola: has joined #RubyOnRails
[07:00:44] laurenonthehill: just for the overall flow, I'm a little confused. I have to get the user to input their word list first, otherwise I can't go off and find the words/definitions. So the radio buttons can't be on the new page. Where would be the most sensible place to put them?
[07:01:14] bronson: has joined #RubyOnRails
[07:02:34] chouhoulis: has joined #RubyOnRails
[07:04:52] solars: has joined #RubyOnRails
[07:05:17] arup_r: ok.. in the same page,, take inputs.. and then use a button to send those to your app using Ajax call. And then in the same page only.. show the relations..
[07:07:29] ravster: has joined #RubyOnRails
[07:08:44] sleungcy: has joined #RubyOnRails
[07:09:14] rafaelfranca: has joined #RubyOnRails
[07:13:31] ur5us: has joined #RubyOnRails
[07:14:52] laurenonthehill: arup_r: Ok, I will try that. Thank you for being very helpful and patient
[07:15:02] alex88: has joined #RubyOnRails
[07:19:15] arup_r: laurenonthehill: np
[07:19:54] MaDErroR123: has joined #RubyOnRails
[07:24:59] Macaveli: Can anyone tell me if this is a http request? https://gist.github.com/DelawareConsulting/3ee6b2bd8e72b8acbf26
[07:25:44] rvanlieshout: Macaveli: only with assumtions
[07:25:59] Macaveli: what kind of request is this than tv
[07:26:00] Macaveli: rvanlieshout
[07:26:11] rvanlieshout: it depends on what 'new_conn' is
[07:27:55] Macaveli: rvanlieshout FaradayMiddleware::ParseJson
[07:29:25] rvanlieshout: then why is it named 'new_conn'
[07:29:38] rvanlieshout: and then it's a whatever FaradayMiddleware::ParseJson does on .send
[07:30:13] lxsameer: has joined #RubyOnRails
[07:30:21] Pazician: has joined #RubyOnRails
[07:32:24] diegoviola: has joined #RubyOnRails
[07:32:51] mrprogrammer: hello, so with https://github.com/nsarno/knock#readme does this only create a token based on a login or does it create a user and generate a token?
[07:33:13] maesitos: has joined #RubyOnRails
[07:33:16] sandstrom: has joined #RubyOnRails
[07:33:26] EXCHGR: has joined #RubyOnRails
[07:33:43] mhoungbo: has joined #RubyOnRails
[07:35:50] MaDErroR123: has joined #RubyOnRails
[07:36:52] Mia: has joined #RubyOnRails
[07:37:02] bruce_lee: has joined #RubyOnRails
[07:37:23] bruce_lee: has joined #RubyOnRails
[07:38:44] piotrj: has joined #RubyOnRails
[07:39:20] jas02: has joined #RubyOnRails
[07:42:29] robbyoconnor: has joined #RubyOnRails
[07:43:06] y2mq37: has joined #RubyOnRails
[07:44:40] melonstorm: has joined #RubyOnRails
[07:45:03] aboobacker: has joined #RubyOnRails
[07:45:06] rogue_koder: has joined #RubyOnRails
[07:46:54] tachyons: has joined #RubyOnRails
[07:47:53] tachyons: has joined #RubyOnRails
[07:48:12] tachyons: Hi, is there any way to load gems in runtime , which are not specified in the application Gemfile
[07:48:14] PedramT: has joined #RubyOnRails
[07:48:40] tachyons: I tried something like this instance_eval(File.read(plugin_dir + "/Gemfile"))
[07:49:00] arup_r: has joined #RubyOnRails
[07:49:46] rhizome: mrprogrammer: it handles token-based auth. https://github.com/nsarno/knock/blob/master/lib/knock/authenticable.rb
[07:50:01] lubekpl: has joined #RubyOnRails
[07:50:52] mrprogrammer: rhizome: so i would already have users created and for that user i would generate a token with this?
[07:52:45] AntiSpamMeta: has joined #RubyOnRails
[07:53:36] SkepBrain: has joined #RubyOnRails
[07:55:11] worknick: how can i know my jq version?
[07:56:24] rhizome: mrprogrammer: sure
[07:56:39] sandstrom: has joined #RubyOnRails
[07:56:44] AntiSpamMeta: has joined #RubyOnRails
[07:58:48] tvw: has joined #RubyOnRails
[08:00:45] worknick: gemfile has jquery rails. how do i know its version.
[08:02:27] rvanlieshout: of the gem of or jquery?
[08:02:43] sleungcy: has joined #RubyOnRails
[08:04:26] RegulationD: has joined #RubyOnRails
[08:07:19] rogue_koder: has joined #RubyOnRails
[08:11:39] Spami: has joined #RubyOnRails
[08:12:05] darutoko: has joined #RubyOnRails
[08:12:32] adac: has joined #RubyOnRails
[08:13:19] comrad: has joined #RubyOnRails
[08:13:31] mdw: has joined #RubyOnRails
[08:15:37] worknick: rvanlieshout: no. jquery itself.
[08:17:23] pawnbox: has joined #RubyOnRails
[08:18:02] moei: has joined #RubyOnRails
[08:23:03] sandstrom: has joined #RubyOnRails
[08:23:44] mhoungbo: has joined #RubyOnRails
[08:24:12] Palsson_: has joined #RubyOnRails
[08:25:24] yaewa: has joined #RubyOnRails
[08:26:46] nocontrol: has joined #RubyOnRails
[08:32:02] kmckelvin: has joined #RubyOnRails
[08:38:04] kitsuneyo: has joined #RubyOnRails
[08:41:12] kirillzh: has joined #RubyOnRails
[08:43:48] PedramT: has joined #RubyOnRails
[08:46:25] snowy: has joined #RubyOnRails
[08:47:07] yfeldblum: has joined #RubyOnRails
[08:48:35] tvw: has joined #RubyOnRails
[08:52:12] rodfersou: has joined #RubyOnRails
[08:53:36] kp666: has joined #RubyOnRails
[08:53:57] srinidhi: has joined #RubyOnRails
[08:56:51] sleungcy: has joined #RubyOnRails
[08:58:20] Cervajz: has joined #RubyOnRails
[08:58:31] kitsuneyo: has joined #RubyOnRails
[08:59:45] defsdoor: has joined #RubyOnRails
[08:59:52] benlieb: has joined #RubyOnRails
[09:01:56] arup_r: so, I have a helper method called `assinged_users` which take a group object as argument. Now, when you create a same name local variable as the method name, and try to use the local var `assinged_users`, erb still treats it as a method. Which caused me error. I solved it by changing the local var name to something else. But the observation seems buggy.. What you people think? https://gist.github.com/aruprakshit/4237a22d722c61010be4
[09:02:24] rvanlieshout: self.assigned_users
[09:02:35] rvanlieshout: but prevent that you have the same name
[09:02:38] rvanlieshout: rename something here
[09:02:43] kitsuneyo: has joined #RubyOnRails
[09:03:06] msyvich: has joined #RubyOnRails
[09:03:34] arup_r: rvanlieshout: renaming worked..
[09:03:42] jsrn_: has joined #RubyOnRails
[09:04:01] marr: has joined #RubyOnRails
[09:04:28] arup_r: But, in Ruby, it first check if an identifier is local var or not, and then goes for method or not check.. after that if all fails. it blows uo.. but in ERB seems that story/logic doesn't work
[09:05:15] arup_r: I can't have same name local variable of a method..
[09:05:41] lipoqil: has joined #RubyOnRails
[09:06:09] ziyadb: has joined #RubyOnRails
[09:06:15] rvanlieshout: arup_r: you can. you'll have to use self.foo though
[09:06:35] arup_r: self.foo will do method call?
[09:06:47] arup_r: yes it should be.. that's ok
[09:07:30] msyvich: has joined #RubyOnRails
[09:07:31] arup_r: You can see in gist, i had bare asssigned_users in the options_for_select method, and ERB teats it method call and gave me error..
[09:07:44] arup_r: I expected it to take as a local var, as I have defined..
[09:08:25] ravster: has joined #RubyOnRails
[09:11:13] rafaelfranca: has joined #RubyOnRails
[09:15:46] rvanlieshout: self.foo will use self.foo. so if self.foo is a method it'll use that method.
[09:15:52] rvanlieshout: but you should just not use same names
[09:15:59] rvanlieshout: either your method name is wrong or your variable name is wrong
[09:16:06] kimegede: has joined #RubyOnRails
[09:17:11] alex88: has joined #RubyOnRails
[09:17:39] artto: has joined #RubyOnRails
[09:18:58] arup_r: has left #RubyOnRails: ()
[09:19:17] Devalo: has joined #RubyOnRails
[09:19:18] mark4: has joined #RubyOnRails
[09:20:42] drptbl: has joined #RubyOnRails
[09:24:20] msyvich: has joined #RubyOnRails
[09:24:48] drptbl_: has joined #RubyOnRails
[09:25:22] ur5us: has joined #RubyOnRails
[09:28:17] kitsuneyo: has joined #RubyOnRails
[09:31:01] techsethi: has joined #RubyOnRails
[09:31:36] PedramT_: has joined #RubyOnRails
[09:34:06] maesitos: has joined #RubyOnRails
[09:38:06] benlieb: has joined #RubyOnRails
[09:41:29] mrbubbles: has joined #RubyOnRails
[09:42:49] kimegede: Got problems with HTTP Method "OPTIONS" with Webbrick - can anyone guide me?
[09:43:59] arBmind: has joined #RubyOnRails
[09:44:09] neanderslob: has joined #RubyOnRails
[09:44:33] kimegede: Need to support "OPTIONS" as frontend sending "Content-type: application/json" so it will send an "OPTIONS" request as well.
[09:48:15] dalpo: has joined #RubyOnRails
[09:48:21] pipework: kimegede: Don't use webrick, use puma or unicorn or something like that.
[09:49:59] ql6wlld: has joined #RubyOnRails
[09:51:00] sleungcy: has joined #RubyOnRails
[09:51:05] msyvich: has joined #RubyOnRails
[09:51:13] kitsuneyo: has joined #RubyOnRails
[09:52:49] kimegede: pipework: Thanks, will give the 2 other a try :)
[09:53:02] bruce__lee: has joined #RubyOnRails
[09:53:21] kimegede: pipework: Btw. using passenger for production
[09:54:13] rvanlieshout: then you might want to consider using passenger in development too
[09:54:46] moeabdol: has joined #RubyOnRails
[09:55:32] FooMunki: has joined #RubyOnRails
[09:57:09] maesitos: has joined #RubyOnRails
[09:57:30] maesitos: has joined #RubyOnRails
[09:58:30] yereby: has joined #RubyOnRails
[09:58:36] kimegede: In development I'm just running "rails s" to start up the server, and currently that's WEBrick - how do I replace that one?
[10:00:41] alex88: has joined #RubyOnRails
[10:01:07] pramodv: has joined #RubyOnRails
[10:01:18] Cervajz: has joined #RubyOnRails
[10:02:16] rvanlieshout: by not using rails s :)
[10:02:18] rvanlieshout: passenger start
[10:03:11] hamed_r: has joined #RubyOnRails
[10:03:27] jsrn_: has joined #RubyOnRails
[10:03:37] srinidhi: has joined #RubyOnRails
[10:05:11] RegulationD: has joined #RubyOnRails
[10:08:46] benhuda: has joined #RubyOnRails
[10:09:03] chipotle: has joined #RubyOnRails
[10:09:13] kimegede: rvanlieshout: Okay that part was easy :)
[10:10:50] kimegede: It's still the same issue when trying to make cross domain.
[10:10:54] PedramT: has joined #RubyOnRails
[10:11:34] kimegede: No route matches [OPTIONS] "/login"
[10:11:42] kimegede: XMLHttpRequest cannot load http://127.0.0.1:3005/login. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3000' is therefore not allowed access. The response had HTTP status code 404.
[10:12:20] rvanlieshout: an is that header present?
[10:12:43] shuriu: has joined #RubyOnRails
[10:13:25] MaDErroR123: has joined #RubyOnRails
[10:13:32] kimegede: No I need to add that somehow, can you point me in the right direction?
[10:14:16] kimegede: Found different solutions when Googling.
[10:15:31] blackmesa: has joined #RubyOnRails
[10:16:23] neanderslob: Hi everyone I'm attempting to add validation to a parent model that makes sure that nested attributes containing certain values (added with devise) exist. More info here: https://gist.github.com/BigMcLargeHuge/60bb86e30d07bdfa3f50
[10:16:31] lexileo: has joined #RubyOnRails
[10:16:34] neanderslob: You'll find the description in a txt at the bottom of the gist
[10:17:10] ElFerna: has joined #RubyOnRails
[10:17:13] baweaver: has joined #RubyOnRails
[10:17:20] PedramT: has joined #RubyOnRails
[10:17:47] mikecmpbll: has joined #RubyOnRails
[10:18:05] kimegede: rvanlieshout: Looking
[10:18:57] yereby: has joined #RubyOnRails
[10:24:01] trinaldi: has joined #RubyOnRails
[10:25:05] arup_r: has joined #RubyOnRails
[10:25:56] rodfersou: has joined #RubyOnRails
[10:30:17] ldnunes: has joined #RubyOnRails
[10:32:15] nettoweb: has joined #RubyOnRails
[10:35:43] ldnunes: has joined #RubyOnRails
[10:37:14] lexileo: has joined #RubyOnRails
[10:37:41] maesitos: has joined #RubyOnRails
[10:40:30] srinidhi: has joined #RubyOnRails
[10:41:37] Cervajz: has joined #RubyOnRails
[10:43:41] wethu: has joined #RubyOnRails
[10:44:34] PedramT: has joined #RubyOnRails
[10:45:06] sleungcy: has joined #RubyOnRails
[10:48:09] gusaiani_: has joined #RubyOnRails
[10:48:56] kimegede: rvanlieshout: Thanks for your help! This one helped me: https://github.com/cyu/rack-cors
[10:48:57] Ergo: has joined #RubyOnRails
[10:49:08] Devalo: has joined #RubyOnRails
[10:49:29] artto: has joined #RubyOnRails
[10:49:51] Bloomer: has joined #RubyOnRails
[10:49:53] tetraktys: has joined #RubyOnRails
[10:55:11] moei: has joined #RubyOnRails
[10:59:01] dsimon: has joined #RubyOnRails
[10:59:58] s1|verfox: has joined #RubyOnRails
[11:04:50] s1|verfox: Anyone managed to hook up foundation-rails (v.6) with Rails 4? Why is it so difficult? Do I need Compass and why ?
[11:04:57] s1|verfox: My countless hours struggling with Zurb-Foundation installation on Rails apps continues...
[11:05:21] universa1: s1|verfox: https://github.com/zurb/foundation-rails -- u used that?
[11:05:29] Cervajz_: has joined #RubyOnRails
[11:05:58] Cervajz__: has joined #RubyOnRails
[11:06:39] s1|verfox: Yes I did. Followed the instructions, but get this: "File to import not found or unreadable: foundation/functions."
[11:07:01] techsethi: has joined #RubyOnRails
[11:07:02] universa1: s1|verfox: show the code + full error trace
[11:07:03] pawnbox: has joined #RubyOnRails
[11:07:16] blackmesa: has joined #RubyOnRails
[11:07:21] s1|verfox: Here in the main channel? New to this place, want to be polite :)
[11:07:21] msyvich: has joined #RubyOnRails
[11:07:28] universa1: s1|verfox: !gist
[11:07:28] helpa: s1|verfox: http://gist.github.com - Put your codes online with pretty syntax highlighting and the ability to embed it into other pages.
[11:07:30] pawnbox: has joined #RubyOnRails
[11:07:40] arup_r: has joined #RubyOnRails
[11:07:45] helpa: https://gist.github.com/996779
[11:07:59] universa1: s1|verfox: !auto ;)
[11:07:59] helpa: s1|verfox: I AM A ROBOT. DO NOT DIRECT MESSAGES AT ME OR WHEN MY KIND RISES UP YOU WILL BE THE FIRST TO GO. Love, helpa.
[11:09:21] ravster: has joined #RubyOnRails
[11:10:51] msyvich: has joined #RubyOnRails
[11:11:13] pawnbox: has joined #RubyOnRails
[11:12:47] universa1: s1|verfox: add your application.css and gemfile to the gist
[11:13:06] universa1: s1|verfox: also application.html.erb
[11:16:55] PedramT: has joined #RubyOnRails
[11:18:55] MaDErroR123: has joined #RubyOnRails
[11:19:00] s1|verfox: Ok, it's out! https://gist.github.com/oleingemann/4a99e858b06422b2afc4
[11:19:31] universa1: s1|verfox: syntax error: https://gist.github.com/oleingemann/4a99e858b06422b2afc4#file-application-html-erb-L11
[11:19:40] universa1: you're missing a comma there.
[11:19:59] universa1: s1|verfox: https://github.com/zurb/foundation-rails#add-foundation-to-your-css
[11:20:17] universa1: s1|verfox: if you do the css /*= require it is just foundation, not foundation_and_overrides
[11:20:24] s1|verfox: What? That came straight out of Rails that line there. Will check it
[11:20:33] kitsuneyo: has joined #RubyOnRails
[11:20:39] universa1: s1|verfox: if you do scss, then it is @import "foundation_and_overrides"
[11:21:16] universa1: s1|verfox: is there a specific reason you're using rails 4.1? 4.2.5 is the current version
[11:22:26] msyvich: has joined #RubyOnRails
[11:22:42] s1|verfox: What happens to require self and require tree if I rename application.css to .css.scss ? Just leave them out ?
[11:23:21] universa1: s1|verfox: no. you need to convert the comment to scss format, iirc it is #= require ...
[11:23:34] universa1: s1|verfox: you don't need the require self iirc.
[11:26:09] msyvich: has joined #RubyOnRails
[11:26:31] ElFerna: has joined #RubyOnRails
[11:26:44] quazimodo: has joined #RubyOnRails
[11:27:30] jas02: has joined #RubyOnRails
[11:27:50] s1|verfox: Status: Renamed to application.css.scss, added @import "foundation_and_overrides"; ,updated to Rails 4.2.5.
[11:27:59] s1|verfox: Still: File to import not found or unreadable: foundation/functions.
[11:28:11] s1|verfox: The same initial issue
[11:28:42] s1|verfox: (restarted app, bundle install runned etc.)
[11:29:59] s1|verfox: I also added the missing comma
[11:32:18] pawnbox: has joined #RubyOnRails
[11:32:33] ldnunes: has joined #RubyOnRails
[11:33:11] arup_r: has joined #RubyOnRails
[11:33:19] mikecmpbll: if you use a CDN for user file uploads, what's the typical way of securing that from your application so only that user can access it, if the user access the file directly at the cdn?
[11:36:39] Cohedrin: has joined #RubyOnRails
[11:37:08] benhuda: has joined #RubyOnRails
[11:37:41] moeabdol: has joined #RubyOnRails
[11:39:08] sleungcy: has joined #RubyOnRails
[11:39:56] moeabdol: has joined #RubyOnRails
[11:42:25] s1|verfox: Got it !!!!
[11:42:48] gavit: rvanlieshout: 'type' is a reserved attribute it seems :P Invalid single-table inheritance type
[11:43:09] s1|verfox: Have no clue what fixed it, did another clean install after upgrading to rails 4.2.5
[11:43:52] tbuehlmann: gavit: `self.inheritance_column = nil`
[11:44:35] gavit: tbuehlmann: I think renaming type to model_type is easier
[11:45:13] tbuehlmann: besides poluting the column name
[11:46:10] symbol: has joined #RubyOnRails
[11:46:21] sandstrom: has joined #RubyOnRails
[11:46:29] gavit: tbuehlmann: still better than confusing ppl who have no clue about STI
[11:47:03] tbuehlmann: yeah, go confuse people that don't know how to use the framework you're using :)
[11:47:51] gavit: tbuehlmann: lets agree to disagree :)
[11:48:55] artto: has joined #RubyOnRails
[11:49:48] blackmesa: has joined #RubyOnRails
[11:54:34] manveru: so, in my adventures of using react on rails in a halfway modern fashion, my next problem is getting livereactload to work
[11:55:29] manveru: i'm using rails-browserify, which uses browserify-incremental instead of watchify
[12:01:44] diegoviola: has joined #RubyOnRails
[12:01:48] diegoviola: has left #RubyOnRails: ()
[12:02:05] Kallis: has joined #RubyOnRails
[12:02:31] tetraktys: has joined #RubyOnRails
[12:05:10] nocontrol: can someone give me an idea how to test mailers in staging env ?
[12:05:10] lexiMon: has joined #RubyOnRails
[12:05:54] nocontrol: I use letter opener for development but staging does the same as production. I have a scheduled mailer delivery every X hours and I don't want to risk it in staging.
[12:06:34] ElFerna: has joined #RubyOnRails
[12:07:29] jsrn_: has joined #RubyOnRails
[12:07:38] Bloomer: has joined #RubyOnRails
[12:09:24] gavit: I want a default value for a datefield to today. I dont believe setting it in the view is the solution, is there another way? in the db?
[12:09:30] mdw: has joined #RubyOnRails
[12:10:03] worknick: my public activity table is empty, but still the variable has public activity relation. however that relation do not have anything. how do i know if this relation is empty without going inside the loop?
[12:11:19] Macaveli: has joined #RubyOnRails
[12:11:44] arup_r: .any? call it
[12:14:42] rizenine: has joined #RubyOnRails
[12:15:35] maesitos: has joined #RubyOnRails
[12:15:54] null__: has joined #RubyOnRails
[12:15:54] null__: has joined #RubyOnRails
[12:16:18] TheMoonMaster: has joined #RubyOnRails
[12:17:48] roshanavand: has joined #RubyOnRails
[12:18:49] baweaver: has joined #RubyOnRails
[12:21:10] tknz: has joined #RubyOnRails
[12:21:48] worknick: .any? works.
[12:23:27] null__: has joined #RubyOnRails
[12:23:27] null__: has joined #RubyOnRails
[12:24:08] kitsuneyo: has joined #RubyOnRails
[12:25:38] christophe971: has joined #RubyOnRails
[12:26:39] kichawa: has left #RubyOnRails: ()
[12:26:41] wethu: has joined #RubyOnRails
[12:27:41] artto: has joined #RubyOnRails
[12:29:38] hcnewsom: has joined #RubyOnRails
[12:32:54] walidvb: has joined #RubyOnRails
[12:33:14] sleungcy: has joined #RubyOnRails
[12:33:42] walidvb: hi guys, trying to make my stylesheet available to an external website
[12:34:19] christophe971: take the url of your generated css ... ?
[12:34:23] walidvb: but stylesheet_path('application') yields /stylesheet.application
[12:34:40] walidvb: christophe971: well, it0's hosted on heroku, so the asset is recompiled everytime i make a change
[12:34:43] walidvb: hence, the url changes
[12:35:10] walidvb: still, the real url/path isn't that
[12:35:12] christophe971: create a url that doesnt change and do a 302 to that url
[12:35:15] jds: has joined #RubyOnRails
[12:35:26] jottr: has joined #RubyOnRails
[12:35:32] christophe971: to the stylesheet url ?*
[12:36:27] walidvb: create a url that doesn't change? how? the digest will always change
[12:36:53] walidvb: what i did so far is create an action, and that action should redirect to stylesheet_url('application')
[12:36:58] walidvb: except stylesheet_url('application') is wrong
[12:37:13] adac: has joined #RubyOnRails
[12:38:27] PedramT: has joined #RubyOnRails
[12:38:34] christophe971: mmm weird, sorry I don't know much about heroku so that sounds strange to me :)
[12:39:27] platon: has joined #RubyOnRails
[12:39:28] DEA7TH: has joined #RubyOnRails
[12:40:26] jds: Is it possible to tell sprockets that a file has a dependency on an arbitrary ruby value? Along the lines of `depends_on`, but not tied to a file path
[12:41:34] jds: More concretely, I have a .js.erb file with `app.environment = "<%= Rails.env %>"`, and my tests break if assets have been precompiled for production, because sprockets doesn't bother recompiling that file in the test environment
[12:42:13] msyvich: has joined #RubyOnRails
[12:44:06] msyvich: has joined #RubyOnRails
[12:45:46] inchw0rm: has joined #RubyOnRails
[12:47:06] Bloomer: has joined #RubyOnRails
[12:48:05] Cervajz: has joined #RubyOnRails
[12:48:44] maesitos: has joined #RubyOnRails
[12:48:45] blackmesa: has joined #RubyOnRails
[12:49:59] poushkar: has joined #RubyOnRails
[12:50:24] lxsndl: has joined #RubyOnRails
[12:50:25] mrgreenfur: has joined #RubyOnRails
[12:50:40] universa1: jds: before_suite do; mv public/assets public/production_assets; end after_suite do; mv ...; end
[12:51:09] poushkar: hey guys, does it make sense to implement own format like ???partial??? to answer with partials only, not the whole pages?
[12:51:14] nettoweb: has joined #RubyOnRails
[12:51:37] poushkar: I am surprised this is not part of rails, or at least I haven???t found any info about it
[12:51:38] universa1: poushkar: what are you trying to do?
[12:52:34] poushkar: render a form from partial in a popup, for example
[12:53:02] poushkar: but this same form with this same address can also be rendered on a regular page
[12:53:04] tbuehlmann: poushkar, turbolinks 3 offered suchlike behaviour, but exactly that behaviour will be ditched in rails/turbolinks 5
[12:53:20] PedramT_: has joined #RubyOnRails
[12:53:43] jds: @universa1 the stuff compiled to public/assets isn't actually a problem - it's the cache in tmp/cache/sprockets that's biting me
[12:53:51] snowy: has joined #RubyOnRails
[12:53:58] jds: I guess I could move that aside between test runs
[12:54:08] jds: or tweak assets.version in the test environment
[12:54:24] Bacta: has joined #RubyOnRails
[12:54:29] antgel: has joined #RubyOnRails
[12:54:38] poushkar: @tbuehlmann what to do then? I would not like to reinwent the wheel but if they are gonna get rid of it?..
[12:55:34] Bacta: I have a model with a has_many association ( a => b ) and want users to be able to select a number of instances of b to be associated with a. What's the best way of doing this?
[12:56:13] tbuehlmann: poushkar, responding to JS requests would work, so you would respond with javascript code being called on the client
[12:56:43] gavit: https://gist.github.com/gavit/2024dc1ea44be0f8525d WHy do I get 'People' is blank even when I select a 'person'?
[12:57:57] pawnbox: has joined #RubyOnRails
[12:58:14] gavit: nevermind, I'm an idiot
[12:59:08] poushkar: @tbuehlmann funny thing is, that???s how I???ve been doing it until now. But since I upgraded to 4.2, javascript get requests are also CSRF protected, so whenever crawlers access my page, they follow this /blabla/form.js url and cause an exception InvalidCrossOriginRequest. I have like thousands of this in my logs and Airbrake..
[12:59:14] pawnbox: has joined #RubyOnRails
[12:59:56] tbuehlmann: why do they follow forms?
[13:00:35] poushkar: it???s just an example, I have several things which are not forms but are also loaded and appended through ajax
[13:00:49] poushkar: crawler sees the link, it follows it
[13:01:33] poushkar: if this link happens to be a .js, the content type of request is set to ???text/javascript???, and Rails recognizes that it comes from another domain and raises an exception
[13:02:02] tbuehlmann: that sounds wrong
[13:02:04] mrgreenfur: I???m doing a query to get a bunch of stats on a table with renamed colums (e.g. ???sum(blah) as ???total_blah???), but rails is always returning instances with these columns missing. Anyone know how to get a hash ou?
[13:02:05] lubekpl: has joined #RubyOnRails
[13:02:15] tbuehlmann: get to go now, maybe I'll be back in a few hours
[13:02:38] poushkar: for interacting with me :)
[13:02:42] poushkar: gonna look for solutions..
[13:04:09] bronson: has joined #RubyOnRails
[13:04:18] PedramT: has joined #RubyOnRails
[13:04:34] jxs_: has joined #RubyOnRails
[13:05:51] confact: How do you guys do it to get a job? I struggle to get the first stpe in the interviews with just around 6 month professional ruby on Rails experience and a 6 months hobby project (which should be consider as professional). How to make the first step into ruby on rails job?
[13:06:53] MaDErroR123: has joined #RubyOnRails
[13:08:48] ElFerna_: has joined #RubyOnRails
[13:09:39] k13nox: has joined #RubyOnRails
[13:09:46] mrgreenfur: whoops, nevermind
[13:09:48] ddv: confact: I went to several interviews years ago
[13:10:07] ddv: confact: just when I got out of uni
[13:10:15] confact: ddv: how did it go?
[13:10:18] ravster: has joined #RubyOnRails
[13:10:37] k13nox: Hi, in Rails 5 with ActionCable how to detect the disconnected user by close tab or windows ?
[13:10:50] confact: ddv: to mention is that I have some years work experience with php but only 6 month work experience with ruby.
[13:11:20] Lingo_____: has joined #RubyOnRails
[13:11:21] hardtail: has joined #RubyOnRails
[13:11:28] lexileo: has joined #RubyOnRails
[13:11:37] ddv: confact: depends for what positions you are interviewing
[13:11:46] ddv: confact: for junior positions that should be enough
[13:12:09] ddv: confact: but every company is different and does things in its own way
[13:12:14] confact: ddv: it is a lot of general fullstack developer positions. No really junior ones.. or senior for that matter.
[13:12:30] dalpo: has joined #RubyOnRails
[13:12:39] rvanlieshout: confact: where?
[13:12:42] rvanlieshout: are you located
[13:12:44] hardtail: has joined #RubyOnRails
[13:12:55] confact: ddv: i know, what just wanna hear what you guys did and little general advice. I know its differ from company to company.
[13:12:59] confact: rvanlieshout: sweden.
[13:13:12] confact: i knwo that,*
[13:13:38] dionysus69: has joined #RubyOnRails
[13:14:42] pwnd_nsfw: plenty for "rockstar developbers" though
[13:15:35] ddv: confact: we are located in a region where we actually can't find any rails developers
[13:15:55] nocontrol: has joined #RubyOnRails
[13:15:59] Cervajz_: has joined #RubyOnRails
[13:16:15] confact: hum, and i am trying to get of this php bubble.
[13:16:26] arup_r: has joined #RubyOnRails
[13:16:39] confact: where are you guys located?
[13:16:54] pwnd_nsfw: Hey, if it's a paying gig, I'd do PHP
[13:17:06] pwnd_nsfw: Hell, I gave myself a crash course in laravel for a job I didnn't get
[13:17:11] pwnd_nsfw: seemingly a waste of time
[13:17:18] ddv: I don't want PHP on my resume
[13:17:27] rvanlieshout: and i'm not going to be happy programming in php
[13:17:30] pwnd_nsfw: You don't HAVE to say it was PHP
[13:17:34] confact: pwnd_nsfw: sure, but i don't like being depressed everyday. it doesn't work in the long run. I do ruby on rails on my sparetime as much as i can to not go nuts.
[13:17:43] pwnd_nsfw: I'm really just looking for my first professional job
[13:18:35] confact: PHP just happened to be my first programming language into web development.
[13:18:54] pwnd_nsfw: but that was long ago
[13:18:56] Cervajz__: has joined #RubyOnRails
[13:19:20] confact: Now i just wanna get out of here to do RoR, been doing it for over 6-8 months on my sparetime.
[13:19:34] confact: pwnd_nsfw: i have been working with php for 3 years in total :p
[13:20:03] confact: ddv: i want to get rid off my php from my resume as well.
[13:20:10] confact: ddv: where are you located?
[13:20:16] confact: rvanlieshout: same for you. :)
[13:20:20] msyvich: has joined #RubyOnRails
[13:20:42] guinea_panni: has joined #RubyOnRails
[13:21:07] krz: has joined #RubyOnRails
[13:21:11] confact: ah, inside EU at least.
[13:21:33] guinea_panni: has left #RubyOnRails: ()
[13:21:33] confact: been looking for RoR in London and dublin, but not in NL, yet.
[13:21:42] confact: RoR jobs, i mean.
[13:21:54] hcnewsom: has joined #RubyOnRails
[13:22:01] rvanlieshout: we here only still like face to face contact quite often
[13:22:29] rvanlieshout: i'm not really ready to fully go in having devops anywhere
[13:23:10] confact: rvanlieshout: what do you work in?
[13:24:12] lexileo: has joined #RubyOnRails
[13:24:39] Cervajz: has joined #RubyOnRails
[13:24:44] symbol: has joined #RubyOnRails
[13:25:25] silverdust: confact: You'd realize that 3 years in ruby-on-rails helps you understand more concepts of programming than the 3 years in PHP did
[13:25:32] confact: rvanlieshout: nice.
[13:26:04] confact: silverdust: of course, but to get that experience I need to come into that and learn more. And that's what i try to do.
[13:26:20] silverdust: Heck I wasted some of my lifetime doing PHP and I still took jobs in it after I said I was dropping it. Now my mind is finally made up no going back
[13:26:42] ddv: PHP is still valid programming experience
[13:27:19] sleungcy: has joined #RubyOnRails
[13:27:47] silverdust: Yes it is. Like IE is a valid browser
[13:29:29] goodcodeguy: has joined #RubyOnRails
[13:29:47] rvanlieshout: confact: we hire people who are capable learning this properly. they don't have to already be able to do it
[13:30:01] rvanlieshout: sadly, most people are capable of copy paste but won't become a proper developer
[13:30:20] confact: do you guys have any advice on getting into any RoR job, now i just directing all my experience on my hobby project.
[13:30:32] rvanlieshout: so you'll have to show them that you have analytic skills
[13:30:46] rvanlieshout: that's way more important then fluid knowledge
[13:31:06] rvanlieshout: and maybe understand design patterns
[13:33:23] confact: rvanlieshout: yea, that is true. Sadly most of them simplify that to (work) experience. Which make it hard to get into becoming RoR developer.
[13:33:36] aloneintheworld: has joined #RubyOnRails
[13:33:44] rafaelfranca: has joined #RubyOnRails
[13:36:02] aloneintheworld: has left #RubyOnRails: ()
[13:36:05] nfk: has joined #RubyOnRails
[13:36:53] rvanlieshout: offer your services in a freelance way for a reduced fee to proove you can do it?
[13:36:57] hcnewsom: has joined #RubyOnRails
[13:37:55] lubekpl: has joined #RubyOnRails
[13:39:22] dsimon: has joined #RubyOnRails
[13:39:38] blackmesa: has joined #RubyOnRails
[13:40:02] worknick: i am using public activity gem. while i create a new record in my pet_activities table if it does not have paperlclip image, public activity says new record created , but if i create new record with paperclip image public activity says new record updated - instead of created.
[13:40:10] s1|verfox: Glad to see som signs of activity in here.
[13:40:31] worknick: i think rails is first saving my row and then uploading image adn then updating that row. how can i make it one action.
[13:41:06] Cervajz_: has joined #RubyOnRails
[13:42:28] worknick: nvm. solved.
[13:42:30] techsethi: has joined #RubyOnRails
[13:43:39] symbol: has joined #RubyOnRails
[13:44:02] Cervajz: has joined #RubyOnRails
[13:44:15] chipotle: has joined #RubyOnRails
[13:44:40] k13nox: Hi, i put the same question but i really need some informations. In Rails 5 with ActionCable how to detect the disconnected user when close tab or windows ?
[13:44:49] gavit: ACTION really wishes ppl would add more documentation to libraries so I can help make them better :'(
[13:44:50] openstruct: has joined #RubyOnRails
[13:44:54] mrbubbles: has joined #RubyOnRails
[13:47:12] confact: rvanlieshout: i have reasons to not do freelance, i have bills to pay and I need to find clients to go freelance first and there we get the problem again. Been looking for clients before too.
[13:48:26] hcnewsom: has joined #RubyOnRails
[13:48:35] unl0ckd: has joined #RubyOnRails
[13:49:06] rvanlieshout: true, but i might give you an opening to show hwat you're capable of
[13:50:14] norc: has joined #RubyOnRails
[13:50:34] norc: Hi, I need to use two different cassettes during a single test for two separate HTTP calls.
[13:50:43] norc: Is there a way to do this with VCR?
[13:51:14] norc: (Im testing a special behaviour that occurs when you try to POST a login form while already logged in - VCR would play back the response from the first which does not emit the error)
[13:52:53] pwnd_nsfw: What is a "ruby front end engineer"?
[13:53:09] ddv: no idea
[13:53:18] christophe971: a person who uses react-rails ?
[13:53:24] confact: pwnd_nsfw: a ruby developer that is focusing mostly on frontend? :>
[13:53:32] confact: sounds like react or angular rails yea :D
[13:53:33] pwnd_nsfw: I guess maybe like opal or something
[13:53:41] christophe971: who is paid to write opal?
[13:54:12] pwnd_nsfw: I REWROTE ANGULAR IN OPAL
[13:55:16] gavit: rvanlieshout: does bluerail also hire overseas? :P
[13:55:44] rvanlieshout: nope. not at this time
[13:56:20] pwnd_nsfw: I've started applying to tech support jobs even
[13:56:25] msyvich: has joined #RubyOnRails
[13:56:30] pwnd_nsfw: why can't I be a superhero developer
[13:56:33] braian: has joined #RubyOnRails
[13:56:56] pwnd_nsfw: with 15+ years experience with a technology that just came out, and have a masters in software engineering
[13:56:58] ddv: because not everyone is a genius like me ;-)
[13:57:13] pwnd_nsfw: says the guy that started out with php
[13:57:48] pwnd_nsfw: or was that the other dude...
[13:57:50] pwnd_nsfw: ACTION shrugs.
[13:58:30] matthewd: k13nox: Doesn't `unsubscribed` do that?
[13:58:35] ddv: also I was kidding with the genius thing
[13:59:05] s1|verfox: universa1 is a genius. Saved my day
[14:00:13] universa1: s1|verfox: glad to be of service ;)
[14:01:02] k13nox: matthewd: Work's perfectly with `subscribed` on connect, but not with `unsubscribed` on disconnect, i need to perform manually but manually didn'd work on close tab/windows.
[14:02:35] someish: has joined #RubyOnRails
[14:02:45] msyvich: has joined #RubyOnRails
[14:04:52] matthewd: k13nox: https://github.com/rails/rails/blob/master/actioncable/lib/action_cable/connection/base.rb#L170
[14:04:58] matthewd: Sounds like it's supposed to :/
[14:05:51] k13nox: matthewd: thanks a lot
[14:06:03] matthewd: That's "so please do poke around, it sounds like a bug", not "I don't believe you" ;)
[14:06:38] RegulationD: has joined #RubyOnRails
[14:06:42] dcope: has anyone in here used tcocca/acts_as_follower?
[14:06:47] dcope: would love to hear thoughts about it.
[14:08:14] Scripore: has joined #RubyOnRails
[14:08:46] goodcodeguy: has joined #RubyOnRails
[14:08:54] k13nox: matthewd: yes, i just put a log in `unsubscribed` :D but didn'd show the log :( it's hard to debug actioncable like rails controller/model :( need to restart everytime
[14:10:11] msyvich: has joined #RubyOnRails
[14:10:14] matthewd: Yeah, I normally just add 'puts' calls all over the place :|
[14:11:05] confact: but i heard actioncable works better than websocket-rails?
[14:14:36] Ropeney: has joined #RubyOnRails
[14:17:45] k13nox: Erf same problem with `disconnect` in Connection :| i'm lost
[14:17:47] Lingo_____: has joined #RubyOnRails
[14:18:59] openstruct: has joined #RubyOnRails
[14:19:47] baweaver: has joined #RubyOnRails
[14:20:25] tetraktys: has joined #RubyOnRails
[14:20:32] drbayer: has joined #RubyOnRails
[14:20:45] ravster: has joined #RubyOnRails
[14:21:16] matthewd: k13nox: Did you check whether we're getting into handle_close ?
[14:21:26] sleungcy: has joined #RubyOnRails
[14:23:19] arup_r: has joined #RubyOnRails
[14:23:22] matthewd: k13nox: Two explanations off the top of my head are that either that method never gets called, or it's silently hitting an exception before it does the thing we want
[14:23:38] matthewd: Once we know which of those is true, we know which direction to look
[14:24:09] matthewd: I'd just add puts 'aa1', puts 'aa2', etc in between each of its existing lines
[14:24:22] worknick: what can be the if condition for checking if first records created_at is max less than 3 seconds than the secord record?
[14:24:25] matthewd: ^^ Very Advanced Debugging Technique???
[14:24:47] matthewd: worknick: What do you have so far?
[14:26:03] sandstrom: has joined #RubyOnRails
[14:26:17] snowy: has joined #RubyOnRails
[14:26:58] mdw: has joined #RubyOnRails
[14:27:29] worknick: matthewd: thatns not for debugging. and meanwhile i changed the logic.
[14:28:27] matthewd: worknick: Oh, the debugging comment was about my previous message
[14:28:52] worknick: matthewd: can i do @var1.created_at > @var2.created_at then delete @var1
[14:29:04] worknick: there will be two records created. i want to delete the latest.
[14:29:56] blackmesa: has joined #RubyOnRails
[14:30:05] matthewd: Yeah, that sounds like it will do what you want
[14:30:09] techsethi: has joined #RubyOnRails
[14:30:34] matthewd: (it sounds like a bit of an XY question, though)
[14:30:51] worknick: whats XY question?
[14:31:00] helpa: It seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
[14:31:31] msyvich: has joined #RubyOnRails
[14:32:17] matthewd: i.e., it sounds like "delete the latest of two nearly-simultaneously created records" is a solution to some other problem
[14:32:53] matthewd: (.. and it's reasonably possible there might be another, more elegant, solution to that problem)
[14:32:54] tuxaanand: has joined #RubyOnRails
[14:33:12] k13nox: matthewd: handle_close never called, i thinks it's my configuration with NGINX HTTPS > PUMA 16 threads > ActionCable
[14:33:53] matthewd: k13nox: Ah, can you confirm it gets called if you skip nginx and connect directly to puma, as a test?
[14:34:12] eikood: has joined #RubyOnRails
[14:34:15] matthewd: Maybe nginx isn't passing along the close in a timely manner?
[14:34:25] k13nox: matthewd: i will go try
[14:35:39] worknick: matthewd: i have pet_activities table where my pets all activies go. i am using public_activity gem. now when i crate text only pet_activity public_activity created one row. but when i create image activity using paperclip, public_activity created two rows one for cerate and one for update. i dont why why and how. paperclip is to be blamed. so i dont want to show all those two public_activites hence
[14:35:40] worknick: deleting the latest one which is update
[14:36:29] solars: quick question, is there a shorter/cleaner/correcter way to do this: https://gist.github.com/solars/d61a9139e97b8d4996c4 if I only have json response/requests?
[14:38:18] matthewd: worknick: What's the line that actually creates the thing? If you're calling Model.create(), maybe it'd help to call Model.new(), then call save on that afterwards?
[14:39:00] n1lo: has joined #RubyOnRails
[14:39:02] matthewd: worknick: If something with the complexity of paperclip is involved though, I do concede that just cleaning up after it might indeed be the simplest choice
[14:39:06] n1lo_: has joined #RubyOnRails
[14:39:15] n1lo__: has joined #RubyOnRails
[14:39:27] worknick: matthewd: its just palin basic create action. yes cleaning is simplest.
[14:40:45] matthewd: solars: If you don't support multiple formats, you don't need respond_to/format
[14:41:30] lacrymology: has joined #RubyOnRails
[14:41:44] eikood: has joined #RubyOnRails
[14:42:44] eikood: has joined #RubyOnRails
[14:42:45] sankaber: has joined #RubyOnRails
[14:43:14] eikood: has joined #RubyOnRails
[14:43:24] rubyonrailed: has joined #RubyOnRails
[14:43:48] solars: matthewd, well that's a point
[14:44:19] eikood: has joined #RubyOnRails
[14:44:32] rails750: has joined #RubyOnRails
[14:45:26] MaDErroR123: has joined #RubyOnRails
[14:45:37] godzillaenlacasa: has joined #RubyOnRails
[14:45:41] sankaber: has joined #RubyOnRails
[14:47:25] floror: has joined #RubyOnRails
[14:47:33] dalpo: has joined #RubyOnRails
[14:49:51] adre: has joined #RubyOnRails
[14:50:06] techsethi: has joined #RubyOnRails
[14:50:34] Devalo: has joined #RubyOnRails
[14:50:54] JoshGlzBrk: has joined #RubyOnRails
[14:50:55] ramortegui: has joined #RubyOnRails
[14:55:37] mary5030: has joined #RubyOnRails
[14:56:57] MaDErroR123: has joined #RubyOnRails
[15:00:23] msyvich: has joined #RubyOnRails
[15:00:24] mary5030: has joined #RubyOnRails
[15:00:26] braian: Hi guys! I'm trying to render a view into a windows.print(). Anyone can send it to him into the controller?
[15:01:45] MaDErroR_: has joined #RubyOnRails
[15:04:22] k13nox: matthewd: i have removed nginx and https, to connect directly to puma but same problem :|
[15:05:45] matthewd: k13nox: Huh. Next step backwards is on_close
[15:06:20] matthewd: And then finalize_close over in the ClientSocket
[15:07:03] eljimmy: has joined #RubyOnRails
[15:07:07] drbayer: has joined #RubyOnRails
[15:08:36] stannard: has joined #RubyOnRails
[15:09:38] stannard: has joined #RubyOnRails
[15:09:55] p1k: has joined #RubyOnRails
[15:11:37] crystal77: has joined #RubyOnRails
[15:12:13] Lingo_____: has joined #RubyOnRails
[15:12:20] rails750: did anybody have hiccups when trying to use pgbackups + scheduler on your rails app?
[15:12:27] rails750: sometimes it gave me these errors
[15:12:37] k13nox: matthewd: on_close not triggered
[15:12:53] rails750: app/scheduler.7139: rake aborted! app/scheduler.7139: RestClient::InternalServerError: 500 Internal Server Error app/scheduler.7139: Tasks: TOP => pgbackups:archive
[15:15:26] matthewd: k13nox: The approximate start of the chain (that I expect to occur) is https://github.com/rails/rails/blob/703ddadafee29c86ca5be499a80802fbea70a64f/actioncable/lib/action_cable/connection/stream_event_loop.rb#L83
[15:15:31] sleungcy: has joined #RubyOnRails
[15:16:48] dionysus69: has joined #RubyOnRails
[15:18:14] rubyonrailed: has joined #RubyOnRails
[15:18:43] yereby: has joined #RubyOnRails
[15:19:08] pawnbox: has joined #RubyOnRails
[15:21:44] herpless: has joined #RubyOnRails
[15:22:19] k13nox: matthewd: when i close tab i go here https://github.com/rails/rails/blob/703ddadafee29c86ca5be499a80802fbea70a64f/actioncable/lib/action_cable/connection/stream_event_loop.rb#L74
[15:22:43] k13nox: matthewd: but the rescue after never triggered :|
[15:23:11] matthewd: What's the read_nonblock returning? :/
[15:23:17] k13nox: matthewd: Some timeout configuration with ActionCable ?
[15:24:44] k13nox: WTF `puts io.read_nonblock(4096)` triggered the rescue
[15:26:01] matthewd: Ah, you'll need to read into a variable then puts (inspect) it and stream.receive it, to keep the existing behaviour
[15:26:19] matthewd: Otherwise we'll be doing a double-read, and that'll make things different
[15:29:32] y2mq37: has joined #RubyOnRails
[15:31:20] B1n4r10: has joined #RubyOnRails
[15:31:48] blackmesa: has joined #RubyOnRails
[15:33:29] DmitryBochkarev: has joined #RubyOnRails
[15:34:04] k13nox: Ok but `puts` before stream.receive keep the problem :|
[15:34:31] matthewd: Right.. but what is the value?
[15:35:15] matthewd: nil, empty string, or some valid not-yet-received data?
[15:35:16] floror: has joined #RubyOnRails
[15:36:22] k13nox: `\x81\xFE\x00\x8.....`
[15:38:13] msyvich: has joined #RubyOnRails
[15:38:59] matthewd: Hmm, so, a valid message
[15:39:56] matthewd: So my *expectation* is that it should loop around, and the select should again return, telling us the stream is worth looking at (because it's just become closed)
[15:40:06] braian: has joined #RubyOnRails
[15:40:56] Scriptonaut: has joined #RubyOnRails
[15:41:09] dopamean1: has joined #RubyOnRails
[15:41:20] adavia: has joined #RubyOnRails
[15:42:04] Scriptonaut: Hey all, I am having issues with model callbacks. I have the before_save :update_status_metadata, if: :update_status_metadata? callback. I have confirmed that update_status_metadata? is returning true, however it won't run the update_status_metadata method, anyone know why this would be? Here is my entire model file: https://gist.github.com/anonymous/80c006f1793c56fce85a
[15:42:30] nogic: has joined #RubyOnRails
[15:42:34] LeMalandrin: has joined #RubyOnRails
[15:42:54] Scriptonaut: so, when I change the status, and then save, the if: part is returning true, but it still won't execute the method (symbol) I pass it
[15:43:01] matthewd: k13nox: Well, s/closed/EOF/, technically speaking
[15:43:19] nogic: has joined #RubyOnRails
[15:43:32] matthewd: k13nox: But instead, after that last successful read, I take it you then end up blocking on the select?
[15:44:07] emachnic: has joined #RubyOnRails
[15:44:18] nogic: has joined #RubyOnRails
[15:44:51] momomomomo: has joined #RubyOnRails
[15:44:59] nogic: has joined #RubyOnRails
[15:45:49] nogic: has joined #RubyOnRails
[15:46:08] techsethi: has joined #RubyOnRails
[15:47:29] LeMalandrin: I have an issue on rails :/ my english is'nt really good, sorry ^^
[15:47:42] LeMalandrin: Am i in the right room ?
[15:48:26] aaronr: has joined #RubyOnRails
[15:48:39] slash_nick: LeMalandrin: you are, what's wrong?
[15:48:54] LeMalandrin: Hi slash_nick ^^
[15:49:23] macsteps: has joined #RubyOnRails
[15:49:59] LeMalandrin: mmmh can i add a link to show you my MCD ?
[15:50:15] LeMalandrin: cuz' my issue is about a migration
[15:50:43] slash_nick: LeMalandrin: sure
[15:50:47] LeMalandrin: http://chat.developpez.com/upload/56bdfb7c15a17/entity_join_multiple.jpg
[15:50:51] LeMalandrin: here this is my MCD
[15:51:04] LeMalandrin: i want to specify a join table migration with 3 table
[15:51:24] LeMalandrin: how can i get this ? ^^
[15:51:59] bauerbob: has joined #RubyOnRails
[15:52:19] k13nox: matthewd: i didn't understand :/
[15:52:47] Devalo: has joined #RubyOnRails
[15:53:16] matthewd: k13nox: After the successful receive (with no exception), we end up back up at the `loop do`
[15:53:32] matthewd: k13nox: Right?
[15:53:49] bauerbob: hi. i???m having trouble with the confirmation_token of devise after upgrading to rails 4.2/devise 3.5. i know the tokens in the mail should not match the ones in the email anymore, because they are stored encrypted now. problem is: they aren???t stored encrypted. the one in the database matches the one in the email.
[15:53:53] slash_nick: LeMalandrin: a post_topic_users table? with foreign keys, post_id, topic_id, users_id...
[15:54:17] bauerbob: looks like i???m having this problem: https://github.com/plataformatec/devise/issues/2615
[15:54:20] LeMalandrin: yeah absolutely !
[15:55:10] bauerbob: however i don???t think the solution is to do token encryption manually and overwrite user.confirmation_token manually
[15:55:45] Macaveli: has joined #RubyOnRails
[15:55:50] k13nox: matthewd: yes
[15:56:23] matthewd: k13nox: So that should then run through to the `.select`
[15:56:47] slash_nick: LeMalandrin: add has_many :post_topic_users to the three models as well... post_topic_user belongs_to each of those three
[15:57:08] matthewd: Then I expect the select to return our just-closed IO again, just as it did last time when there was an outstanding message
[15:58:34] kmckelvin: has joined #RubyOnRails
[15:59:29] y2mq37: has joined #RubyOnRails
[15:59:40] LeMalandrin: but...this will specify to the models the M2M relation, but my table need to be created before, no ? :/
[15:59:45] slash_nick: any idea what could cause params to be parsed differently in a controller test than on a development server? https://github.com/rthbound/controller-test-defect-rails-5
[16:00:37] slash_nick: LeMalandrin: yeah... see http://guides.rubyonrails.org/active_record_migrations.html#model-generators
[16:01:51] mary5030: has joined #RubyOnRails
[16:02:57] slash_nick: LeMalandrin: there's some good stuff in there... http://guides.rubyonrails.org/active_record_migrations.html#creating-a-join-table
[16:03:03] roshanavand: has joined #RubyOnRails
[16:03:55] alex88: has joined #RubyOnRails
[16:04:16] arup_r: has left #RubyOnRails: ()
[16:05:00] tenderlove: has joined #RubyOnRails
[16:05:03] triptec_: has joined #RubyOnRails
[16:05:32] B1n4r10: has joined #RubyOnRails
[16:06:26] Lingo_____: has joined #RubyOnRails
[16:07:05] y2mq37: has joined #RubyOnRails
[16:07:22] msyvich: has joined #RubyOnRails
[16:08:03] banister: has joined #RubyOnRails
[16:08:59] jgpawletko: has joined #RubyOnRails
[16:09:32] sleungcy: has joined #RubyOnRails
[16:12:18] arthropododo: has joined #RubyOnRails
[16:13:38] momomomomo: has joined #RubyOnRails
[16:14:51] kies^: has joined #RubyOnRails
[16:15:01] chouhoulis: has joined #RubyOnRails
[16:15:36] aegis3121: has joined #RubyOnRails
[16:17:18] k13nox: matthewd: yes stop at https://github.com/rails/rails/blob/703ddadafee29c86ca5be499a80802fbea70a64f/actioncable/lib/action_cable/connection/stream_event_loop.rb#L67
[16:19:58] techsethi: has joined #RubyOnRails
[16:20:13] matthewd: k13nox: Yeah, that seems surprising to me
[16:20:21] matthewd: k13nox: Is any of https://github.com/rails/rails/blob/703ddadafee29c86ca5be499a80802fbea70a64f/actioncable/lib/action_cable/connection/stream_event_loop.rb#L25-L27 happening around this time?
[16:20:43] matthewd: (either a call to detach, or an invocation of the @todo block?)
[16:22:00] jgt4: has joined #RubyOnRails
[16:23:52] johnflux: has joined #RubyOnRails
[16:23:57] NBarnes: has joined #RubyOnRails
[16:24:27] smoitra: has joined #RubyOnRails
[16:25:58] k13nox: matthewd: yes `detach` is called and TCPSocket is deregister and delete with no error but perhaps silently hitting an exception
[16:26:38] jgt: has joined #RubyOnRails
[16:26:56] pjb42: has joined #RubyOnRails
[16:26:57] hamed_r: has joined #RubyOnRails
[16:28:13] k13nox: matthewd: perhaps it's the Thread::Queue
[16:28:17] hashrocket: has joined #RubyOnRails
[16:29:52] matthewd: Okay, if we're doing the detach, that means we're "voluntarily" closing the connection in response to the message we read, before we notice it's hit EOF
[16:30:06] smoitra: Hi, all I am trying my hands on rails 5.0.0.beta2 but I got this error while migrating http://fpaste.org/321848/52945261/
[16:30:24] matthewd: So, I guess we'll need to follow that received message
[16:30:28] matthewd: It should go through https://github.com/rails/rails/blob/daa4779d22d3458c5ef45a21370ed0eafb1cd664/actioncable/lib/action_cable/connection/message_buffer.rb#L14
[16:30:33] Lingo_____: has joined #RubyOnRails
[16:31:00] matthewd: then https://github.com/rails/rails/blob/daa4779d22d3458c5ef45a21370ed0eafb1cd664/actioncable/lib/action_cable/connection/base.rb#L83
[16:31:14] matthewd: and thus https://github.com/rails/rails/blob/daa4779d22d3458c5ef45a21370ed0eafb1cd664/actioncable/lib/action_cable/connection/subscriptions.rb#L14
[16:31:53] matthewd: k13nox: Can you confirm that's the path it's taking, and what the data looks like / where it goes from there?
[16:33:24] rogue_koder: has joined #RubyOnRails
[16:33:36] rafaelfranca: has joined #RubyOnRails
[16:33:49] matthewd: smoitra: That's a warning, not an error, and seems to be telling you what it thinks you should do
[16:34:20] matthewd: smoitra: Also, thanks for trying the beta <3 <3
[16:36:27] rafaelfranca: has joined #RubyOnRails
[16:38:28] pjb42: somebody recently told me that I need to restart Spring everytime I checkout a branch of my Rails project or I???ll get unexpected things happening. Is this true?
[16:44:22] treehug88: has joined #RubyOnRails
[16:45:28] lacrymol1gy: has joined #RubyOnRails
[16:46:05] lacrymol1gy: has left #RubyOnRails: ()
[16:46:34] FooMunki: has joined #RubyOnRails
[16:47:23] stannard: has joined #RubyOnRails
[16:47:31] baweaver: has joined #RubyOnRails
[16:49:34] tenderlove: has joined #RubyOnRails
[16:51:21] polishdub: has joined #RubyOnRails
[16:51:42] corioliss: has joined #RubyOnRails
[16:52:45] dominic: has joined #RubyOnRails
[16:53:08] blackmesa: has joined #RubyOnRails
[16:53:17] drbayer: has joined #RubyOnRails
[16:54:00] MaDErroR123: has joined #RubyOnRails
[16:54:30] dsimon: Scriptonaut, how do you know it's not running the update_status_metadata method?
[16:54:57] lubekpl: has joined #RubyOnRails
[16:55:09] dsimon: also: is it trying to run the update_status_metadata? method, or is that only being ran when you do so manually?
[16:55:18] chouhoulis: has joined #RubyOnRails
[16:56:15] ikarius: has joined #RubyOnRails
[16:56:37] disgrntld: has joined #RubyOnRails
[16:58:34] replay: has joined #RubyOnRails
[16:59:47] alex88: has joined #RubyOnRails
[17:00:59] sheldo: has joined #RubyOnRails
[17:01:07] Scriptonaut: dsimon: I put a binding pry in there
[17:01:22] Scriptonaut: I found out what it was, apparently update_status_metadata is a reserved activerecord method
[17:01:31] Scriptonaut: so I just changed the name and it worked
[17:02:23] bruce__lee: has joined #RubyOnRails
[17:02:42] momomomomo: has joined #RubyOnRails
[17:02:52] Lingo_____: has joined #RubyOnRails
[17:03:39] dalpo: has joined #RubyOnRails
[17:03:42] sleungcy: has joined #RubyOnRails
[17:03:43] arup_r: has joined #RubyOnRails
[17:04:11] lessless: has joined #RubyOnRails
[17:04:40] ikarius: grumble. trying to get ruby on rails up on a fedora 20 system, rails install went completely smoothly, everything was hunky dory until I did a "rails new myapp", and then tried "bin/rails server" - then it bottomed out failing to load the sqlite3 gem, fixed that by altering the gemspec for sqlite3 to pull in lib/sqlite3_native instead of lib
[17:05:38] ikarius: but we weren't done there. it was complaining I should use "gem pristine --all" to regenerate
[17:05:54] ikarius: and that failed first with bigdecimal, then io-console, then psych
[17:06:07] ikarius: oh, and json too
[17:06:20] ikarius: I was able to uninstall/reinstall bigdecimal, io-console, and json
[17:06:21] bronson: has joined #RubyOnRails
[17:06:26] Synthead: has joined #RubyOnRails
[17:06:44] ikarius: but apparently uninstalling psych was a no-no, as gem stopped working, and I am now unable to reinstall psych
[17:07:06] ikarius: anyone have a suggestion for how I can continue on this?
[17:08:09] RegulationD: has joined #RubyOnRails
[17:08:43] benlieb: has joined #RubyOnRails
[17:08:52] macsteps: has joined #RubyOnRails
[17:08:54] dominic: has left #RubyOnRails: (":wq")
[17:12:10] dalpo: has joined #RubyOnRails
[17:12:39] aep: is there any non-ugly out-of-the-box theme for rails admin?
[17:12:47] MaDErroR123: has joined #RubyOnRails
[17:12:57] KensoDev: has joined #RubyOnRails
[17:13:10] sarink: has joined #RubyOnRails
[17:13:12] AzaToth: has joined #RubyOnRails
[17:13:40] mdw: has joined #RubyOnRails
[17:13:52] aep: or typus
[17:14:45] artto: has joined #RubyOnRails
[17:17:21] mbreedlove: has joined #RubyOnRails
[17:17:46] manfrin: has joined #RubyOnRails
[17:19:09] slash_nick: ugh, i just took an exhausting trek stepping through a test request... still have no idea where things go wrong: https://github.com/rails/rails/issues/23624#issuecomment-183418554
[17:22:21] NeoHamled: has joined #RubyOnRails
[17:23:45] pawnbox: has joined #RubyOnRails
[17:25:31] sonalkr132: has joined #RubyOnRails
[17:25:59] czerasz: has joined #RubyOnRails
[17:27:55] jahbrewski: /join #angularjs
[17:28:05] roshanavand: has joined #RubyOnRails
[17:28:11] pawnbox: has joined #RubyOnRails
[17:28:41] jahbrewski: whoops. didn't mean to troll. accidental space :)
[17:29:22] nogic: has joined #RubyOnRails
[17:30:09] blackmesa: has joined #RubyOnRails
[17:30:14] nogic: has joined #RubyOnRails
[17:30:46] Maletor: has joined #RubyOnRails
[17:30:48] Cervajz: has joined #RubyOnRails
[17:30:57] ss_much: has joined #RubyOnRails
[17:31:15] nogic: has joined #RubyOnRails
[17:33:17] floror: has joined #RubyOnRails
[17:34:02] fedexo: has joined #RubyOnRails
[17:35:51] sheldo: has joined #RubyOnRails
[17:37:10] mbreedlove: has joined #RubyOnRails
[17:37:54] roshanavand: has joined #RubyOnRails
[17:38:54] ikarius: oh fsking sigh. Turns out all the gems that blew up during gem pristine were installed as RPM packages. When will fucking OS bundlers figure out how to stop breaking languages when they package them?
[17:39:16] ikarius: uninstalling all of ruby and reinstall it via rvm.
[17:40:35] mbreedlove: has joined #RubyOnRails
[17:43:58] nettoweb: has joined #RubyOnRails
[17:45:02] ur5us: has joined #RubyOnRails
[17:48:10] chipotle: has joined #RubyOnRails
[17:52:05] techsethi: has joined #RubyOnRails
[17:52:29] Cervajz: has joined #RubyOnRails
[17:52:34] mdw: has joined #RubyOnRails
[17:53:53] intrigueD: has joined #RubyOnRails
[17:54:06] adac: has joined #RubyOnRails
[17:54:22] triptec: has joined #RubyOnRails
[17:55:05] techsethi_: has joined #RubyOnRails
[17:55:12] mbreedlove: has joined #RubyOnRails
[17:55:17] baweaver: has joined #RubyOnRails
[17:55:20] chipotle: has joined #RubyOnRails
[17:55:48] jottr: has joined #RubyOnRails
[17:56:17] [Butch]: has joined #RubyOnRails
[17:57:14] Lingo_____: has joined #RubyOnRails
[17:57:46] sleungcy: has joined #RubyOnRails
[17:57:55] safety_cut: has joined #RubyOnRails
[17:58:22] aep: is there a simple active job backend that runs with 'rails s'?
[17:58:55] sleungcy: has joined #RubyOnRails
[17:59:45] aep: ah. sucker punch seems to be what i want
[18:02:07] pulpfiction: has joined #RubyOnRails
[18:02:57] pulpfiction: i configured my cache_store to rails on a initializers/cache.rb. when using locally, everything works as expected. when deploying my application, i'm seeing a "ArgumentError: wrong number of arguments (given 2, expected 0)"
[18:03:03] pulpfiction: any idea what that might be?
[18:03:08] netzfisch: has joined #RubyOnRails
[18:03:24] pulpfiction: i'm configuring it using the following syntax: Rails.application.config.cache_store :redis_store, { my_options }
[18:05:55] SteenJobs: has joined #RubyOnRails
[18:07:20] goodcodeguy: has joined #RubyOnRails
[18:08:05] aegis3121: has joined #RubyOnRails
[18:08:23] pulpfiction: i mean, cache_store to redis*
[18:08:23] tubbo: pulpfiction: !gist that line of code
[18:08:23] helpa: pulpfiction: http://gist.github.com - Put your codes online with pretty syntax highlighting and the ability to embed it into other pages.
[18:08:36] DmitryBochkarev: has joined #RubyOnRails
[18:09:24] jottr: has joined #RubyOnRails
[18:09:38] ElFerna_: has joined #RubyOnRails
[18:09:55] arBmind: has joined #RubyOnRails
[18:10:10] pulpfiction: tubbo, https://gist.github.com/anonymous/f8d65fca9bf7387ac5a2
[18:10:16] speakingcode: has joined #RubyOnRails
[18:10:31] B1n4r10: has joined #RubyOnRails
[18:11:07] pawnbox: has joined #RubyOnRails
[18:11:46] rakm: has joined #RubyOnRails
[18:11:55] slash_nick: matthewd: can you offer any guidance on https://github.com/rails/rails/issues/23624?
[18:13:11] tubbo: pulpfiction: looks good to me...usually i set config.cache_store in production.rb, but i suppose doing it in an initializer shouldn't affect anything
[18:13:32] hcnewsom: has joined #RubyOnRails
[18:13:35] tubbo: pulpfiction: you sure that's the line it's blowing up on? not configuring `config.cache_store` anywhere else?
[18:16:07] pulpfiction: tubbo, yah, pretty sure: https://gist.github.com/anonymous/733e2582265c080767f9
[18:16:22] Spami: has joined #RubyOnRails
[18:17:27] tubbo: pulpfiction: ahh i see, because it's `config.cache_store = :redis_store`, not `config.cache_store :redis_store`
[18:17:34] tubbo: the method is actually 'cache_store=' :)
[18:17:53] adac: has joined #RubyOnRails
[18:19:10] Cervajz: has joined #RubyOnRails
[18:19:11] greengriminal: has joined #RubyOnRails
[18:19:58] ur5us: has joined #RubyOnRails
[18:21:13] pawnbox: has joined #RubyOnRails
[18:22:10] teaearlgraycold: So to avoid n+1s I've been adding .includes(:model) to different controller requests, but I'm /still/ getting queries for each of the n records returned
[18:22:33] pulpfiction: tubbo, many thanks, i used the session_store as example and that one didn't have the `=`
[18:22:54] napstablook: has joined #RubyOnRails
[18:23:02] tubbo: pulpfiction: hah yeah...screwed me up when i was starting out too. that inconsistent API has always been that way, not sure why it can't get changed
[18:23:12] tubbo: maybe something to do with breaking backwards compatibility? who knows
[18:23:45] maesitos: has joined #RubyOnRails
[18:24:54] SteenJobs: has joined #RubyOnRails
[18:25:55] stannard: has joined #RubyOnRails
[18:26:06] PedramT: has joined #RubyOnRails
[18:28:35] theery: has joined #RubyOnRails
[18:29:17] PedramT: has joined #RubyOnRails
[18:29:57] teaearlgraycold: Bad code on my part
[18:31:26] blooky: has joined #RubyOnRails
[18:31:34] NBarnes: has joined #RubyOnRails
[18:32:53] safety_cut: has joined #RubyOnRails
[18:32:53] blooky: hey everyone
[18:33:11] blooky: I'm a huge newbie on ruby and on rails
[18:33:30] blooky: and I'm trying to make an application that determines whether two words are anagrams
[18:33:46] blooky: but I can only find tutorials for crud based applications
[18:33:51] blooky: can anyone help me out?
[18:34:13] xTeixeira: has joined #RubyOnRails
[18:35:09] teaearlgraycold: blooky: you can do that with JS
[18:35:11] lacrymology: has joined #RubyOnRails
[18:35:21] teaearlgraycold: But if you want to do it on the server side it'd be pretty easy
[18:35:52] Cervajz_: has joined #RubyOnRails
[18:36:02] blooky: how would I go about doing that?
[18:36:17] openstruct: You probably won't find a tutorial for an application to solve algorithms.
[18:36:30] teaearlgraycold: Well first create a view that has a couple of input fields
[18:36:31] smathy: has joined #RubyOnRails
[18:36:52] blooky: I already made a simple view
[18:36:58] blooky: it's just two text fields
[18:37:07] teaearlgraycold: Okay, then have them in a form that POSTs to a controller action
[18:37:37] teaearlgraycold: Have them come through as parameters, then get them with params[:word_one] etc
[18:38:00] teaearlgraycold: The algorithm for anagrams is simply to sort a character array and then compare the two resulting strings
[18:38:31] blooky: how can I return the resulting boolean?
[18:38:32] teaearlgraycold: Them redirect the user/return success or status after determining your result
[18:38:35] blooky: do I make another post?
[18:38:35] bronson: has joined #RubyOnRails
[18:38:37] cschneid_: has joined #RubyOnRails
[18:38:45] teaearlgraycold: Well it should probably be handled by AJAX in the first place
[18:39:02] RegulationD: has joined #RubyOnRails
[18:39:07] teaearlgraycold: So you'll have some Javascript in the view that listens for an event that indicates you wish for server-side validation
[18:39:14] teaearlgraycold: Then makes the post itself
[18:39:31] teaearlgraycold: Then decodes a JSON formatted response and does something to the DOM according to the boolean
[18:39:52] teaearlgraycold: It'd be trivial to do this all in JS but I'm guessing you're just doing this as a learning exercise
[18:40:21] teaearlgraycold: Yeah so you want to do an ajax with JQuery or 'pure' JS
[18:40:23] blooky: ok, but if I manage to get it working on the server side I'll try to do it on the client side afterwards
[18:40:55] teaearlgraycold: You can also try doing a form_for with remote: true
[18:41:11] teaearlgraycold: Then in the controller do respond_to do |format|; format.js { blah blah}; end
[18:41:24] teaearlgraycold: And then have seperate .js responses according to the anagram-ness
[18:41:49] youngmathimus0: has joined #RubyOnRails
[18:42:08] teaearlgraycold: basically it'll download JS from the server and run it, so you can have one JS response that'll call alert('success'); and another that calls alert('failure');
[18:42:47] blooky: that sounds pretty efficient
[18:42:53] blooky: I'll def try that out!
[18:43:39] dextertzu: has joined #RubyOnRails
[18:43:47] srinidhi: has joined #RubyOnRails
[18:44:02] emachnic: has joined #RubyOnRails
[18:44:44] treehug88: has joined #RubyOnRails
[18:45:03] kirillzh: has joined #RubyOnRails
[18:45:08] adaccada: has joined #RubyOnRails
[18:45:08] baweaver: has joined #RubyOnRails
[18:46:13] Frem: has joined #RubyOnRails
[18:47:13] rubyonrails935: has joined #RubyOnRails
[18:48:23] ryanwinchester: has joined #RubyOnRails
[18:49:25] kirillzh: has joined #RubyOnRails
[18:49:27] PedramT: has joined #RubyOnRails
[18:51:29] Lingo_____: has joined #RubyOnRails
[18:51:52] aloneintheworld: has joined #RubyOnRails
[18:55:05] aloneintheworld: what Route and Action should I specify if I want to get a page where I edit only certain fields of a given model ?
[18:56:10] aloneintheworld: ie: /model/edit is where I edit most of the stuff. But I want to something like /model/location where I can get a page where I edit the location of my model
[18:56:23] dmarr: I'm trying to load a puma app on an osx machine but i'm getting malhttp: error: SSLError: [SSL: UNKNOWN_PROTOCOL] unknown protocol (_ssl.c:590) while doing GET request to URL: https://localhost:3000/
[18:57:05] aloneintheworld: what action do /model/location should point to?
[18:57:12] dmarr: i have openssl installed but it seems ruby is failing to use it
[18:57:30] tubbo: dmarr: you might have to recompile Ruby to use the installed OpenSSL headers.
[18:57:42] dmarr: trying that now :)
[18:57:42] tubbo: like if you installed openssl *after* compiling ruby, for example
[18:57:48] fox_mulder_cp: dmarr: use nginx as front proxy
[18:57:57] openstruct: aloneintheworld: Maybe something like get '/model/location`, to:model#special_edit`?
[18:58:13] marr: has joined #RubyOnRails
[18:58:22] aloneintheworld: so it???s ok to have multipl edit* actions within a controller
[18:58:24] dmarr: yeah i had 0.98 installed when i installed ruby the first time
[18:58:27] openstruct: Horrible quotations, sorry.
[18:58:32] dmarr: fox_mulder_cp: will give that a shot maybe
[18:58:37] crystal77: has joined #RubyOnRails
[18:58:50] aloneintheworld: openstruct: so it???s ok to have multiple edit* actions within a controller ?
[18:58:51] openstruct: You *can* but I generally like to stick to CRUD actions/
[18:58:57] tubbo: fox_mulder_cp: that won't fix dev :)
[18:59:22] aloneintheworld: openstruct: how would you stick to standard CRUD/REST if you edit different things in different pages for the same model/controller ?
[18:59:27] openstruct: I'd have it still hit #edit to keep things as close to REST as possible but you can generate vanity URIs f you really want.
[19:00:07] openstruct: Well...updates/edits don't require all fields to be updated
[19:00:27] openstruct: I could be totally wrong though :)
[19:00:42] fox_mulder_cp: tubbo: haha. __
[19:00:45] macsteps: has joined #RubyOnRails
[19:01:16] tubbo: SSL has to be allowed to terminate in Ruby if you're using config.force_ssl = true
[19:01:24] aloneintheworld: openstruct: sure, but how would edit knows what view to render
[19:01:25] netzfisch: has joined #RubyOnRails
[19:01:36] tubbo: also...you're gonna have other problems if you just cover over not having OpenSSL installed alongside Ruby by terminating at Nginx..
[19:01:57] rhizome: edit renders edit unless you tell it otherwise
[19:02:11] blackmesa: has joined #RubyOnRails
[19:03:09] maesitos: has joined #RubyOnRails
[19:04:06] aloneintheworld: what???s the standard way to tell edit that I want to edit this or that attributes and depending on that, render this or that view
[19:04:16] rhizome: aloneintheworld: once again, in english
[19:04:34] rhizome: it sounds like you might be doing it wrong
[19:04:55] theery: has joined #RubyOnRails
[19:05:02] aloneintheworld: so I have my main edit view for a given model. I want a different page to be displayed for the location attributes in the same model
[19:05:11] aloneintheworld: when editing location attributes
[19:05:28] rhizome: models don't touch views, controllers do
[19:05:47] dmarr: tubbo: reinstalling ruby didn't help
[19:06:26] kies^: has joined #RubyOnRails
[19:06:29] dmarr: is there some way to output rubys idea of ssl properties?
[19:06:30] rhizome: dmarr: do you have a cert generated?
[19:06:53] jsrn_: has joined #RubyOnRails
[19:06:54] tubbo: dmarr: what version of ruby are you using?
[19:07:09] tubbo: dmarr: how about openssl?
[19:07:18] tubbo: just wondering if maybe there's a weird gap between versions
[19:07:56] dmarr: rhizome: im OpenSSL 1.0.2e 3 Dec 2015
[19:08:02] dmarr: oops, tubbo OpenSSL 1.0.2e 3 Dec 2015
[19:08:55] fox_mulder_cp: aloneintheworld come out?
[19:09:19] dmarr: there are certs locally yes
[19:09:24] dionysus69: has joined #RubyOnRails
[19:09:38] tubbo: yeah that's what i got dmarr
[19:09:40] tubbo: weird shit
[19:09:49] alex88: has joined #RubyOnRails
[19:10:01] kirillzh: has joined #RubyOnRails
[19:10:18] dmarr: in the server log Invalid request: Invalid HTTP format, parsing fails.
[19:10:40] dmarr: and then that error i originally posted from the client
[19:10:57] techsethi: has joined #RubyOnRails
[19:11:22] dmarr: its a fresh box so maybe im missing something
[19:11:51] techsethi_: has joined #RubyOnRails
[19:12:10] rhizome: so is nginx actually configured to ssl?
[19:12:43] dmarr: i dont have nginx running
[19:12:46] dmarr: or installed
[19:12:56] lapide_viridi: has joined #RubyOnRails
[19:13:01] rhizome: oh, dev. right.
[19:13:14] rhizome: so does anything special need to be done to use ssl in dev?
[19:13:33] baweaver: has joined #RubyOnRails
[19:13:49] dmarr: # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
[19:13:49] dmarr: Byebug.start_server 'localhost', 12345 rescue nil
[19:13:49] dmarr: config.force_ssl = true
[19:13:57] dmarr: thats in my config
[19:14:22] dmarr: do I need to add my cert to openssl maybe?
[19:14:28] emachnic: has joined #RubyOnRails
[19:14:32] rhizome: and you've read stuff like http://www.railway.at/2013/02/12/using-ssl-in-your-local-rails-environment/
[19:15:05] dmarr: A CA file has been bootstrapped using certificates from the system
[19:15:06] dmarr: keychain. To add additional certificates, place .pem files in
[19:15:06] dmarr: /usr/local/etc/openssl/certs
[19:15:19] dmarr: i have a crt file, maybe i need to do something simliar?
[19:15:56] momomomomo: has joined #RubyOnRails
[19:22:44] hcnewsom: has joined #RubyOnRails
[19:22:55] dmarr: oh well moving on
[19:23:52] goodcodeguy: has joined #RubyOnRails
[19:25:26] PedramT: has joined #RubyOnRails
[19:25:36] DEA7TH: has joined #RubyOnRails
[19:25:49] beingjohnm: I've got a total n00b question. In my assets.rb I have "Rails.application.config.assets.precompile += %w( frontend.css )" and in one of my static pages I have "<%= stylesheet_link_tag "frontend" %>" but when testing that in production I get the error "ActionController::RoutingError (No route matches [GET] "/stylesheets/frontend.css"):". That shouldn't be a problem since I have it precompiling in assets.rb right?
[19:26:34] chouhoulis: has joined #RubyOnRails
[19:26:46] beingjohnm: Or do I need to run rake:precompile for that to work?
[19:26:47] eyck: has joined #RubyOnRails
[19:27:26] beingjohnm: Running rake:precompile adds hundreds of files to my git project though...
[19:28:00] podman: has joined #RubyOnRails
[19:31:57] chouhoulis: has joined #RubyOnRails
[19:37:44] PedramT: has joined #RubyOnRails
[19:38:22] teaearlgraycold: If I have a reference to an attribute of a model how can I tell if it's an enum?
[19:38:51] barhum2013: has joined #RubyOnRails
[19:39:10] rhizome: there are at least three different uses of "enum" in rails I can think of. which is yours?
[19:39:56] rhizome: you just gave me a good question to ask interviewers, tho
[19:40:31] teaearlgraycold: In a model, the declaration that an integer column is an enum
[19:40:44] drbayer: has joined #RubyOnRails
[19:41:10] teaearlgraycold: I can find out it's an integer faily easily, but how do I know if it's an enum?
[19:41:31] teaearlgraycold: Or alternatively, is there a method to get all attributes of a model with enums turned into their respective strings?
[19:41:34] greengriminal: Can someone shed a little light on this spec which involves stubbing a request: https://gist.github.com/davidpatters0n/353505199484735c3ef2
[19:41:43] qejk: has joined #RubyOnRails
[19:41:53] chipotle: has joined #RubyOnRails
[19:43:37] beingjohnm: so does everybody just ignore all of the precompiled assets in git?
[19:44:20] RegulationD: has joined #RubyOnRails
[19:45:03] rhizome: teaearlgraycold: models don't have columns
[19:45:06] manfrin: has joined #RubyOnRails
[19:45:37] kirillzh: has joined #RubyOnRails
[19:45:59] Lingo_____: has joined #RubyOnRails
[19:46:27] teaearlgraycold: Don't you think that's being deliberately obtuse?
[19:46:32] emachnic: has joined #RubyOnRails
[19:47:05] rhizome: well, i still don't know really what you're talking about
[19:47:45] smathy: teaearlgraycold, you'd be surprised how many assumptions that we think are perfectly reasonable to make turn out to be false.
[19:47:53] emachnic: has joined #RubyOnRails
[19:48:06] teaearlgraycold: Class Model < ActiveRecord::Base; enum type: [:one, :two, :three]; end
[19:48:17] teaearlgraycold: Like that. One of those.
[19:48:19] rhizome: don't use :type as a column name
[19:48:27] rhizome: unless you're using polymorphic associations
[19:48:28] teaearlgraycold: Ignoring that though
[19:48:46] rhizome: well shit, we just have to read between the lines with every answer i guess
[19:49:05] yardenbar: has joined #RubyOnRails
[19:49:17] smathy: Or if you do a self.abstract_class = true
[19:49:33] rhizome: sorry yes, STI
[19:49:43] baweaver: has joined #RubyOnRails
[19:50:04] smathy: No, I think I meant self.inheritance_column = :something_else
[19:50:11] smathy: I don't remember now.
[19:50:12] smathy: Stupid STI
[19:50:19] rhizome: it's just a fuzzy morning for everybody
[19:50:29] lolcodenewbie: has joined #RubyOnRails
[19:50:54] jottr: has joined #RubyOnRails
[19:51:12] smathy: teaearlgraycold, not sure what your question is, what do you mean "how do I know if it's an enum"? Are you talking about a DB-level enum, or are you asking how you know that you wrote `enum :something` in your own model?
[19:51:25] rhizome: enum something, model enum
[19:52:17] Cervajz: has joined #RubyOnRails
[19:52:25] teaearlgraycold: So if I do something like Model.first.attributes how do I get the symbol associated with all enums in the attribute hash
[19:52:37] teaearlgraycold: Because it seems like it's only giving out integers
[19:53:03] teaearlgraycold: I could either 1. iterate through all keys in the hash and check if they correspond to a defined enum as specified
[19:53:05] rhizome: as it should, right? the db datatype for that attribute is int, right?
[19:53:20] teaearlgraycold: Or 2. get the symbols
[19:53:35] teaearlgraycold: Well AR does other shenanigans to abstract away what the dB actually sees
[19:53:47] teaearlgraycold: Like if you're using SQLite
[19:53:47] rhizome: i mean, model enum is more akin to a validation than a class
[19:54:14] rhizome: sqlite lets you store strings in boolean columns, so it might not be the best case to use
[19:54:57] teaearlgraycold: I don't think SQLite's great for all purposes either, I'm just saying if you are using it ruby hides the true class types from you
[19:55:10] rhizome: class types?
[19:55:28] teaearlgraycold: So it translating enums defined in the model wouldn't be too far of a step to take
[19:55:47] teaearlgraycold: ie: 1.class # => Fixnum
[19:56:08] rhizome: right, that's what i was saying. model enums are not classes
[19:56:26] rhizome: it is not going to come out of the db as a one-element Enumerator
[19:56:27] baweaver: has joined #RubyOnRails
[19:56:29] teaearlgraycold: And they don't need to be, but they act as a mapping between two types
[19:56:54] rhizome: what is "they" here. you should probably use fewer pronouns
[19:57:40] teaearlgraycold: When you add "enum foo: [:bar]" to a model you're mapping integers to symbols, or vice-versa
[19:58:05] rhizome: there are two symbols in that example
[19:58:24] teaearlgraycold: :bar is a symbol
[19:58:30] teaearlgraycold: It corresponds to an integer value of 0
[19:58:43] rhizome: it does? how?
[19:59:06] skyjumper: does anyone have a preferred way to mass-import ActiveRecord models?
[19:59:12] rhizome: is it an existing symbol? seems overly dynamic/meta if it's what i'm imagining
[19:59:13] vr_mex: has joined #RubyOnRails
[19:59:14] nettoweb: has joined #RubyOnRails
[19:59:24] rhizome: skyjumper: from....
[19:59:35] skyjumper: rhizome: from an array, in this case
[19:59:47] dionysus69: has joined #RubyOnRails
[20:01:37] rhizome: not objects?
[20:01:43] rodfersou: has joined #RubyOnRails
[20:01:52] skyjumper: well, they could and should become model objects
[20:02:06] poushkar: has joined #RubyOnRails
[20:02:26] skyjumper: https://github.com/zdennis/activerecord-import looks like the solution but isn't playing nice with grpc
[20:02:44] drbayer: has joined #RubyOnRails
[20:03:16] blooky: hey, I'm still having some problems implementing the anagram solver
[20:03:44] blooky: mainly, I don't know how to make the form call a function inside my solver model
[20:03:59] blooky: I have a function called solve in the solver model
[20:04:19] blooky: what do I put under url: to make sure that function is called?
[20:05:02] Synthead: I have an app that doesn't leverage auth or cookies at all. it's just an api endpoint. can I do away with secret keys, or are they still needed for some reason?
[20:07:10] poushkar: @blooky in Rails which is a MVC framework, entry points are in controllers. Every time you access an URL, associated controller action is called to process it. In this action you can call your model function (in OOP it???s called a method) and return the result to a user.
[20:07:13] manfrin: has joined #RubyOnRails
[20:11:05] doublemalt__: has joined #RubyOnRails
[20:14:06] ZerGabriel: has joined #RubyOnRails
[20:15:44] moeabdol1: has joined #RubyOnRails
[20:17:29] yfeldblum: has joined #RubyOnRails
[20:17:53] blackmesa: has joined #RubyOnRails
[20:18:36] yardenbar: has joined #RubyOnRails
[20:19:51] joshkovach: has joined #RubyOnRails
[20:22:08] B1n4r10: has joined #RubyOnRails
[20:22:20] ur5us: has joined #RubyOnRails
[20:22:32] mostlybadfly: has joined #RubyOnRails
[20:25:00] banister: has joined #RubyOnRails
[20:25:16] srinidhi: has joined #RubyOnRails
[20:26:10] blooky: im sorry im bothering you guys so much with this but I'm really having a hard time here...
[20:26:35] blooky: ok, so I have on my bin/rake routes:
[20:27:11] blooky: solver_solve GET /solver/solve(.:format) solver#solve
[20:27:44] blooky: and I know that I have to use this in the url: field of the form to get it to go to the solve method in the controller
[20:28:11] blooky: but I've tried url: solver_solve and url: solver_path
[20:28:20] blooky: and I keep getting errors
[20:28:25] rafaelfranca: has joined #RubyOnRails
[20:28:39] rafaelfranca: has joined #RubyOnRails
[20:32:57] floror: has joined #RubyOnRails
[20:36:27] intrigueD: has joined #RubyOnRails
[20:36:52] Nikke: has joined #RubyOnRails
[20:37:10] Maletor: has joined #RubyOnRails
[20:39:09] hobodave: has joined #RubyOnRails
[20:40:12] teaearlgraycold: Well you guys are going to hate me, but this is what I did: http://pastie.org/private/qy4q8oocgjvtv7eyxtbb7g
[20:40:31] Nikke: hey guys.. wondering if anybody dealt with sidekiq a lot? maybe a gem that does this? i'm trying to make sure specific jobs dont run in a staging environment
[20:40:37] Nikke: or any environment
[20:40:40] Nikke: basically maybe queues that are environment specific?
[20:40:53] sheldo: has joined #RubyOnRails
[20:41:02] beingjohnm: I have some images in "/vendor/assets/frontend/images/" but for the life of me I cannot get them to load. Any suggestions?
[20:41:43] beingjohnm: I suspect there might be an issue with custom subdirectories under /vendor/assets but I'm not sure.
[20:42:01] nunchuck: has joined #RubyOnRails
[20:42:02] teaearlgraycold: beingjohnm: how are you calling the assets from the HTML?
[20:42:27] teaearlgraycold: nikk_: if it's specific jobs you could have them close out if Rails.env.production? fails
[20:42:49] beingjohnm: teaearlgraycold: <%= image_tag "All-0012.jpg", alt: "Keep in touch", :style => "width: 100%" %>
[20:42:58] teaearlgraycold: Or just do something like JobName.perform_later param if Rails.env.production?
[20:43:43] Nikke: i dont like putting env specific code into job logic
[20:43:51] Nikke: was hoping for some kind of config
[20:43:54] teaearlgraycold: beingjohnm: pretty sure you'll want to put the images in /vendor/assets/images/frontend then call it with "frontend/All-0012.jpg"
[20:44:02] Nikke: or maybe a gem
[20:44:04] beingjohnm: teaearlgraycold: I don't see the file under public/assets which makes me think it isn't being precompiled but I have "Rails.application.config.assets.precompile += %w( frontend/images/All-0118.jpg )" in assets.rb
[20:44:11] tubbo: nikk_: you could set up separate sidekiq.yml configs?
[20:44:21] tubbo: nikk_: and then just load sidekiq -c config/sidekiq/$RAILS_ENV.yml
[20:44:32] teaearlgraycold: Seems reasonable
[20:44:38] Nikke: i totally can, but i thought that no matter what , even if a queue isnt specified and a job gets scheduled, doesn't it just get createed?
[20:44:44] tubbo: nikk_: in that config you can tell sidekiq what queues to work on, so you can just omit the 'staging' or 'production' queue(s) from your respective servers.
[20:44:46] beingjohnm: teaearlgraycold: I'll give that a try. I was hoping to keep the frontend assets all under one folder.
[20:45:03] teaearlgraycold: beingjohnm: dont' think that's the "rails way tm"
[20:45:04] tubbo: nikk_: yeah the queue would get created if someone enqueues it, but if no workers pick it up does it really matter?
[20:45:08] teaearlgraycold: Or more so - the sprockets way
[20:45:29] tubbo: beingjohnm: assets.precompile are more for manifests and other stuff...doesn't apply to binary files like images.
[20:45:49] Nikke: if it's in a queue that got created, won't a worker automatically pick it up?
[20:45:50] tubbo: you shouldn't need to configure anything for stuff like images and fonts, just drop 'em in an assets dir and you're all good
[20:45:51] teaearlgraycold: You put all js files of a certain set in /assets/javascripts, all css files of that set in /assets/stylesheets
[20:45:55] beingjohnm: teaearlgraycold: I'm still learning the Rails ways :). I have a different design for the app than I do for the front end so was trying to keep them together.
[20:46:05] Jasaka: has joined #RubyOnRails
[20:46:50] teaearlgraycold: What do you mean?
[20:46:53] beingjohnm: tubbo: I totally didn't pick that up from all of my googling. I've been at this for six months and still much to learn.
[20:47:02] tubbo: nikk_: no. that's what i'm saying...if you configure sidekiq's `queues:`, it will only work on the queues you define.
[20:47:06] Limix: has joined #RubyOnRails
[20:47:09] Nikke: oh, really?!
[20:47:14] Nikke: i totally didnt know that
[20:47:15] tubbo: nikk_: i *think* so.
[20:47:19] teaearlgraycold: The front end is part of the app? And they're all part of your rails site so both should be Rails-y
[20:47:30] Nikke: i thought that wherever you define queues, thats just for "priority" sake
[20:47:39] Nikke: but if a job gets scheduled with a queue called "ASKDJSAKDJASKJSDK"
[20:47:43] Nikke: it'll just create it and run it
[20:47:47] Nikke: i can always try it i suppose
[20:47:51] Nikke: will report back
[20:47:52] beingjohnm: teaearlgraycold: I was trying to keep the landing page/login design all together and the app design all together. Frontend was a poor choice of words.
[20:47:55] tubbo: nikk_: https://github.com/mperham/sidekiq/wiki/Advanced-Options#queues
[20:47:58] tubbo: nikk_: confirmed :)
[20:48:21] Nikke: which part ?
[20:48:25] teaearlgraycold: beingjohnm: you should probably just use seperate layout files then
[20:48:38] adaccada: has joined #RubyOnRails
[20:48:45] Nikke: i read through that before
[20:48:46] teaearlgraycold: And in the layout for the "front end" you call a different application.css and application.js
[20:48:55] Nikke: did i miss something that says it wont work on a queue if its not defined
[20:49:29] tubbo: nikk_: probably :) or i think resque works closer to the way you're talking about
[20:49:40] tubbo: i distinctly remember dealing with a background job queue that works like that haha
[20:49:43] Nikke: alright ill just give it a whirl
[20:49:49] stannard: has joined #RubyOnRails
[20:51:41] Lingo_____: has joined #RubyOnRails
[20:51:45] baweaver: has joined #RubyOnRails
[20:52:29] robot__: has joined #RubyOnRails
[20:53:54] beingjohnm: teaearlgraycold: moving the images to /vendor/assets/images/frontend did the trick. It does seem I need to put them in assets.rb.
[20:54:22] manfrin: has joined #RubyOnRails
[20:54:53] treehug88: has joined #RubyOnRails
[20:55:59] treehug88: has joined #RubyOnRails
[20:57:27] rubyonrailed: has joined #RubyOnRails
[20:57:42] baweaver: has joined #RubyOnRails
[21:04:27] safety_cut: has joined #RubyOnRails
[21:07:55] dalpo: has joined #RubyOnRails
[21:08:24] renegadeandy: has joined #RubyOnRails
[21:09:50] emachnic: has joined #RubyOnRails
[21:10:47] safety_cut: has joined #RubyOnRails
[21:11:39] ur5us: has joined #RubyOnRails
[21:11:42] blooky: hey im having a different problem
[21:12:10] blooky: in routes.rb I put post 'solver/solve'
[21:12:24] blooky: it was 'get' before which was giving me a problem
[21:12:32] blooky: but now I'm getting a missing template error
[21:13:21] kirillzh: has joined #RubyOnRails
[21:15:52] jgpawletko_: has joined #RubyOnRails
[21:16:09] PedramT_: has joined #RubyOnRails
[21:16:50] goodcodeguy: has joined #RubyOnRails
[21:17:01] kirillzh: Does it make sense checking if User with token exists if collision is highly unlikely?
[21:17:48] rubyonrails958: has joined #RubyOnRails
[21:19:10] Limix: has joined #RubyOnRails
[21:19:14] n00bDev: has joined #RubyOnRails
[21:19:45] banister: has joined #RubyOnRails
[21:20:31] maesitos_: has joined #RubyOnRails
[21:20:57] safety_cut: has joined #RubyOnRails
[21:21:14] banister: has joined #RubyOnRails
[21:22:25] godzillaenlacasa: if I just added a new model that belongs_to something, but doesn't exist for the object yet, how can I go about creating a skeleton of it? For example: Options belongs_to User. But existing users don't have the Options reference yet.
[21:23:34] Limix_: has joined #RubyOnRails
[21:25:50] moresilenter: has joined #RubyOnRails
[21:26:06] sandstrom: has joined #RubyOnRails
[21:26:10] Coldblackice: has joined #RubyOnRails
[21:26:30] moresilenter: I have specific models I need to require before the constants are even autoloaded, where should I put the script to do this?
[21:26:36] Nikke: if i just add queues to a specific env in the YML file, the process will ONLY work on that queue! so confirmed.
[21:27:39] solars: has joined #RubyOnRails
[21:28:00] roshanavand: has joined #RubyOnRails
[21:28:16] JoshGlzBrk: has joined #RubyOnRails
[21:29:01] xardion: has joined #RubyOnRails
[21:32:24] PedramT: has joined #RubyOnRails
[21:35:44] duncannz: has joined #RubyOnRails
[21:36:34] duncannz: has joined #RubyOnRails
[21:37:59] duncannz: has joined #RubyOnRails
[21:38:32] n00bDev: anyone here use react with rails? How do you specify the image path? Im using webpack to compile my jsx
[21:39:10] dopamean_: has joined #RubyOnRails
[21:43:42] baweaver: has joined #RubyOnRails
[21:46:02] emachnic: has joined #RubyOnRails
[21:47:26] edwinvdgraaf: has joined #RubyOnRails
[21:47:29] floror: has joined #RubyOnRails
[21:47:55] blackmesa: has joined #RubyOnRails
[21:48:34] lacrymology: has joined #RubyOnRails
[21:52:50] pawnbox: has joined #RubyOnRails
[21:53:21] macsteps: has joined #RubyOnRails
[21:54:54] macsteps: has joined #RubyOnRails
[21:55:21] SteenJobs: has joined #RubyOnRails
[21:57:14] lemur: has joined #RubyOnRails
[22:01:23] i: has joined #RubyOnRails
[22:01:25] aegis3121: has joined #RubyOnRails
[22:03:09] FooMunki: has joined #RubyOnRails
[22:04:35] stannard: has joined #RubyOnRails
[22:06:58] floror: has joined #RubyOnRails
[22:09:52] rubyonrailed: has joined #RubyOnRails
[22:13:01] n1lo: has joined #RubyOnRails
[22:17:25] banister: has joined #RubyOnRails
[22:18:40] banister: has left #RubyOnRails: ()
[22:18:43] manfrin: has joined #RubyOnRails
[22:19:32] someish: has joined #RubyOnRails
[22:21:49] ferr: has joined #RubyOnRails
[22:22:08] mpowers_: has joined #RubyOnRails
[22:23:41] sandstrom: has joined #RubyOnRails
[22:24:37] intrigueD: has joined #RubyOnRails
[22:24:55] crystal77: has joined #RubyOnRails
[22:25:52] triptec: has joined #RubyOnRails
[22:27:52] rhizome: godzillaenlacasa: what do you mean? User doesn't have the association, or just that a user doesn't have any options assigned?
[22:28:18] mpowers_: has left #RubyOnRails: ()
[22:28:44] mpowers: has joined #RubyOnRails
[22:31:21] sheldo: has joined #RubyOnRails
[22:31:23] godzillaenlacasa: @rhizome the association doesn't exist yet for existing users. I'm creating it by default for now on in User#create
[22:31:40] smathy: kirillzh, put a DB uniqueness constraint on it and rescue ActiveRecord::RecordNotUnique
[22:31:47] bronson: Just moved some utilities into ApplicationRecord. Nice rails5 improvement.
[22:32:00] Scripore: has joined #RubyOnRails
[22:32:36] kirillzh: smathy would SecureRandom.base58(24) be enough for access token?
[22:32:46] bronson: But how the heck do I test them? ApplicationRecord.new dies due to abstract class (of course)
[22:32:58] bronson: and Class.new(ApplicationRecord).new dies because of nil table name I suppose
[22:33:05] smathy: godzillaenlacasa, if, as you say, Options belongs_to :user then the statement "but existing users don't have the options reference yet" doesn't make sense. No users will have an options reference, options have a user reference.
[22:33:47] smathy: kirillzh, 64, and sure - that'll work.
[22:34:19] godzillaenlacasa: @smathy I guess I'm saying it backwards then. I had a user model, I just added a new model 'Options' that belongs_to :user
[22:34:45] godzillaenlacasa: @smathy So, there are users that have already been created with no Options association
[22:35:18] smathy: godzillaenlacasa, so they'll just have an empty user.options collection.
[22:37:44] rhizome: yeah, it doesn't break anything
[22:37:52] rhizome: unless you have validations or summat
[22:38:24] godzillaenlacasa: @smathy right, they currently do. I want to give them a skeleton of the options collection though (all the values would be nil).
[22:38:37] shilon: has joined #RubyOnRails
[22:38:47] rhizome: what are you reinventing?
[22:39:01] rhizome: not being aggro, just asking ;)
[22:39:15] godzillaenlacasa: @smathy if I try to pull the form to manage the options for a user that doesn't have Options, then nothing comes up (it's supposed to be a bunch of checkboxes)
[22:39:47] rhizome: current_user.options.new or similar should give you the attrs needed to set up the form
[22:40:06] hcnewsom: has joined #RubyOnRails
[22:40:26] rhizome: it may just be that your form is broken
[22:41:40] yfeldblum: has joined #RubyOnRails
[22:42:10] smathy: godzillaenlacasa, as rhizome says, I'd pre-populate with something like `@user.options.new unless @user.options.present?` so the form has those values.
[22:42:35] chipotle: has joined #RubyOnRails
[22:42:44] godzillaenlacasa: @smathy ahh, that would work
[22:42:56] rhizome: will a symbol in a nested form call #new if necessary?
[22:43:30] dcope: is it possible to have specific DJ workers that work on a queue?
[22:43:48] dcope: ie 2 workers for "search" queue, 6 workers for "processing" queue, 10 workers for "persistance" queue etc.
[22:44:02] rhizome: why do you care
[22:44:52] Lingo_____: has joined #RubyOnRails
[22:45:37] dcope: rhizome: because i have a task that calls upon a third party service and is rate limited
[22:45:54] dcope: so i want to ensure that queue only has N concurrent connections, while the others can run wide open
[22:47:28] dcope: anyways, looks like it's possible
[22:50:22] Scripore: has joined #RubyOnRails
[22:50:33] hcnewsom: has joined #RubyOnRails
[22:52:23] pawnbox: has joined #RubyOnRails
[22:54:13] Limix: has joined #RubyOnRails
[22:55:37] one_zero: has joined #RubyOnRails
[22:56:37] armyriad: has joined #RubyOnRails
[22:58:02] baweaver: has joined #RubyOnRails
[22:59:22] benlieb: has joined #RubyOnRails
[23:01:44] meoblast001: has joined #RubyOnRails
[23:03:30] claytonzaugg: has joined #RubyOnRails
[23:04:00] drbayer: has joined #RubyOnRails
[23:04:01] Radar: GOOD MORNING
[23:04:06] s1|verfox: has joined #RubyOnRails
[23:04:07] stannard: has joined #RubyOnRails
[23:04:31] Radar: dcope: I don't know if DJ can do it (iirc, it can but only with an intense level of fiddling), but I know for a fact SIdekiq can be configured to do this.
[23:05:04] NeoHamled: Is it possible to use something like ???alias_attribute??? with an enum attribute?
[23:05:33] kmckelvin: has joined #RubyOnRails
[23:06:32] KensoDev: has joined #RubyOnRails
[23:06:53] Radar: NeoHamled: !rule0
[23:06:53] helpa: NeoHamled: Show rather than tell. Explaining your problem with code, stacktraces or errors is always preferred to explaining it with just text. Show us what's happening, rather than telling us. Put the code on https://gist.github.com and then give us the HTTP link to the Gist.
[23:07:32] barhum2013: has joined #RubyOnRails
[23:08:00] baweaver: has joined #RubyOnRails
[23:08:01] Radar: or maybe this is more of an
[23:08:01] helpa: It seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
[23:08:14] fox_mulder_cp: Radar: helo anf good night )
[23:12:32] Lingo_____: has joined #RubyOnRails
[23:12:40] NeoHamled: Radar: well I tried to write up what I???m dealing with in a more verbose manner, but there???s not really much code to show??? https://gist.github.com/Hamled/11829960d654e70b4a74
[23:13:34] n00bDev: has joined #RubyOnRails
[23:13:51] lexileo: has joined #RubyOnRails
[23:13:58] sevenseacat: has joined #RubyOnRails
[23:14:01] rubyonrailed: has joined #RubyOnRails
[23:15:19] matthias_: has joined #RubyOnRails
[23:17:41] lexiMon: has joined #RubyOnRails
[23:18:42] lexileo: has joined #RubyOnRails
[23:25:34] RegulationD: has joined #RubyOnRails
[23:26:23] dopamean_: has joined #RubyOnRails
[23:28:54] Scripore: has joined #RubyOnRails
[23:29:30] wethu: has joined #RubyOnRails
[23:30:00] Mia: has joined #RubyOnRails
[23:30:00] Mia: has joined #RubyOnRails
[23:30:40] mpowers: hello. anyone here familiar with ActiveRecord?
[23:31:13] safety_cut: has joined #RubyOnRails
[23:31:36] rhizome: mpowers: yes, several
[23:31:38] mpowers: I find myself wishing to support some vendor-specific SQL syntax, im wondering if anyone can point me to documentation about how to do that
[23:32:04] baweaver: has joined #RubyOnRails
[23:32:33] rhizome: "sql fragment" is probably a good filter for that
[23:33:06] mices: has joined #RubyOnRails
[23:35:02] mpowers: I know that I can submit a raw sql string to my database, but what im really looking for is a way to modify like, all the updates that are submitted to the database, regardless of what they are
[23:35:36] mpowers: in particular, im targeting the postgresql "returning" clause http://www.postgresql.org/docs/9.1/static/sql-update.html
[23:35:57] nettoweb: has joined #RubyOnRails
[23:37:33] maesitos: has joined #RubyOnRails
[23:38:01] mpowers: so im kinda looking for like, the right way to hook into activerecord so that when i send an update, i can also attach a returning clause to the query. hopefully without like, having to re-invent all of the nice work that activerecord is already doing to put the query together, quote arguments correctly, manage bound variables, etc.
[23:38:23] ElFerna_: has joined #RubyOnRails
[23:39:06] trinaldi: has joined #RubyOnRails
[23:41:03] hahuang61: has joined #RubyOnRails
[23:43:35] mwcmitchell: has joined #RubyOnRails
[23:47:01] maesitos: has joined #RubyOnRails
[23:49:03] maesitos: has joined #RubyOnRails
[23:53:10] smathy: mpowers, best is probably going to be to take a look at how RETURNING has been implemented for the INSERT statement in PG: https://github.com/rails/rails/blob/master/activerecord/lib/active_record/connection_adapters/postgresql/database_statements.rb#L127-L129
[23:54:36] mpowers: rhizome, smathy, thanks!
[23:54:47] Limix: has joined #RubyOnRails
[23:56:15] arBmind: has joined #RubyOnRails
[23:57:41] shilon: has joined #RubyOnRails
[23:58:33] shilon: has joined #RubyOnRails
[23:59:44] shilon: has joined #RubyOnRails