« Back to channel list

#RubyOnRails - 21 March 2019

« Back 1 day Forward 1 day »
[00:01:27] orbyt_: has joined #RubyOnRails
[00:16:17] gheegh: has joined #RubyOnRails
[00:17:17] hnanon: has joined #RubyOnRails
[00:17:44] hnanon: Do I need to run app:update when upgrading from 5.2.2 to 5.2.2.1?
[00:39:57] ur5us: has joined #RubyOnRails
[00:42:19] havenwood: hnanon: nope
[00:42:39] hnanon: havenwood, Thanks.
[00:46:40] orbyt_: has joined #RubyOnRails
[01:04:48] ss942: has joined #RubyOnRails
[01:07:02] sevenseacat: has joined #RubyOnRails
[01:10:51] orbyt_: has joined #RubyOnRails
[01:26:29] fcser_: has joined #RubyOnRails
[01:27:26] ss942: I have problem with .order() inside controller, when I add this query takes centuries. And I have no idea how to fix it.
[01:27:26] ss942: Project.first.documents.joins("LEFT JOIN custom_values AS cv ON custom_values.customized_id = documents.id AND custom_values.custom_field_id = 55").limit(5)
[01:27:26] ss942: Takes less than secounds, but centuries when I do:
[01:27:27] ss942: Project.first.documents.joins("LEFT JOIN custom_values AS cv ON custom_values.customized_id = documents.id AND custom_values.custom_field_id = 55").order(custom_values.value).limit(5)
[01:27:27] ss942: Any tips?
[02:18:50] sevenseacat: analyze the query, see why its taking so long
[02:19:13] sevenseacat: .analyze on the end
[02:23:59] hnanon: has joined #RubyOnRails
[02:54:08] mangold: has joined #RubyOnRails
[03:05:41] Saukk: has joined #RubyOnRails
[03:27:12] apparition: has joined #RubyOnRails
[03:52:21] tdy: has joined #RubyOnRails
[04:10:16] braincrash: has joined #RubyOnRails
[04:46:34] alexeev: has joined #RubyOnRails
[04:47:46] segy: has joined #RubyOnRails
[04:52:05] kvda: has joined #RubyOnRails
[04:53:26] kapil____: has joined #RubyOnRails
[05:31:35] dviola: has joined #RubyOnRails
[05:33:32] MrCrackPotBuilde: has joined #RubyOnRails
[05:37:07] kvda: has joined #RubyOnRails
[05:56:29] conta: has joined #RubyOnRails
[06:22:38] srinidhi: has joined #RubyOnRails
[06:37:10] za1b1tsu: has joined #RubyOnRails
[06:42:47] reber: has joined #RubyOnRails
[06:46:21] defsdoor_: has joined #RubyOnRails
[07:03:45] dionysus69: which is normally a convention, I have a spec with parent and 2 children, should I test all 3 in parent spec or should I maximize division between the specs?
[07:25:51] Dbugger: has joined #RubyOnRails
[07:53:25] mikecmpbll: has joined #RubyOnRails
[08:00:31] guyzmo: ss942 - that's because when you do limit(5) the query takes only the needed time to take 5 elements out of the database, without looking further
[08:01:50] guyzmo: ss942 - when you add `order(...)` (same thing goes for `distinct`), the db needs to crawl through the whole table to compare all the values, to display them in order
[08:22:19] lxsameer: has joined #RubyOnRails
[08:29:54] neozor: has joined #RubyOnRails
[08:37:41] albipri: has joined #RubyOnRails
[08:37:53] albipri: Hello everybody,
[08:37:53] albipri: I'm having issue in installing rack-mini-profiler in my Rails app in my local development environment.
[08:37:54] albipri: I'm using Rails 5.1.4 with puma on ruby 2.4
[08:37:54] albipri: The issue is that I cannot see the badge.
[08:37:54] albipri: There are no javascript errors.
[08:37:54] albipri: Also passing `?pp=enable` to the url, won't fix it.
[08:37:55] albipri: I also tried to add `require: false` to the gemfile entry for rack-mini-profiler
[08:37:55] albipri: And create an initializer with:
[08:37:56] albipri: Rack::MiniProfilerRails.initialize!(Rails.application)
[08:37:56] ChanServ: +q *!*@host193-122-static.26-87-b.business.telecomitalia.it
[08:49:24] albipri: has left #RubyOnRails: ()
[08:56:54] beanHolez: has joined #RubyOnRails
[08:57:59] Ergo: has joined #RubyOnRails
[09:03:12] mikecmpbll: has joined #RubyOnRails
[09:36:43] deathwishdave: has joined #RubyOnRails
[09:57:32] alexeev: has joined #RubyOnRails
[09:58:34] kvda: has joined #RubyOnRails
[10:04:33] deathwishdave: has joined #RubyOnRails
[10:32:12] lankanmon: has joined #RubyOnRails
[10:35:18] nakuku: has joined #RubyOnRails
[11:04:34] segy: has joined #RubyOnRails
[11:05:40] alexeev_: has joined #RubyOnRails
[11:19:41] mangold: has joined #RubyOnRails
[11:40:28] lupine: has joined #RubyOnRails
[11:45:14] alexeev: has joined #RubyOnRails
[11:46:39] reber: has joined #RubyOnRails
[12:07:06] garyserj: has joined #RubyOnRails
[12:07:34] garyserj: where is rails located in mac osx? (i'm having trouble installing it so perhaps somebody can do which rails and let me know the path? thanks)
[12:25:21] alexeev: has joined #RubyOnRails
[12:49:56] Cork: is it possible to get activerecord to use stable names for dynamicly joined tables?
[12:56:28] conta1: has joined #RubyOnRails
[12:58:20] hnanon: has joined #RubyOnRails
[12:59:14] deathwishdave: has joined #RubyOnRails
[12:59:57] ams__: has joined #RubyOnRails
[13:03:01] za1b1tsu: has joined #RubyOnRails
[13:05:41] wolfravenous: has joined #RubyOnRails
[13:16:27] terabytes: Can anyone help me with a spec in rails 3? https://pastebin.com/xMqhtZiK
[13:23:31] hnanon: has joined #RubyOnRails
[13:54:48] hnanon: has joined #RubyOnRails
[14:09:21] segy: has joined #RubyOnRails
[14:13:27] mangold: has joined #RubyOnRails
[14:16:54] Dbugger: has joined #RubyOnRails
[14:26:39] alexeev: has joined #RubyOnRails
[14:43:06] hnanon_: has joined #RubyOnRails
[14:43:30] yoshie902a: has joined #RubyOnRails
[14:44:10] yoshie902a: If anyone is really talented and take a shot at a harder join, please let help with this.. https://stackoverflow.com/questions/55272545/joins-one-way-but-not-the-other
[14:54:29] tdy: has joined #RubyOnRails
[14:55:48] pd09041999: has joined #RubyOnRails
[14:59:22] beanHolez: has joined #RubyOnRails
[15:09:14] bogn: has joined #RubyOnRails
[15:20:34] hnanon_: has joined #RubyOnRails
[15:27:33] hightower2: has joined #RubyOnRails
[15:28:20] alexeev: yoshie902a: could you share your db schema?
[15:28:47] rascencio: has joined #RubyOnRails
[15:29:56] yoshie902a: alexeev: which part is helpful? the tables a rather long.
[15:30:18] yoshie902a: alexeev: I did show the models, which should be enough, but glad to share more
[15:31:48] alexeev: yoshie902a: in my opinion the bug could be in links between tables
[15:32:03] alexeev: foreign keys, you know
[15:32:28] yoshie902a: alexeev: it works one way, but not the other, I will share
[15:32:53] hnanon: has joined #RubyOnRails
[15:33:02] alexeev: yoshie902a: share, i would try to think
[15:36:25] yoshie902a: alexeev: just need to clean the tables up, but will post soon
[15:39:58] orbyt_: has joined #RubyOnRails
[15:42:14] alexeev: has joined #RubyOnRails
[15:42:44] alexeev_: has joined #RubyOnRails
[15:43:11] gambl0r3: has joined #RubyOnRails
[15:44:05] yoshie902a: alexeev: just posted
[15:46:33] hnanon: has joined #RubyOnRails
[15:58:23] yoshie902a: has joined #RubyOnRails
[15:58:36] yoshie902a: alexeev_: noticed my computer disconnect, sorry, did I miss anything?
[16:23:33] skryking: has joined #RubyOnRails
[16:30:33] pd09041999: has joined #RubyOnRails
[16:32:19] beanHolez: has joined #RubyOnRails
[16:42:41] orbyt_: has joined #RubyOnRails
[16:57:14] neozor: has joined #RubyOnRails
[17:00:46] pokalyis: has joined #RubyOnRails
[17:05:35] KeyJoo: has joined #RubyOnRails
[17:10:09] pd09041999: has joined #RubyOnRails
[17:12:05] orbyt_: has joined #RubyOnRails
[17:24:37] duderonomy: has joined #RubyOnRails
[17:31:17] Saukk: has joined #RubyOnRails
[17:37:47] conta1: has joined #RubyOnRails
[17:45:10] orbyt_: has joined #RubyOnRails
[17:58:25] Dbugger: Was it possible to create with a contructor not only the attributes of a model, but also of its references?
[17:58:48] yoshie902a: has joined #RubyOnRails
[17:59:58] alexeev: has joined #RubyOnRails
[18:01:13] KeyJoo: has joined #RubyOnRails
[18:04:36] vovs03: has joined #RubyOnRails
[18:05:07] s00pcan: has joined #RubyOnRails
[18:11:17] mikecmpbll: has joined #RubyOnRails
[18:14:49] s00pcan: has joined #RubyOnRails
[18:45:03] reber: has joined #RubyOnRails
[18:45:46] agent_white: has joined #RubyOnRails
[18:58:53] s00pcan: has joined #RubyOnRails
[19:05:01] tdy: has joined #RubyOnRails
[19:07:30] xco: has joined #RubyOnRails
[19:07:42] yoshie902a: has left #RubyOnRails: ()
[19:14:14] neozor: has joined #RubyOnRails
[19:15:52] hnanon: has joined #RubyOnRails
[19:27:28] rascencio: has joined #RubyOnRails
[19:32:38] defsdoor_: has joined #RubyOnRails
[19:57:24] krawchyk: has joined #RubyOnRails
[20:11:29] srruby: has joined #RubyOnRails
[20:13:55] srruby: In a controller index method, I have code like: CustomerMachine.joins([:customer,:machine]).order('customers.name,machines.name')
[20:14:30] srruby: Should I refactor that into a method on the model class?
[20:36:17] ur5us: has joined #RubyOnRails
[20:49:57] xco: has joined #RubyOnRails
[20:56:32] beholders_eye: has joined #RubyOnRails
[21:11:22] hnanon: has joined #RubyOnRails
[21:15:45] uks: has joined #RubyOnRails
[21:15:45] uksio: has joined #RubyOnRails
[21:27:35] paul0: has joined #RubyOnRails
[21:30:23] hnanon: has joined #RubyOnRails
[22:06:58] hays: has joined #RubyOnRails
[22:32:31] gambl0r3: has joined #RubyOnRails
[22:32:51] rascencio: has joined #RubyOnRails
[22:42:34] xco: has joined #RubyOnRails
[22:51:07] ellcs: has joined #RubyOnRails
[22:57:37] ams__: has joined #RubyOnRails
[22:59:32] ericboehs: has joined #RubyOnRails
[23:14:33] srruby: has joined #RubyOnRails
[23:19:57] jottr: has joined #RubyOnRails
[23:28:52] xco: has joined #RubyOnRails
[23:35:45] jottr: has joined #RubyOnRails
[23:46:48] rascencio: has joined #RubyOnRails
[23:51:42] jottr: has joined #RubyOnRails