camonz

Activity Graph

Page 1 of 3 | Next »

2018-06-20

[20:03:19] camonz: has joined #ruby
[23:53:59] camonz: Quit: Linkinus - http://linkinus.com

2018-05-11

[09:51:03] camonz: has joined #ruby
[10:10:52] camonz: Quit: Linkinus - http://linkinus.com

2018-05-03

[14:30:24] camonz: has joined #ruby
[17:39:17] camonz: Quit: Linkinus - http://linkinus.com

2018-04-28

[19:51:46] camonz: has joined #ruby
[20:09:41] camonz: Quit: Linkinus - http://linkinus.com

2018-04-27

[00:46:13] camonz: has joined #ruby
[00:46:24] camonz: has joined #RubyOnRails
[00:47:07] camonz: is there a way to config app-wide for routes paths to be dasherized instead of underscored?
[00:56:03] camonz: Radar: thanks dude
[00:56:57] camonz: was just checking out an app with a react frontend and it seems they're dasherizing paths to conform to react's settings
[01:00:09] camonz: yep, that's how they're doing it
[01:00:41] camonz: Ember has a neat solution, just redefine pathForType on the ApplicationAdapter to use underscores
[01:25:20] camonz: Quit: Linkinus - http://linkinus.com

2018-04-20

[08:21:26] camonz: Quit: Linkinus - http://linkinus.com
[12:40:41] camonz: has joined #ruby
[21:52:42] camonz: Quit: Linkinus - http://linkinus.com

2018-04-19

[05:20:45] camonz: has joined #ruby

2018-04-17

[06:10:07] camonz: has joined #ruby
[23:38:45] camonz: Ping timeout: 264 seconds

2018-03-18

[03:27:57] camonz: Ping timeout: 264 seconds

2018-03-15

[09:32:43] camonz: has joined #ruby

2018-01-23

[00:42:33] camonz: Quit: Linkinus - http://linkinus.com

2018-01-22

[16:54:36] camonz: has joined #ruby

2018-01-01

[06:12:49] camonz: Quit: Linkinus - http://linkinus.com

2017-12-31

[15:24:23] camonz: has joined #ruby

2017-12-30

[19:31:44] camonz: has joined #ruby
[19:40:12] camonz: Quit: Linkinus - http://linkinus.com

2017-12-02

[03:50:46] camonz: Quit: Linkinus - http://linkinus.com

2017-12-01

[19:01:37] camonz: has joined #ruby

2017-08-11

[02:11:10] camonz: Read error: Connection reset by peer

2017-08-09

[15:03:34] camonz: has joined #ruby

2017-07-16

[21:54:03] camonz: has joined #ruby
[23:50:38] camonz: Quit: Linkinus - http://linkinus.com

2017-07-02

[04:07:26] camonz: has joined #ruby
[15:39:14] camonz: Quit: Linkinus - http://linkinus.com

2017-06-19

[13:47:25] camonz: has joined #ruby
[13:47:46] camonz: has joined #RubyOnRails
[13:57:59] camonz: Quit: Linkinus - http://linkinus.com

2017-03-30

[18:25:16] camonz: Quit: Linkinus - http://linkinus.com

2017-03-29

[19:15:33] camonz: has joined #ruby
[19:16:01] camonz: has joined #RubyOnRails
[19:17:19] camonz: how can I turn an Arel::SelectManager instance into something I can further compose via a regular WhereChain?
[19:23:46] camonz: centrx: yes, but it's not as simple as composing with a regular AR::Base instance
[19:24:13] camonz: for example, MyClass.custom_query_done_with_arel.find(1)
[19:24:42] camonz: centrx: the idea being the my custom query is a scope
[19:26:11] camonz: centrx: sure but AR throws an error when handling 2 left outer joins with an OR clause :)
[19:26:30] camonz: across a polymorphic relation
[19:27:24] camonz: fwiw here's my query builder https://gist.github.com/CamonZ/65acb2cb748ec4c5b6a668e0e1512bc8
[19:27:26] camonz: that works
[19:27:55] camonz: problem is I'd like in my controller to simply say `Task.for_user(current_user).find(params[:id])`
[19:28:40] camonz: epochwolf: I know :( it's a last resort
[19:29:21] camonz: I tried regular `Task.left_joins([:checklists, :trip_checklists]).where(...)`
[19:30:52] camonz: epochwolf: model, query builder, and controller on this gist https://gist.github.com/CamonZ/65acb2cb748ec4c5b6a668e0e1512bc8
[19:31:48] camonz: centrx: do you mean ActiveRecord::Base.find_by_sql ?
[19:32:59] camonz: epochwolf: that was my first attempt, though the raw sql is unmaintainable
[19:34:39] camonz: Idminuoso: I know how you feel, why use abstractions right. let's just drop AR altogether
[19:35:03] camonz: in all seriousness, Arel is highly verbose and very specific
[19:35:13] camonz: but it does allow a bit more maintainability over a raw sql string
[19:46:35] camonz: sorry, back
[20:08:00] camonz: dminuoso, epochwolf: I have joined the dark side https://gist.github.com/CamonZ/1746a1a82009a13fbfe01778ae446bb9
[20:08:10] camonz: considerably much simpler
[20:08:39] camonz: and it's AR-composable
[20:10:35] camonz: dminuoso: nice catch, thanks!

2016-07-12

[16:11:54] camonz: has joined #RubyOnRails
[16:11:55] camonz: has joined #ruby
[16:13:42] camonz: how can I set the values of a habtm relation without having the entire instance of the associated object
[16:14:19] camonz: because I have a very large object with a GIS geography that I don't need loaded, I just need the id so I can set the habtm
[16:15:32] camonz: no, how to set them on the habtm
[16:15:52] camonz: if I do .association << models with the partially loaded models then I get validation errors on the associated models
[16:17:05] camonz: fair enough
[16:17:14] camonz: feels like overkill though
[16:18:29] camonz: why though, it's just a join table, the rule of thumb is to use hm:t if you plan on manipulating the join table
[16:18:40] camonz: that is, if you have something other than FKs in there
[16:20:35] camonz: fair enough, thanks
[16:20:43] camonz: I'll switch to hm:t
[23:31:55] camonz: Quit: Textual IRC Client: www.textualapp.com

2016-07-09

[01:33:31] camonz: Quit: Textual IRC Client: www.textualapp.com

2016-07-08

[13:33:41] camonz: has joined #ruby
[13:33:41] camonz: has joined #RubyOnRails

2016-07-07

[03:05:02] camonz: Quit: Textual IRC Client: www.textualapp.com
[10:49:08] camonz: has joined #ruby
[10:49:08] camonz: has joined #RubyOnRails
[10:49:38] camonz: Hello, I'm having an issue requiring rgeo-geojson on my rails app even though it's on my Gemfile
[10:50:19] camonz: tried adding it to an new Rails app and it works without issue, so I'm guessing there's some kind of conflict for why Rails says it can't load/find 'rgeo/geo_json'
[10:50:26] camonz: any clues on how to solve / debug this?
[10:56:37] camonz: dminuoso: https://gist.github.com/CamonZ/c372252fb222944ab7d6ae4bd76541fb
[10:58:08] camonz: old habits
[11:00:42] camonz: dminuoso: how?
[11:03:50] camonz: thank you :)
[11:04:06] camonz: killed all spring processes and restarted the rails console
[11:04:34] camonz: roelof: yes
[11:07:36] camonz: hahahaha love that checklist
[11:08:16] camonz: roelof: before committing to deleting it, bundle exec spring stop
[11:08:39] camonz: or the old fashioned way of ps -e | grep spring and kill -9 those pids
[11:09:19] camonz: dminuoso is right tho, that problem I just had was incredibly opaque
[11:14:27] camonz: roelof: https://gist.github.com/rwobben/ee02f1ac6777513497cc311ce24f9bb9#file-accounts_controller-rb-create-L3
[11:27:17] camonz: roelof: test it with http://reggyapp.com/
[11:27:42] camonz: roelof: test it with http://reggyapp.com/
[11:33:55] camonz: the moment you realize you've been doing too much javascript: "if feature.geometry.geometry_type !== RGeo::Feature::Point"
[11:34:38] camonz: it's prob very similar to rubular
[11:36:13] camonz: roelof: try with [\w|"]+
[12:16:50] camonz: dkam: (they have)
[12:17:04] camonz: use a request spec
[12:17:14] camonz: test the full vertical for the app
[12:17:21] camonz: s/full/entire
[12:23:46] camonz: Read error: Connection reset by peer
[12:24:11] camonz: has joined #ruby
[12:24:11] camonz: has joined #RubyOnRails
[12:30:27] camonz: dkam: how are you authenticating users, devise?
[20:39:25] camonz: Read error: No route to host

2016-07-06

[15:05:02] camonz: has joined #RubyOnRails
[15:05:03] camonz: has joined #ruby
[15:06:23] camonz: I'm having an issue trying to instantiate a model with geo data from PostGIS on Heroku. When selecting any of the fields with geo data or all the fields of the instance I get an (Object doesn't support #inspect) error
[15:06:30] camonz: any clues?
[15:07:41] camonz: here's a gist with the heroku console output https://gist.github.com/CamonZ/ea34ec1609e2b997608b7f252673986b
[15:07:55] camonz: running the same on dev works fine
[15:32:52] camonz: kriptonium: learn ruby through Rails
[15:33:33] camonz: roelof: show us the schema def
[15:35:08] camonz: SteenJobs: why would you want to do that?
[15:35:43] camonz: wordpress alongside rails
[15:35:51] camonz: but fair enough, I'd do it straight in production
[15:35:53] camonz: it's 2 different apps
[15:36:12] camonz: proxy through them with nginx or apache
[15:38:36] camonz: roelof: validate!( schema, strict: true)
[15:38:41] camonz: have you tried that?
[15:39:55] camonz: SteenJobs: Then I'd have a staging env as well
[15:40:15] camonz: in case the designer breaks something up
[15:40:34] camonz: should be straightforward with capistrano
[15:40:38] camonz: different stages
[15:42:26] camonz: roelof_: shouldn't params[:name] be run through JSON.parse first?
[15:42:59] camonz: that is, not by you but by the controller
[15:43:21] camonz: it should happen automatically, unless you're sending on the JSON: {"name": "{test}"}
[15:43:26] camonz: then that's a valid string
[15:44:20] camonz: SteenJobs: how's he changing the styles. straight into the wordpress app?
[15:45:32] camonz: unless he has ssh access to the server
[15:45:42] camonz: or worst-case scenario the wordpress gets hacked
[15:46:42] camonz: imo, I'd run a locomotive instance instead of wordpress but it's not as cost-effective as simply doing a wordpress install
[15:48:56] camonz: roelof: if one of the fields on the JSON received has invalid chars then you need to clean it up
[16:02:37] camonz: roelof: it is a string, "{test}"
[16:03:17] camonz: look at the difference with 'account[category]=Bezittingen langer dan 1 jaar'
[16:04:03] camonz: postman = https://www.getpostman.com/?
[16:05:22] camonz: ok, it's interesting that it's sending the {} as well
[16:06:40] camonz: ahh, I thought you were sending test and receiving {test}

2016-07-05

[00:21:23] camonz: has joined #ruby
[00:21:23] camonz: has joined #RubyOnRails
[00:22:56] camonz: so I got a list of points with an elevation and I want to store em on PostGIS, what's the best way to save the data, XYZ spheric point or X,Y with elevation?
[01:29:57] camonz: Read error: Connection reset by peer
[07:37:48] camonz: has joined #ruby
[07:37:48] camonz: has joined #RubyOnRails
[09:39:59] camonz: Read error: Connection reset by peer

2015-12-01

[08:49:28] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-11-30

[20:49:35] camonz: has joined #RubyOnRails
[20:49:36] camonz: has joined #ruby
[20:50:09] camonz: what are some OSS repos with bad code that I could take a look at?
[20:51:02] camonz: what are some example repos of bad code?
[20:51:25] camonz: Radar: thanks!
[20:51:48] camonz: I want to analize them with codeclimate
[20:56:03] camonz: Ox29c1: that makes absolutely no sense
[20:56:42] camonz: *Analyse :)
[20:59:28] camonz: eam: PERL? :)
[21:00:15] camonz: https://codeclimate.com/github/square/rangeclient/issues
[21:01:12] camonz: it's not very ruby???like, but CC didn't find much, 8 violations, 3 from complexity, 4 in style and a possible bug risk
[21:09:15] camonz: eam: the loop here can be turned into a private method https://gist.github.com/CamonZ/4aad283de81902e035b4
[21:09:29] camonz: and the if condition into another
[21:12:23] camonz: #_sort_nodes is unreadable and the assignment there is the same that is being done in the nodes.each loop that I gist'd
[21:13:13] camonz: eam: dude, thanks! this is a great example. I have to interview a dev tomorrow and really needed some oss code that we could talk-through/refactor

2015-11-26

[12:47:55] camonz: has joined #RubyOnRails
[12:47:56] camonz: has joined #ruby
[16:35:35] camonz: Read error: Connection reset by peer

2015-11-23

[07:20:16] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-11-22

[19:21:37] camonz: has joined #ruby
[19:21:37] camonz: has joined #RubyOnRails

2015-08-12

[11:21:16] camonz: has joined #RubyOnRails
[11:21:17] camonz: has joined #ruby
[23:21:06] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-08-10

[10:24:28] camonz: has joined #ruby
[10:24:28] camonz: has joined #RubyOnRails
[22:23:44] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-07-12

[11:08:45] camonz: has joined #ruby
[11:08:45] camonz: has joined #RubyOnRails
[23:06:58] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-07-06

[02:57:17] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-07-05

[14:57:27] camonz: has joined #ruby
[14:57:27] camonz: has joined #RubyOnRails

2015-07-04

[02:02:58] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-07-03

[14:03:44] camonz: has joined #RubyOnRails
[14:03:45] camonz: has joined #ruby

2015-06-30

[07:39:39] camonz: has joined #ruby
[07:39:39] camonz: has joined #RubyOnRails
[08:09:33] camonz: Read error: Connection reset by peer

2015-06-29

[12:27:07] camonz: has joined #ruby
[12:27:07] camonz: has joined #RubyOnRails
[13:03:09] camonz: Read error: Connection reset by peer

2015-06-25

[10:24:20] camonz: has joined #ruby
[10:24:20] camonz: has joined #RubyOnRails
[22:24:09] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-06-24

[16:52:50] camonz: has joined #ruby
[16:52:50] camonz: has joined #RubyOnRails
[22:39:17] camonz: Read error: Connection reset by peer

2015-06-23

[12:23:16] camonz: has joined #ruby
[12:23:16] camonz: has joined #RubyOnRails
[16:26:50] camonz: Read error: No route to host

2015-06-19

[01:18:06] camonz: Quit: Textual IRC Client: www.textualapp.com
[10:59:41] camonz: has joined #RubyOnRails
[10:59:42] camonz: has joined #ruby
[22:59:18] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-06-18

[10:03:13] camonz: has joined #ruby
[10:03:13] camonz: has joined #RubyOnRails
[13:07:37] camonz: Ping timeout: 264 seconds
[13:18:17] camonz: has joined #ruby
[13:18:17] camonz: has joined #RubyOnRails

2015-06-17

[21:43:56] camonz: has joined #RubyOnRails
[21:43:57] camonz: has joined #ruby
[22:39:32] camonz: Quit: Textual IRC Client: www.textualapp.com

2015-06-12

[10:04:56] camonz: has joined #ruby
[10:04:56] camonz: has joined #RubyOnRails
[14:25:44] camonz: Read error: Connection reset by peer

2015-06-11

[12:29:41] camonz: has joined #ruby
[12:29:41] camonz: has joined #RubyOnRails
[13:51:04] camonz: Read error: Connection reset by peer

2015-06-10

[00:44:08] camonz: Read error: Connection reset by peer
[08:30:32] camonz: has joined #ruby
[08:30:32] camonz: has joined #RubyOnRails
[12:57:25] camonz: Read error: Connection reset by peer

2015-06-09

[17:47:24] camonz: has joined #ruby
[17:47:24] camonz: has joined #RubyOnRails
[17:47:49] camonz: I'm trying to load my schema on a CI srever and i'm getting a `PG::InvalidDatetimeFormat: ERROR: invalid input syntax for type date: "(now() - '1 day'::interval)"` error
[17:48:17] camonz: the (now() - '1 day'::interval) is the default value that I'm setting to a column

2015-06-08

[12:58:29] camonz: Read error: Connection reset by peer