« Back to channel list

#RubyOnRails - 06 September 2018

« Back 1 day Forward 1 day »
[00:09:36] Radar: GOOD MORNING
[00:11:59] cagomez: has joined #RubyOnRails
[00:13:43] tdy: has joined #RubyOnRails
[00:16:49] apeiros_: has joined #RubyOnRails
[00:50:25] jkprg: has joined #RubyOnRails
[00:54:59] sevenseacat: has joined #RubyOnRails
[01:00:34] Guest58115: has joined #RubyOnRails
[01:05:43] jottr: has joined #RubyOnRails
[01:06:53] Caerus: Hey Radar, morning
[01:10:10] jtperreault: has joined #RubyOnRails
[01:11:36] apeiros_: has joined #RubyOnRails
[01:28:20] argoneus: has joined #RubyOnRails
[01:32:12] cagomez: has joined #RubyOnRails
[01:33:44] jjman: does helpers like form_with provide the AJAX javascript code?
[01:33:48] jtperreault: has joined #RubyOnRails
[01:34:57] fourcolors: has joined #RubyOnRails
[01:35:12] fourcolors: Hey I'm a little new to ActiveStorage and this is driving me a little nutz
[01:35:32] fourcolors: I'm trying to get an image url so I can include it in some json returned by a jbuilder
[01:35:38] fourcolors: I get this error signed_id delegated to attachment, but attachment is nil:
[01:35:55] fourcolors: I'm doing something like this json.preview rails_blob_url(map.preview)
[01:36:07] fourcolors: I have a Model named Map
[01:36:26] fourcolors: with a has_one_attached :preview
[01:36:34] fourcolors: I can see the image was uploaded to s3 correclty
[01:36:52] fourcolors: So I know there is an attachment there
[01:36:57] fourcolors: I'm not sure what I'm doing wrong here.
[01:47:04] Dimik: has joined #RubyOnRails
[01:54:01] mheld: has joined #RubyOnRails
[01:58:54] Croata: has joined #RubyOnRails
[02:01:38] jkprg: has joined #RubyOnRails
[02:06:25] apeiros_: has joined #RubyOnRails
[02:11:10] knight33: has joined #RubyOnRails
[02:34:48] duderonomy: has joined #RubyOnRails
[02:43:46] ariedler: has joined #RubyOnRails
[02:52:09] orbyt_: has joined #RubyOnRails
[02:55:35] brandoncc: has joined #RubyOnRails
[03:01:13] apeiros_: has joined #RubyOnRails
[03:06:30] jottr: has joined #RubyOnRails
[03:10:11] braincrash: has joined #RubyOnRails
[03:10:26] Gizmokid2005: has joined #RubyOnRails
[03:12:05] MedubzZ: has joined #RubyOnRails
[03:13:46] SuperTux88: has joined #RubyOnRails
[03:16:56] jkprg: has joined #RubyOnRails
[03:18:40] egray: has joined #RubyOnRails
[03:19:59] duderonomy: has joined #RubyOnRails
[03:28:35] jackhum: has joined #RubyOnRails
[03:30:23] Technodrome: has joined #RubyOnRails
[03:36:45] Applitect: If I'm looping through an array of ActiveRecord objects, what would be the easiest way to add a temp attribute to each record? This is in Rails 4.2.0 if that helps.
[03:48:40] jackhum: has joined #RubyOnRails
[04:12:01] DTZUZO: has joined #RubyOnRails
[04:46:35] bitch: has joined #RubyOnRails
[04:54:29] jackhum: has joined #RubyOnRails
[05:00:27] reber: has joined #RubyOnRails
[05:03:53] v01d4lph4: has joined #RubyOnRails
[05:07:28] jottr: has joined #RubyOnRails
[05:12:20] srinidhi: has joined #RubyOnRails
[05:24:28] apeiros_: has joined #RubyOnRails
[05:59:45] timdotrb: has joined #RubyOnRails
[06:09:30] roshanavand: has joined #RubyOnRails
[06:39:33] jackhum: has joined #RubyOnRails
[06:51:11] dionysus69: has joined #RubyOnRails
[06:54:44] ellcs: has joined #RubyOnRails
[06:59:41] apeiros_: has joined #RubyOnRails
[07:01:01] jackhum: has joined #RubyOnRails
[07:08:12] jottr: has joined #RubyOnRails
[07:11:35] egray: has joined #RubyOnRails
[07:15:50] lomex: has joined #RubyOnRails
[07:22:25] anikras: has joined #RubyOnRails
[07:38:05] srinidhi: has joined #RubyOnRails
[07:41:32] schneider: has joined #RubyOnRails
[08:00:02] apeiros__: has joined #RubyOnRails
[08:00:24] mikecmpbll: has joined #RubyOnRails
[08:06:36] jottr: has joined #RubyOnRails
[08:10:53] Guest58115: has joined #RubyOnRails
[08:11:43] srinidhi: has joined #RubyOnRails
[08:14:31] ams__: has joined #RubyOnRails
[08:22:44] noob_on_rails: has joined #RubyOnRails
[08:24:02] glasz: has joined #RubyOnRails
[08:30:31] schneider: has joined #RubyOnRails
[08:30:37] srinidhi: has joined #RubyOnRails
[08:30:52] apeiros_: has joined #RubyOnRails
[08:47:56] uks: has joined #RubyOnRails
[08:49:18] brotspinne: has joined #RubyOnRails
[08:50:18] brotspinne: hi everyone. do you know if there is a way to use activestorage with rails 4?
[08:59:04] tbuehlmann: brotspinne: not without some headache, as it requires actionpack and activerecord 5.2
[09:23:31] catbusters: has joined #RubyOnRails
[09:38:26] kotepillar_: has joined #RubyOnRails
[09:38:34] gregf_: has joined #RubyOnRails
[09:39:21] kotepillar_: my database use column named “hello_id”, but now I want to use “id” as it’s name, but I dont’ want to alter the table
[09:41:16] Ergo: has joined #RubyOnRails
[09:59:20] anubhav996: has joined #RubyOnRails
[10:13:35] srinidhi: has joined #RubyOnRails
[10:15:13] dionysus69: isn't it weird that sidekiq doesn't come with the ability to view failed jobs? resque had such functionality :S
[10:21:04] morfin60: has joined #RubyOnRails
[10:22:16] morfin60: seems like blob uploads would fixed only in Rails 6.0? I mean they're uploaded ONLY if model were valid not always(to avoid orphans)
[10:22:54] tbuehlmann: that's a rails 6 feature, iirc
[10:23:38] morfin60: i had to workaround in 5.2 to remove orphans
[10:36:16] beholders_eye: has joined #RubyOnRails
[10:51:01] jackhum: has joined #RubyOnRails
[10:51:43] lankanmon: has joined #RubyOnRails
[10:55:55] morfin60: other stuff works fine for me
[11:07:10] Puffball: has joined #RubyOnRails
[11:13:57] lomex: has joined #RubyOnRails
[11:14:09] armyriad: has joined #RubyOnRails
[11:14:55] timdotrb: has joined #RubyOnRails
[11:15:46] wojnar: has joined #RubyOnRails
[11:15:55] Ropeney: has joined #RubyOnRails
[11:17:44] kapil___: has joined #RubyOnRails
[11:19:49] srinidhi: has joined #RubyOnRails
[11:20:45] Croata: has joined #RubyOnRails
[11:24:00] beholders_eye: has joined #RubyOnRails
[11:42:18] beholders_eye: has joined #RubyOnRails
[11:54:15] lomex: has joined #RubyOnRails
[12:09:27] lomex: has joined #RubyOnRails
[12:14:10] kotepillar_: my database use column named “hello_id”, but now I want to use “id” as it’s name, but I dont’ want to alter the table
[12:17:50] tbuehlmann: kotepillar_: "id" is the conventional name for the primary key, is this your primary key?
[12:19:16] mello: has joined #RubyOnRails
[12:21:07] tbuehlmann: you can rename columns using rename_column: https://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/SchemaStatements.html#method-i-rename_column
[12:21:15] tbuehlmann: this will change the table
[12:23:44] kotepillar_: I don’t want to alter the table, just let model level column name map “a” -> “b”
[12:24:44] tbuehlmann: on an instance level this could just be: `def id; hello_id; end`
[12:25:13] tbuehlmann: I still assume this just being an example, you shouldn't override the id method
[12:31:04] ariedler: has joined #RubyOnRails
[12:32:21] kotepillar_: has joined #RubyOnRails
[12:32:42] lomex: has joined #RubyOnRails
[12:35:45] Sylario: has joined #RubyOnRails
[12:36:27] lomex: has joined #RubyOnRails
[12:45:09] beholders_eye: has joined #RubyOnRails
[12:46:31] lomex: has joined #RubyOnRails
[12:48:42] dblessing: has joined #RubyOnRails
[12:50:14] apeiros_: has joined #RubyOnRails
[13:24:08] knight33: has joined #RubyOnRails
[13:27:40] kotepillar_: has joined #RubyOnRails
[13:40:08] sevenseacat: has joined #RubyOnRails
[13:49:57] mikecmpbll: has joined #RubyOnRails
[13:51:22] Saukk: has joined #RubyOnRails
[13:53:15] kyrylo: has joined #RubyOnRails
[14:15:46] kyrylo: Hey guys. Is there a way to map this to the corresponding route? {:controller=>"things/1/foo", :action=>"show"}}
[14:16:04] kyrylo: I want to get something like `things/:id/foo`
[14:16:53] jjman: has left #RubyOnRails: ("WeeChat 1.6")
[14:22:01] kyrylo_: has joined #RubyOnRails
[14:26:14] havenwood: Rails.application.routes.routes.find { |route| route.defaults == {controller: 'articles', action: 'edit'} }.path.spec.to_s #=> "/articles/:id/edit(.:format)"
[14:27:29] duderonomy: has joined #RubyOnRails
[14:28:13] kotepillar_: has joined #RubyOnRails
[14:38:51] kotepillar_: has joined #RubyOnRails
[14:59:54] kyrylo: has joined #RubyOnRails
[15:03:59] Dbugger: has joined #RubyOnRails
[15:08:03] sariyar: has joined #RubyOnRails
[15:08:34] kapil___: has joined #RubyOnRails
[15:13:29] kyrylo: has left #RubyOnRails: ("Textual IRC Client: www.textualapp.com")
[15:19:28] GodFather: has joined #RubyOnRails
[15:22:41] magellanicloud: has joined #RubyOnRails
[15:23:58] v01d4lph4: has joined #RubyOnRails
[15:24:13] desperek: has joined #RubyOnRails
[15:27:56] apeiros_: has joined #RubyOnRails
[15:34:31] orbyt_: has joined #RubyOnRails
[15:50:57] knight33: has joined #RubyOnRails
[15:54:35] cagomez: has joined #RubyOnRails
[15:56:24] eckhardt: has joined #RubyOnRails
[15:56:49] orbyt_: has joined #RubyOnRails
[15:58:47] Dimik: has joined #RubyOnRails
[16:04:35] dblessing: has joined #RubyOnRails
[16:11:34] rootsudo: has joined #RubyOnRails
[16:12:57] dviola: has joined #RubyOnRails
[16:13:57] srinidhi: has joined #RubyOnRails
[16:15:28] neomindryan: has joined #RubyOnRails
[16:24:25] tdy: has joined #RubyOnRails
[16:31:06] brandoncc: has joined #RubyOnRails
[16:33:36] Lloyd: has left #RubyOnRails: ()
[16:36:45] mikecmpbll: has joined #RubyOnRails
[16:38:24] GreekFreak: has joined #RubyOnRails
[16:40:03] v01d4lph4: has joined #RubyOnRails
[16:40:39] GreekFreak: I am new to ActiveStorage and today it's been doing something funny (not sure what I might've changed). My storage.yml file directs my attachment to "Rails.root.join("public/storage")" yet when I do url_for(user.profile_pic) it returns the URL that starts with "/rails/active_storage/blobs/eyJfcmF...." I can't seem to find any help online for this either.
[16:40:45] GreekFreak: Any help would be appreciated
[16:47:09] GreekFreak: It seems to be saving to the correct location, but it won't retrieve it correctly
[16:49:39] knight33: has joined #RubyOnRails
[16:52:59] Cork: has joined #RubyOnRails
[16:59:28] v01d4lph4: has joined #RubyOnRails
[16:59:44] orbyt_: has joined #RubyOnRails
[17:02:12] dblessing: has joined #RubyOnRails
[17:08:50] chrisarcand: has joined #RubyOnRails
[17:19:38] mikecmpbll: has joined #RubyOnRails
[17:34:18] defsdoor: has joined #RubyOnRails
[17:36:20] jackhum: has joined #RubyOnRails
[17:40:33] choke: has joined #RubyOnRails
[17:42:32] mattwc: has joined #RubyOnRails
[17:47:09] work_: has joined #RubyOnRails
[17:47:21] jottr: has joined #RubyOnRails
[17:53:01] eckhardt: has joined #RubyOnRails
[17:53:04] knight33: has joined #RubyOnRails
[17:57:46] prettybTech: has joined #RubyOnRails
[17:58:11] unreal: has joined #RubyOnRails
[18:02:23] ShekharReddy: has joined #RubyOnRails
[18:16:50] dopie: has joined #RubyOnRails
[18:16:57] dopie: I was wondering what you think of this... I have a Post Model... should I have an adjoining Meta model that hasll the seo stuff on it like meta_description, meta_keywords, or should I just put them on the same modell?
[18:17:07] dopie: like post.meta_description or post.meta.description
[18:20:16] tdy: has joined #RubyOnRails
[18:33:26] Guest58115: has joined #RubyOnRails
[18:39:02] Linuus: has joined #RubyOnRails
[18:43:11] duderonomy: has joined #RubyOnRails
[18:43:26] Guest58115: has joined #RubyOnRails
[18:43:28] jottr: has joined #RubyOnRails
[18:48:42] Puffball: has joined #RubyOnRails
[18:48:44] magellanicloud: has joined #RubyOnRails
[18:49:34] duderonomy: has joined #RubyOnRails
[18:49:41] beholders_eye: has joined #RubyOnRails
[18:51:24] choke: has joined #RubyOnRails
[18:52:08] duderonomy: has joined #RubyOnRails
[19:03:05] skryking: has joined #RubyOnRails
[19:03:19] Guest58115: has joined #RubyOnRails
[19:07:24] fourcolors: has joined #RubyOnRails
[19:15:26] filipechagas: has joined #RubyOnRails
[19:23:37] sameerynho: has joined #RubyOnRails
[19:32:12] choke: has joined #RubyOnRails
[19:40:24] duderonomy: has joined #RubyOnRails
[19:44:13] rootsudo: has joined #RubyOnRails
[20:30:21] Linuus: has joined #RubyOnRails
[20:36:17] prettybTech: has joined #RubyOnRails
[20:48:06] tdy: has joined #RubyOnRails
[20:48:53] Linuus: has joined #RubyOnRails
[20:59:22] cosmicfires: has joined #RubyOnRails
[20:59:59] defsdoor: has joined #RubyOnRails
[21:00:05] cosmicfires: I get this error when I start apache /usr/local/rvm/gems/ruby-2.3.3/gems/passenger-5.3.4 is not secure: it can be modified by user david
[21:06:01] apeiros_: has joined #RubyOnRails
[21:08:37] ellcs: has joined #RubyOnRails
[21:24:34] orbyt_: has joined #RubyOnRails
[21:25:56] armyriad: has joined #RubyOnRails
[21:29:13] choke: has joined #RubyOnRails
[21:31:03] Linuus: has joined #RubyOnRails
[21:31:25] LiftLeft2: has joined #RubyOnRails
[21:33:01] LiftLeft3: has joined #RubyOnRails
[21:56:29] dionysus69: has joined #RubyOnRails
[22:05:11] beowuff: has joined #RubyOnRails
[22:08:06] beowuff: has joined #RubyOnRails
[22:09:11] rodd: noob q: Is there a way to retrieve the current host / request.host outside a controller? i.e. in a service/custom mailer ?
[22:12:46] baweaver: Passing it in from a controller mostly.
[22:13:12] baweaver: I'd just ferry the data to the service or mailer from there to keep separation of concerns.
[22:14:35] rodd: found a hacky way, will have to do for now
[22:15:07] rodd: a before_action in applicationController, then set settings on ActionMailer::Base.default_url_options based on request
[22:15:18] rodd: k maybe ill just pass from controller
[22:24:57] grvgr: has joined #RubyOnRails
[22:31:56] orbyt_: has joined #RubyOnRails
[22:35:29] choke: has joined #RubyOnRails
[22:56:42] egray: has joined #RubyOnRails
[22:56:46] Linuus: has joined #RubyOnRails
[23:03:17] armyriad: has joined #RubyOnRails
[23:13:53] lomex: has joined #RubyOnRails
[23:20:39] choke: has joined #RubyOnRails
[23:25:50] SteenJobs: has joined #RubyOnRails
[23:39:09] chris349: has joined #RubyOnRails
[23:44:00] orbyt_: has joined #RubyOnRails
[23:52:41] brkkyk: has joined #RubyOnRails
[23:52:44] cagomez: has joined #RubyOnRails
[23:53:07] Linuus: has joined #RubyOnRails
[23:56:51] brkkyk: is there anybody out there