« Back to channel list

#RubyOnRails - 01 July 2017

« Back 1 day Forward 1 day »
[00:02:07] quazimodo: has joined #RubyOnRails
[00:04:48] ayonkhan: has joined #RubyOnRails
[00:12:49] jottr_: has joined #RubyOnRails
[00:23:11] quirkycoders: has joined #RubyOnRails
[00:33:09] jhfisc: has joined #RubyOnRails
[00:33:27] quazimodo: has joined #RubyOnRails
[00:37:36] arBmind: has joined #RubyOnRails
[00:39:40] jhfisc: has joined #RubyOnRails
[00:45:40] jhfisc: has joined #RubyOnRails
[00:48:37] jhfisc: has joined #RubyOnRails
[00:49:49] bed1: has joined #RubyOnRails
[00:50:36] arBmind: has joined #RubyOnRails
[00:53:40] jhfisc: has joined #RubyOnRails
[00:57:31] ascarter: has joined #RubyOnRails
[00:59:10] quirkycoders: has joined #RubyOnRails
[01:04:41] bed7: has joined #RubyOnRails
[01:07:48] gusrub: has joined #RubyOnRails
[01:13:33] jottr_: has joined #RubyOnRails
[01:13:35] FastJack: has joined #RubyOnRails
[01:21:15] FastJack: has joined #RubyOnRails
[01:22:23] delgiudices: has joined #RubyOnRails
[01:28:05] coetry: has joined #RubyOnRails
[01:29:41] jhfisc: has joined #RubyOnRails
[01:35:43] jhfisc: has joined #RubyOnRails
[01:41:40] jhfisc: has joined #RubyOnRails
[01:46:22] AckZ: has joined #RubyOnRails
[01:46:54] FastJack: has joined #RubyOnRails
[01:47:17] s2013: has joined #RubyOnRails
[01:51:47] jhfisc: has joined #RubyOnRails
[01:55:43] rafaeldelucena: has joined #RubyOnRails
[02:02:39] ascarter: has joined #RubyOnRails
[02:05:10] gusrub: has joined #RubyOnRails
[02:05:39] s2013: has joined #RubyOnRails
[02:11:35] jhfisc: has joined #RubyOnRails
[02:14:33] jottr_: has joined #RubyOnRails
[02:17:40] irishfromua: has joined #RubyOnRails
[02:18:27] jhfisc: has joined #RubyOnRails
[02:22:51] Jameser: has joined #RubyOnRails
[02:24:19] Chernobuk: has joined #RubyOnRails
[02:24:24] jhfisc: has joined #RubyOnRails
[02:27:55] truenito: has joined #RubyOnRails
[02:38:44] kies: has joined #RubyOnRails
[02:39:40] jhfisc: has joined #RubyOnRails
[02:40:44] patarr: has joined #RubyOnRails
[02:45:40] jhfisc: has joined #RubyOnRails
[02:46:38] robnester: has joined #RubyOnRails
[02:48:02] knight33: has joined #RubyOnRails
[02:48:22] jhfisc: has joined #RubyOnRails
[02:49:15] juddey: has joined #RubyOnRails
[02:52:12] juddey: has left #RubyOnRails: ()
[02:58:49] conta: has joined #RubyOnRails
[02:59:41] jhfisc: has joined #RubyOnRails
[03:08:04] ascarter: has joined #RubyOnRails
[03:10:24] robnester: has joined #RubyOnRails
[03:12:24] jhfisc: has joined #RubyOnRails
[03:12:48] wethu: has joined #RubyOnRails
[03:13:47] s2013: has joined #RubyOnRails
[03:15:01] robnester: has joined #RubyOnRails
[03:15:18] jottr_: has joined #RubyOnRails
[03:18:23] jhfisc: has joined #RubyOnRails
[03:23:04] robnester: has joined #RubyOnRails
[03:30:51] jhfisc: has joined #RubyOnRails
[03:33:55] mikecmpbll: has joined #RubyOnRails
[03:34:08] delgiudices: has joined #RubyOnRails
[03:34:26] robnester: has joined #RubyOnRails
[03:36:12] jhfisc: has joined #RubyOnRails
[03:39:30] robnester: has joined #RubyOnRails
[03:39:57] swemoney: has joined #RubyOnRails
[03:40:04] knight33: has joined #RubyOnRails
[03:42:55] swemoney: I just ran into a bug where Person.items has some duplicates in my database. (i.e. I've called Person.items << some_item more than once) .. This is a has and belongs to many relationship. If I do Person.items.uniq or Items.people.uniq, it'll return the list correctly. Is there an easy way to clean up these duplicates?
[03:43:34] swemoney: from the database, I mean.
[03:44:42] ascarter: has joined #RubyOnRails
[03:48:55] wethu: has joined #RubyOnRails
[03:49:39] jhfisc: has joined #RubyOnRails
[03:55:33] jhfisc: has joined #RubyOnRails
[03:56:32] knight33: has joined #RubyOnRails
[03:58:47] quirkycoders: has joined #RubyOnRails
[04:01:56] fryguy: https://stackoverflow.com/questions/2630440/how-to-delete-duplicates-on-a-mysql-table
[04:09:29] swemoney: Think that would work on postgres too?
[04:16:02] jottr_: has joined #RubyOnRails
[04:23:08] FastJack: has joined #RubyOnRails
[04:25:52] jhfisc: has joined #RubyOnRails
[04:32:19] fryguy: similar solutions for postgres
[04:35:12] wethu: has joined #RubyOnRails
[04:40:27] s2013: has joined #RubyOnRails
[04:50:41] ahrs: has joined #RubyOnRails
[04:51:54] s2013: has joined #RubyOnRails
[05:00:20] jhfisc: has joined #RubyOnRails
[05:00:33] biox: has joined #RubyOnRails
[05:09:04] marr: has joined #RubyOnRails
[05:10:35] quirkycoders: has joined #RubyOnRails
[05:15:42] jhfisc: has joined #RubyOnRails
[05:17:38] jottr_: has joined #RubyOnRails
[05:18:14] choke_: has joined #RubyOnRails
[05:23:36] Technodrome: has joined #RubyOnRails
[05:26:15] jhfisc: has joined #RubyOnRails
[05:35:44] jhfisc: has joined #RubyOnRails
[05:36:15] mikecmpbll: has joined #RubyOnRails
[05:46:50] quirkycoders: has joined #RubyOnRails
[05:57:36] timdotrb: has joined #RubyOnRails
[06:07:22] jhfisc: has joined #RubyOnRails
[06:10:38] ur5us: has joined #RubyOnRails
[06:16:04] jhfisc: has joined #RubyOnRails
[06:18:21] jottr_: has joined #RubyOnRails
[06:19:16] jhfisc: has joined #RubyOnRails
[06:22:25] quirkycoders: has joined #RubyOnRails
[06:26:24] jhfisc: has joined #RubyOnRails
[06:27:51] itsgokul: has joined #RubyOnRails
[06:28:51] itsgokul: how can i known if content inside :X is empty/not
[06:32:48] itsgokul: when i do f.select :id its saving but not staying selected in edit
[06:39:40] jhfisc: has joined #RubyOnRails
[06:46:44] jhfisc: has joined #RubyOnRails
[06:51:59] jhfisc: has joined #RubyOnRails
[06:55:41] wethu: has joined #RubyOnRails
[07:13:01] s2013: has joined #RubyOnRails
[07:19:35] jottr_: has joined #RubyOnRails
[07:23:24] jhfisc: has joined #RubyOnRails
[07:30:44] jhfisc: has joined #RubyOnRails
[07:42:21] jhfisc: has joined #RubyOnRails
[07:44:28] wethu: has joined #RubyOnRails
[07:48:15] jhfisc: has joined #RubyOnRails
[07:51:21] jhfisc: has joined #RubyOnRails
[08:02:32] jhfisc: has joined #RubyOnRails
[08:08:37] patarr: has joined #RubyOnRails
[08:09:06] marr: has joined #RubyOnRails
[08:10:38] irishfromua: has left #RubyOnRails: ()
[08:11:41] jhfisc: has joined #RubyOnRails
[08:15:40] conta: has joined #RubyOnRails
[08:17:42] jhfisc: has joined #RubyOnRails
[08:21:33] jottr_: has joined #RubyOnRails
[08:25:17] Technodrome: has joined #RubyOnRails
[08:25:33] xco: has joined #RubyOnRails
[08:25:46] jhfisc: has joined #RubyOnRails
[08:28:49] timdotrb: So this is a pretty strange issue
[08:29:15] timdotrb: I have a remote form. The server is sending the correct response based on the data sent, but the ajax is always executing ajax:error
[08:29:54] timdotrb: Any thoughts on that one?
[08:33:16] jhfisc: has joined #RubyOnRails
[08:33:30] rietta_: has joined #RubyOnRails
[08:36:10] tbuehlmann: timdotrb: doesn't ring a bell. do you have an app for reproduction?
[08:37:07] dionysus69: has joined #RubyOnRails
[08:37:11] timdotrb: tbuehlmann: I do not. I could gist my code
[08:50:44] xco: hi. i have a test_helper.rb with this #process method https://gist.github.com/siaw23/4d1587046d5dbb7fae286458f42b2f90#file-test_helper-rb-L63. i’m on Rails 5 but for some reason the #process method is implementing this: http://api.rubyonrails.org/v4.2/classes/ActionController/TestCase/Behavior.html#method-i-process which is from Rails 4 (hence giving me lots of deprecation warnings). How do I make my Rails 5 use this #process me
[08:50:44] xco: instead? https://github.com/rails/rails/blob/5-0-4/actionpack/lib/action_controller/test_case.rb#L469 maybe I am using the wrong class in my test_helper.rb?
[08:54:35] Axsuul: has joined #RubyOnRails
[08:59:23] jhfisc: has joined #RubyOnRails
[09:00:19] tbuehlmann: xco: why do you use process and not just get/post/whatnot?
[09:02:24] xco: i haven’t thought about that yet. but i don’t understand why a Rails 5 app is running a method from Rails 4.
[09:02:34] xco: i’m looking for an answer to that
[09:09:30] tbuehlmann: why do you think it's the method from rails 4?
[09:13:41] xco: tbuehlmann: i think so because the deprecation warnings it’s showing me have been taken care of in Rails 5 and not in Rails 4
[09:13:56] xco: i could be wrong though
[09:14:51] tbuehlmann: what's the warning?
[09:18:19] jhfisc: has joined #RubyOnRails
[09:18:26] xco: tbuehlmann: warning looks like https://gist.github.com/siaw23/b0034d051e5dbaf0468207a0e7e58a89#file-msg-rb
[09:18:36] xco: on tests like https://gist.github.com/siaw23/b0034d051e5dbaf0468207a0e7e58a89#file-gistfile1-txt
[09:19:15] xco: but if i add params: {} on line https://gist.github.com/siaw23/b0034d051e5dbaf0468207a0e7e58a89#file-gistfile1-txt-L27 i get “Not route matches action controller…”
[09:20:11] tbuehlmann: wiat version of rails do you use?
[09:20:30] tbuehlmann: and where does this oauth method come from?
[09:22:17] jottr_: has joined #RubyOnRails
[09:24:49] conta: has joined #RubyOnRails
[09:26:09] xco: tbuehlmann: i’m using Rails 5.0.4, the oauth is a method defined in my test_helper.rb
[09:27:22] tbuehlmann: what does it do?
[09:27:43] jhfisc: has joined #RubyOnRails
[09:29:33] tbuehlmann: also, do you see there's a deprecation warning in 5.0.4? https://github.com/rails/rails/blob/33db42168425866b714203e35a3a36693983b3f9/actionpack/lib/action_controller/test_case.rb#L484
[09:31:00] xco: oauth authorizes a user to use my api. yes i saw that. but even though routes are defined, when i add the kwargs like say params: { obj: { something: ‘hello’} } i get undefined routes error
[09:34:46] rgr: has joined #RubyOnRails
[09:35:33] dionysus69: has joined #RubyOnRails
[09:37:48] tbuehlmann: xco: you are requesting an action without a route then?
[09:39:18] jhfisc: has joined #RubyOnRails
[09:40:04] xco: those routes were seen in Rails 4
[09:40:10] xco: maybe something might have changes in R5?
[09:40:20] xco: changed*
[09:47:46] tbuehlmann: what's the exact error?
[09:50:32] xco: let me run again, one sec
[09:51:55] wethu: has joined #RubyOnRails
[09:54:02] xco: tbuehlmann: so a test example with an error example https://gist.github.com/siaw23/d83d26a75b0d80e5279b0f7c3e68537a
[09:54:10] xco: AFTER adding params: {}
[09:55:59] tbuehlmann: can you gist the oauth method?
[09:58:13] xco: tbuehlmann: https://gist.github.com/siaw23/d83d26a75b0d80e5279b0f7c3e68537a#file-oauth-rb
[10:00:40] jhfisc: has joined #RubyOnRails
[10:01:59] Fernando-Basso: has joined #RubyOnRails
[10:06:57] tbuehlmann: "missing required keys: [:id]" - check whether or not that id is present
[10:09:31] patarr: has joined #RubyOnRails
[10:10:33] timdotrb: has joined #RubyOnRails
[10:15:59] itsgokul: how can i access name for id from view page
[10:16:14] tbuehlmann: itsgokul: I don't understand the question, can you elaborate?
[10:16:50] jhfisc: has joined #RubyOnRails
[10:17:28] itsgokul: i have this object school_details that has corporate_id when i do @school_details.corporate its not displaying the name
[10:18:20] xco: tbuehlmann: the id is present, let me update the gist
[10:19:17] itsgokul: corporates is the table name update works
[10:21:25] xco: tbuehlmann: https://gist.github.com/siaw23/d83d26a75b0d80e5279b0f7c3e68537a#file-image_request_controller-rb-L121 and on line https://gist.github.com/siaw23/d83d26a75b0d80e5279b0f7c3e68537a#file-image_request_controller-rb-L257
[10:21:42] xco: id is present
[10:22:46] jhfisc: has joined #RubyOnRails
[10:22:48] tbuehlmann: itsgokul: what happens when you do this in a rails console? also, can you show your code?
[10:23:40] jottr_: has joined #RubyOnRails
[10:26:32] wethu: has joined #RubyOnRails
[10:30:28] jhfisc: has joined #RubyOnRails
[10:38:34] arup_r: has joined #RubyOnRails
[10:39:52] itsgokul: why do i get error when value is nil for nil:NilClass
[10:42:20] jhfisc: has joined #RubyOnRails
[10:47:39] jhfisc: has joined #RubyOnRails
[10:49:56] jottr_: has joined #RubyOnRails
[10:53:40] jhfisc: has joined #RubyOnRails
[11:02:18] itsgokul: onchange for select not trigerring
[11:13:03] HoierM_: has joined #RubyOnRails
[11:17:00] gambl0re: has joined #RubyOnRails
[11:41:50] jhfisc: has joined #RubyOnRails
[11:47:39] giraffe: has joined #RubyOnRails
[11:47:54] jhfisc: has joined #RubyOnRails
[11:49:02] lxsameer: has joined #RubyOnRails
[11:58:03] xco: tbuehlmann: fixed
[12:00:54] ayonkhan_: has joined #RubyOnRails
[12:10:23] patarr: has joined #RubyOnRails
[12:15:47] ayonkhan: has joined #RubyOnRails
[12:34:43] Qchmqs__: has joined #RubyOnRails
[12:34:54] jhfisc: has joined #RubyOnRails
[12:39:38] jhfisc: has joined #RubyOnRails
[12:40:49] Technodrome: has joined #RubyOnRails
[12:45:43] jhfisc: has joined #RubyOnRails
[12:46:17] arBmind: has joined #RubyOnRails
[12:47:51] delgiudices: has joined #RubyOnRails
[12:52:03] jhfisc: has joined #RubyOnRails
[12:54:44] jhfisc: has joined #RubyOnRails
[12:57:21] jottr_: has joined #RubyOnRails
[13:01:43] jhfisc: has joined #RubyOnRails
[13:17:50] jhfisc: has joined #RubyOnRails
[13:17:56] qchmqs_: has joined #RubyOnRails
[13:21:49] quirkycoders: has joined #RubyOnRails
[13:23:42] jhfisc: has joined #RubyOnRails
[13:29:21] unreal: has joined #RubyOnRails
[13:30:09] jhfisc: has joined #RubyOnRails
[13:40:44] quirkycoders: has joined #RubyOnRails
[13:48:20] Jameser: has joined #RubyOnRails
[13:52:40] jhfisc: has joined #RubyOnRails
[13:55:22] jhfisc: has joined #RubyOnRails
[13:56:35] quirkycoders: has joined #RubyOnRails
[14:00:21] DLSteve: has joined #RubyOnRails
[14:00:22] delgiudices: has joined #RubyOnRails
[14:11:19] patarr: has joined #RubyOnRails
[14:12:22] srinidhi: has joined #RubyOnRails
[14:15:52] chouhoulis: has joined #RubyOnRails
[14:16:30] dionysus69: has joined #RubyOnRails
[14:17:43] ayonkhan: has joined #RubyOnRails
[14:20:59] quazimodo: has joined #RubyOnRails
[14:23:49] Guest41824: has joined #RubyOnRails
[14:25:09] jhfisc: has joined #RubyOnRails
[14:25:30] babykosh: has joined #RubyOnRails
[14:26:25] babykosh: has joined #RubyOnRails
[14:38:00] delgiudices: has joined #RubyOnRails
[14:38:39] jhfisc: has joined #RubyOnRails
[14:41:34] bratsche: has joined #RubyOnRails
[14:42:58] quirkycoders: has joined #RubyOnRails
[14:50:14] jhfisc: has joined #RubyOnRails
[14:54:18] mtkd: has joined #RubyOnRails
[14:55:21] jhfisc: has joined #RubyOnRails
[14:55:59] pLaTo0n: has joined #RubyOnRails
[14:56:09] delgiudices: has joined #RubyOnRails
[14:57:08] ayonkhan_: has joined #RubyOnRails
[14:59:17] delgiudices: has joined #RubyOnRails
[15:01:54] delgiudices: has joined #RubyOnRails
[15:02:40] [dmp]: has joined #RubyOnRails
[15:04:25] ayonkhan: has joined #RubyOnRails
[15:06:38] [dmp]: has joined #RubyOnRails
[15:09:12] patarr: has joined #RubyOnRails
[15:11:39] Fenhl: hello. I host a web service which won't start any more since I upgraded to Debian jessie. Error message during `bundle install` is as follows: rack-2.0.3 requires ruby version >= 2.2.2, which is incompatible with the current version, ruby 2.1.5p273
[15:12:22] Fenhl: `ruby --version` outputs “ruby 2.3.3p222 (2016-11-21) [x86_64-linux-gnu]”. Any ideas? I'm mostly unfamiliar with the toolchains involved here
[15:13:07] Fenhl: the code for the web service in question is at https://github.com/fenhl/lore-seeker
[15:14:30] jhfisc: has joined #RubyOnRails
[15:16:19] fryguy: Fenhl: how do you have ruby installed
[15:17:12] Fenhl: fryguy: through apt, if I remember correctly
[15:17:50] fryguy: where is the ruby executable located?
[15:21:48] Fenhl: fryguy: /usr/bin/ruby
[15:22:00] fryguy: and where is the location of bundle?
[15:22:10] Fenhl: in /usr/local/bin
[15:22:21] fryguy: that seems wrong
[15:22:27] fryguy: how did you install bundler?
[15:23:46] Fenhl: I want to say using gem, but it doesn't show up in `gem list --local` or `sudo gem list --local`
[15:24:15] fryguy: where is the location of gem?
[15:25:32] fryguy: i'd remove bundler, install it correctly, and move on from there. i'd look in /usr/local/bin to see if you maybe have another ruby installation in there that you forgot about. in addition, i'd strongly consider adding rbenv or chruby and have you own ruby installation instead of relying on the os provided one.
[15:26:25] Fenhl: installing it correctly meaning using apt, or gem?
[15:28:00] bratsche: has joined #RubyOnRails
[15:29:24] quirkycoders: has joined #RubyOnRails
[15:30:34] ayonkhan: has joined #RubyOnRails
[15:31:11] Fenhl: okay, I don't have an additional ruby install in /usr/local/bin at least. Also I meant stretch earlier, not jessie (oops)
[15:34:34] Fenhl: reinstalling bundler fixed it, thanks for the help fryguy
[15:34:44] cpruitt: has joined #RubyOnRails
[15:35:46] arBmind: has joined #RubyOnRails
[15:39:59] kapil___: has joined #RubyOnRails
[15:42:11] Technodrome: has joined #RubyOnRails
[15:43:15] conta2: has joined #RubyOnRails
[15:44:01] jhfisc: has joined #RubyOnRails
[15:44:52] quirkycoders: has joined #RubyOnRails
[15:47:03] pLaTo0n: has joined #RubyOnRails
[15:55:30] zacts: has joined #RubyOnRails
[16:04:52] Aherin: has joined #RubyOnRails
[16:07:16] tercenya: has joined #RubyOnRails
[16:08:48] jottr_: has joined #RubyOnRails
[16:15:07] jhfisc: has joined #RubyOnRails
[16:15:49] quirkycoders: has joined #RubyOnRails
[16:26:52] jhfisc: has joined #RubyOnRails
[16:27:25] xco: has joined #RubyOnRails
[16:30:08] zacts: has joined #RubyOnRails
[16:37:40] jhfisc: has joined #RubyOnRails
[16:38:16] quirkycoders: has joined #RubyOnRails
[16:38:48] jottr_: has joined #RubyOnRails
[16:41:28] xco: has joined #RubyOnRails
[16:43:45] jhfisc: has joined #RubyOnRails
[16:55:26] jhfisc: has joined #RubyOnRails
[16:56:32] cam27: has joined #RubyOnRails
[16:56:59] cam27: Is this a hash block? if: Proc.new { |order| order.paid_with_card? }
[16:57:39] cam27: just a block like the .eaach method stuff right
[16:59:48] jhfisc: has joined #RubyOnRails
[17:00:44] cpruitt: has joined #RubyOnRails
[17:09:33] quirkycoders: has joined #RubyOnRails
[17:13:43] jhfisc: has joined #RubyOnRails
[17:29:15] cpruitt: has joined #RubyOnRails
[17:32:07] conta2: has joined #RubyOnRails
[17:48:13] daydream: has joined #RubyOnRails
[17:50:36] ivanskie: has joined #RubyOnRails
[17:51:14] ivanskie: rails 5. rspec or minitest?
[17:53:05] ivanskie: starting new project. wondering what are people doing these days. watched a talk about how much built-in testing was improved with rails 5.. which raised this question. Do I go with rspec, or the built in minitest
[17:53:18] delgiudices: has joined #RubyOnRails
[17:55:59] quirkycoders: has joined #RubyOnRails
[18:05:05] dionysus69: I am bashing my head on custom pk and find_or_create_by method
[18:05:32] dionysus69: it just throwns this error https://gist.github.com/anonymous/625a2f9a1f14c1d3f722d194a13bfbec
[18:06:39] dionysus69: I could just do create unless find but I am just curious why find_or_create_by doesnt work. I have actually removed ID column and added executed this in migration ALTER TABLE subdivisions ADD PRIMARY KEY (subdivision_id);
[18:07:12] dionysus69: I also indexed the column, thinking it might be error due to lack of indexing
[18:07:49] dionysus69: it just lacks default value, other than that I recreated same column parameters as with stock id column
[18:08:40] Chernobuk: has joined #RubyOnRails
[18:14:47] danielsousa: has joined #RubyOnRails
[18:15:47] jhfisc: has joined #RubyOnRails
[18:17:32] agent_white: has joined #RubyOnRails
[18:21:33] Technodrome: has joined #RubyOnRails
[18:21:39] armyriad: has joined #RubyOnRails
[18:26:30] jhfisc: has joined #RubyOnRails
[18:26:57] quirkycoders: has joined #RubyOnRails
[18:31:02] rafaeldelucena: has joined #RubyOnRails
[18:31:44] ivanskie: answers to my question earlier rails 5: rspec or minitest. --> https://www.reddit.com/r/rails/comments/5v5tuy/what_do_you_use_and_why_rspec_vs_minitest/
[18:32:51] dionysus69: has joined #RubyOnRails
[18:34:51] jhfisc: has joined #RubyOnRails
[18:38:37] pLaTo0n: has joined #RubyOnRails
[18:40:17] jhfisc: has joined #RubyOnRails
[18:48:45] mtkd: has joined #RubyOnRails
[18:56:19] jhfisc: has joined #RubyOnRails
[18:57:30] quirkycoders: has joined #RubyOnRails
[19:05:59] delgiudices: has joined #RubyOnRails
[19:09:08] pLaTo0n: has joined #RubyOnRails
[19:10:25] jhfisc: has joined #RubyOnRails
[19:16:49] jhfisc: has joined #RubyOnRails
[19:21:08] tbuehlmann: dionysus69: why do you change the pk?
[19:21:40] dionysus69: imported data from api, api data has some guid/uuid
[19:22:12] dionysus69: even though I cant use id in any way, I am still leaving due to recommendation
[19:24:30] KeyJoo: has joined #RubyOnRails
[19:29:42] jhfisc: has joined #RubyOnRails
[19:32:24] jhfisc: has joined #RubyOnRails
[19:35:36] pLaTo0n: has joined #RubyOnRails
[19:48:00] arup_r: has joined #RubyOnRails
[19:48:26] jhfisc: has joined #RubyOnRails
[19:53:12] S1kx: has joined #RubyOnRails
[19:54:07] Technodrome: has joined #RubyOnRails
[19:55:08] jhfisc: has joined #RubyOnRails
[19:56:10] chouhoulis: has joined #RubyOnRails
[19:56:16] xco: has joined #RubyOnRails
[20:00:28] knight33: has joined #RubyOnRails
[20:05:45] jhfisc: has joined #RubyOnRails
[20:13:02] jhfisc: has joined #RubyOnRails
[20:14:58] quirkycoders: has joined #RubyOnRails
[20:24:07] dionysus69: data is the last word of the modelname
[20:24:12] dionysus69: should I call it datum or data?
[20:24:39] jhfisc: has joined #RubyOnRails
[20:24:47] dionysus69: i checked pluralize method on both and it ends up as data in both cases. I guess conventionally it would be still singular > thus datum?
[20:30:39] jhfisc: has joined #RubyOnRails
[20:38:01] delgiudices: has joined #RubyOnRails
[20:41:54] kariyaki: has joined #RubyOnRails
[20:42:03] ivanskie: i'm trying to create a rails app from scratch with testing. i'm failing miserably. (rails 5, devise, rspec, factory girl, faker, capybara). I may have gone ahead of myself a bit. I'm trying to test user signup, login, and all of that. and the test rails generated for users controller is failing to pass.
[20:42:33] ivanskie: says that we're expecting Users to increase by one, but does not.
[20:44:49] ivanskie: last time i made an app a few years back, i was using devise test helpers.. so I'm thinking i should be doing that. but i dont remember how without blatenly copying the spec from last app. A buddy from a diff country and I are getting together to pair program, started last night only to not really get anywhere lol.
[20:45:34] ivanskie: so im trying to do refresher. scramling to look at rails 4 in action book, or rails tutorial, or screencasts, but not finding just stesp to do it without starting completely from scratch arrrrr
[20:45:58] quirkycoders: has joined #RubyOnRails
[20:46:35] ivanskie: yah we could skip writing tests until later but trying to do tdd
[20:47:09] ivanskie: don't know maybe should start from scratch and do core functionality and add user authen/author later??
[20:47:22] ivanskie: crazy how rusty u get without practice for a few years
[20:49:36] ivanskie: ya looks like i need to get rid of new/create and etc in users controller
[20:53:53] jhfisc: has joined #RubyOnRails
[21:01:39] marr: has joined #RubyOnRails
[21:01:48] kariyaki: Does anyone know if there exists a conflict between Simplecov and another gem? I'm using Simplecov to generate coverage results, but the results only show in the generated index.html file under the "coverage" folder. I want the coverage results to show directly in RubyMine in the corresponding controllers/models. I'm currently working on an existing project, so still fresh in the Ruby
[21:01:48] kariyaki: world. Tried creating a new project and ran the tests with coverage, and got the results directly in RubyMine. Therefore I suspect that Simplecov have a conflict with another gem.
[21:09:53] jhfisc: has joined #RubyOnRails
[21:11:05] pLaTo0n: has joined #RubyOnRails
[21:12:46] knight33: has joined #RubyOnRails
[21:16:32] jhfisc: has joined #RubyOnRails
[21:19:15] jhfisc: has joined #RubyOnRails
[21:24:30] jhfisc: has joined #RubyOnRails
[21:27:01] Moeh: has joined #RubyOnRails
[21:35:40] jhfisc: has joined #RubyOnRails
[21:39:45] arBmind: has joined #RubyOnRails
[21:41:05] jhfisc: has joined #RubyOnRails
[21:42:59] gambl0re: has joined #RubyOnRails
[21:46:30] jhfisc: has joined #RubyOnRails
[21:47:48] quirkycoders: has joined #RubyOnRails
[21:51:27] mostlybadfly: has joined #RubyOnRails
[22:03:32] quirkycoders: has joined #RubyOnRails
[22:03:37] Technodrome: has joined #RubyOnRails
[22:15:17] jhfisc: has joined #RubyOnRails
[22:22:31] jhfisc: has joined #RubyOnRails
[22:25:03] diggitydane: has joined #RubyOnRails
[22:27:15] diggitydane: I'm trying to write rspec tests for an API with JWT using cancancan for authorization. When I run a request with 'rspec /spec/requests/alert_responses_spec.rb' all of the tests pass. When I run it will 'rspec' they fail. It appears in the latter that load_and_authorize_resource is called before the parent action runs to authenticate the JWT
[22:27:20] diggitydane: https://gist.github.com/danejorgensen/890bc6daddfcf8f9ff66b44b4d7ed637
[22:28:06] diggitydane: What would different between running 'rspec' and 'rspec /spec/requests/alert_responses_spec.rb' ? I can't find any behavior differences anywhere on them
[22:35:37] jhfisc: has joined #RubyOnRails
[22:49:59] quirkycoders: has joined #RubyOnRails
[23:05:27] quirkycoders: has joined #RubyOnRails
[23:06:49] ResidentBiscuit: has joined #RubyOnRails
[23:11:11] delgiudices: has joined #RubyOnRails
[23:24:27] knight33: has joined #RubyOnRails
[23:30:48] havenwood: diggitydane: the other tests running is the only difference i can think of.
[23:32:27] havenwood: diggitydane: do the tests maybe fail because of the order they're run in? does it always fail with?: --order rand
[23:35:59] diggitydane: havenwood, no order doesn't matter. The main thing that is happening, is when I run with `rspec` load_and_authorize_resource runs first. If I run the test directly, it runs the before_action :authenticate_request! first (which works because I then have a current_user)
[23:36:01] quirkycoders: has joined #RubyOnRails
[23:36:31] havenwood: diggitydane: does it not load first because of the test order? why is it first?
[23:36:58] diggitydane: the actions run in different orders. not sure why
[23:37:09] havenwood: what's calling `load_and_authorize_resource`? another test? setup?
[23:37:27] diggitydane: I've found a few other SO questions that are pretty much the same thing
[23:37:31] diggitydane: https://stackoverflow.com/questions/34751750/integration-testing-a-rails-api-using-devise-token-auth-for-authenticaton-and-ca
[23:38:09] diggitydane: https://stackoverflow.com/questions/41580841/error-in-cancancan-ability-initializer-when-testing-controllers
[23:38:18] diggitydane: unfortunately, neither have answers
[23:39:47] diggitydane: the request is calling load_and_authorize. what's weird is the front-end app works correctly, using curl works correctly, and running the test directly works correctly. The only time it doesn't work is running the full test suite. When I do that, the order of those actions on the class changes
[23:44:16] diggitydane: if i run them random and directly, still passes. I don't think it's an order problem with the tests
[23:52:52] DLSteve: has joined #RubyOnRails