dcope

Activity Graph

Page 1 of 11 | Next »

2018-11-26

[09:25:26] dcope: *.net *.split

2018-10-21

[15:53:42] dcope: anyone in here developing in docker? i can't figure out if the slow rails server is isolated to my setup or if that's just how it is.

2018-10-20

[16:02:12] dcope: does anyone in here develop in docker? it seems like the rails server is _super_ slow in docker.
[16:09:13] dcope: has joined #ruby
[16:19:22] dcope: has left #ruby: ()

2018-01-11

[03:03:55] dcope: why would rake db:seed try to recreate the database? it looks like it is trying to drop tables and recreate.

2018-01-10

[12:55:27] dcope: Ping timeout: 240 seconds
[12:58:02] dcope: has joined #RubyOnRails

2018-01-05

[14:46:39] dcope: Ping timeout: 256 seconds
[14:46:49] dcope: has joined #RubyOnRails

2017-12-21

[02:09:41] dcope: Ping timeout: 260 seconds
[02:12:25] dcope: has joined #RubyOnRails

2017-12-07

[03:39:05] dcope: Ping timeout: 240 seconds
[03:40:38] dcope: has joined #RubyOnRails

2017-11-16

[01:28:20] dcope: has joined #RubyOnRails

2017-10-04

[20:56:29] dcope: what's the proper way to retrieve the url for an asset? i'm trying to load static assets and serve them through a rails api.

2017-09-20

[15:46:07] dcope: Ping timeout: 248 seconds
[15:47:33] dcope: has joined #RubyOnRails

2017-09-07

[04:25:21] dcope: has joined #RubyOnRails
[19:17:21] dcope: Ping timeout: 248 seconds
[19:18:46] dcope: has joined #RubyOnRails

2017-09-04

[18:19:02] dcope: has joined #RubyOnRails
[18:19:39] dcope: is there a trick to get factory girl to work with habtm? i have a "role" model that is just a join table. i can't seem to get factory girl to build the relationship.

2017-07-23

[20:09:42] dcope: has left #RubyOnRails: ()

2017-07-22

[22:34:52] dcope: has joined #RubyOnRails
[22:35:31] dcope: is there a built in way to run something on a background thread and continue execution to fulfill a request?
[22:36:07] dcope: looking for something other than delayed job, resque, etc.

2017-04-13

[15:10:52] dcope: *.net *.split

2017-03-15

[02:05:09] dcope: Ping timeout: 260 seconds
[02:13:02] dcope: has joined #RubyOnRails
[02:13:02] dcope: Changing host
[02:13:02] dcope: has joined #RubyOnRails

2017-03-12

[03:34:49] dcope: has joined #RubyOnRails

2016-07-10

[16:11:27] dcope: i'm adding pjax to an old rails app and am wondering if there's a good way to override every controller method? i need to be able to not render the layout if the pjax header is in the request.
[16:11:32] dcope: what's the best way to go about doing it automatically?
[16:29:59] dcope: fryguy: i have, but i'd like to just use pjax for now.

2016-06-25

[13:51:17] dcope: Ping timeout: 258 seconds
[13:51:18] dcope: has joined #RubyOnRails
[13:51:18] dcope: has joined #ruby
[13:51:22] dcope: has joined #ruby
[13:51:22] dcope: has joined #RubyOnRails
[13:51:22] dcope: Changing host

2016-06-07

[19:04:30] dcope: Ping timeout: 276 seconds
[19:05:40] dcope: has joined #RubyOnRails
[19:05:40] dcope: has joined #ruby

2016-05-27

[14:01:38] dcope: whats the best way to fetch models in batches but also apply an overall limit?
[14:09:11] dcope: tbuehlmann: the total number of records
[14:09:24] dcope: ie loop through 100 records with batches of 5
[14:11:00] dcope: tbuehlmann: sorry, not following you.
[14:11:30] dcope: im hoping to loop through 100 models with batches of 5. ie the enumerator will get executed 20 times with batches of 5 models

2016-05-05

[14:42:58] dcope: hey all, i have an AR accessor on a model called `index`. a gem i just installed has it's own method called `index` for AR models. what's the best way to redefine mine without having to rename the column?
[14:43:41] dcope: fox_mulder_cp: sunspot
[14:43:48] dcope: for solr searching
[14:45:23] dcope: smathy: awesome! this is perfect. thank you :)
[14:50:46] dcope: oh no, this *just* does an alias
[14:50:56] dcope: so it's still calling the `index` method :P
[14:53:54] dcope: solved by just making my own accessor methods with read_attr and write_attr

2016-05-04

[11:54:54] dcope: Ping timeout: 276 seconds
[12:09:16] dcope: has joined #RubyOnRails
[12:09:16] dcope: has joined #ruby

2016-04-21

[20:44:29] dcope: can someone please tell me why the 'where' clause does not return anything? http://pastie.org/private/x7tptgphhfanrhgouhvhwg
[20:47:00] dcope: i'm certainly doing something wrong with the where clause but i can't see it. :(
[20:49:57] dcope: weaksauce: postgres 9.1
[20:50:38] dcope: this is so weird. when i run Book.where("released_at <= '{Time.now}'") i get some results but not the one im searching for
[20:50:52] dcope: but if i manually compare the released_at to Time.now, it's true o_O
[20:52:34] dcope: weaksauce: it's not returning based on released_at <= Time.now
[20:52:39] dcope: the first condition is fine
[20:54:42] dcope: weaksauce: Book.where(released_at: (Time.now - 1.day)..Time.now)
[20:54:44] dcope: that fixes it :)
[20:55:20] dcope: + 1.day does too, but i need to make sure i don't pull records with a future released_at
[20:55:30] dcope: looks like this syntax causes pg to do a "BETWEEN"
[21:12:57] dcope: ah that makes sense
[21:13:02] dcope: thanks weaksauce and smathy for the insight :)

2016-04-18

[21:15:52] dcope: Ping timeout: 260 seconds
[21:17:45] dcope: has joined #RubyOnRails
[21:17:45] dcope: has joined #ruby

2016-04-17

[22:22:43] dcope: Ping timeout: 260 seconds
[22:23:47] dcope: has joined #RubyOnRails
[22:23:47] dcope: has joined #ruby

2016-04-15

[05:27:28] dcope: Ping timeout: 264 seconds
[05:33:05] dcope: has joined #RubyOnRails
[05:33:05] dcope: has joined #ruby
[13:53:48] dcope: is there a way to abort a long running task other than using Timeout::timeout
[18:54:27] dcope: if i set a read_timeout and an open_timeout on Net::HTTP will the request cancel if it times out?
[19:00:02] dcope: context: it seems to in dev but in production i have logs showing http requests taking longer than the timeout
[19:02:29] dcope: context: what's the better alternative?
[19:02:42] dcope: i just need to ensure an HTTP post does not take longer than N seconds. it's being sent to a server i do not control.
[19:04:57] dcope: there's no telling
[19:05:19] dcope: my monitoring software is just showing http requests taking well over the timeout
[19:05:31] dcope: so im wondering if the http requests continue to run until they finish or the server times out... or what
[19:05:41] dcope: a request im making
[19:05:55] dcope: i'm posting to a 3rd party server
[19:06:45] dcope: tried that too
[19:07:08] dcope: haha yeah, i've been reading up on it. pretty much everyone opposes it :P

2016-04-14

[04:31:28] dcope: Ping timeout: 276 seconds
[04:32:29] dcope: has joined #RubyOnRails
[04:32:29] dcope: has joined #ruby
[21:52:56] dcope: Ping timeout: 268 seconds
[21:58:47] dcope: has joined #RubyOnRails
[21:58:47] dcope: has joined #ruby

2016-04-07

[19:45:50] dcope: hi all, is there a helper method to iterate over batches of an AR result set?
[19:45:58] dcope: say i get 200 records back, is there a helper method to loop over them 5 at a time?
[19:46:10] dcope: instead of `each`

2016-03-30

[16:35:44] dcope: is there a way to 'wrap' a call with a timeout handler?
[16:35:57] dcope: i am calling into a gem that makes an http request but i'd like to wrap some sort of timeout around it

2016-03-29

[21:04:23] dcope: is there an easy way to check if a string contains emoji?
[21:25:45] dcope: tobiasvl: awesome, thank you!

2016-03-24

[15:00:35] dcope: is there a general web dev channel? i'm having an issue with cors that isn't particularly rails related.

2016-03-09

[13:41:58] dcope: has anyone in here purchased this? https://gumroad.com/l/backbone-js-on-rails i'm wondering if it's good / worth the $30

2016-03-08

[04:26:27] dcope: has joined #ruby
[04:26:39] dcope: with net http, how can i set a query string?
[04:26:53] dcope: i can't find any applicable properties on Net::HTTP::Get
[04:28:14] dcope: Radar: i'm just using net:http to keep it simple. this is just a simple shell script i'm playing with. :)
[04:28:58] dcope: Radar: well, simple to setup. i was just trying to stick in with built in libraries.
[04:29:04] dcope: request_uri did the trick though! thank you :D

2016-03-06

[15:00:25] dcope: is there a gem to create static pages on the fly?
[15:00:30] dcope: it seems that high voltage is not capable of this
[20:59:36] dcope: is there a gem to create static pages on the fly?
[20:59:38] dcope: it seems that high voltage is not capable of this

2016-02-28

[09:32:08] dcope: Ping timeout: 244 seconds
[09:32:19] dcope: has joined #RubyOnRails
[09:32:20] dcope: has joined #RubyOnRails
[09:32:20] dcope: Changing host
[09:39:21] dcope: Ping timeout: 244 seconds
[10:40:24] dcope: has joined #RubyOnRails

2016-02-27

[22:24:05] dcope: Ping timeout: 252 seconds
[22:53:10] dcope: has joined #RubyOnRails
[22:53:10] dcope: Changing host
[22:53:10] dcope: has joined #RubyOnRails

2016-02-26

[17:20:47] dcope: *.net *.split
[17:21:30] dcope: has joined #RubyOnRails

2016-02-25

[12:18:12] dcope: why would assets precompile randomly fail when deploying with capistrano?
[12:18:25] dcope: it seems to work 90% of the time... but randomly i can't deploy because assets precompile fails
[12:23:13] dcope: rvanlieshout: it doesn't give an error
[12:23:21] dcope: it just says rolling back because assets precompile failed :(
[12:23:33] dcope: when it happens i just keep deploying til it goes through :/
[12:52:04] dcope: rvanlieshout: perhaps, ill check into that

2016-02-24

[19:20:26] dcope: is the default value for an integer column null?
[20:44:57] dcope: hey all, i just added an integer column to a model. i'm trying to check to see if a value is set but i'm getting a "missing attribute" error. it works fine when the value is non-nil.
[20:45:01] dcope: any ideas?

2016-02-16

[02:00:39] dcope: anyone in here ever gotten devise + grape working in tandem?

2016-02-15

[21:51:10] dcope: i'm trying to use devise (warden) + another piece of middleware and i can't figure out why warden thinks im not authenticated
[21:51:16] dcope: following this: http://www.programmatic.me/blog/2014/11/14/making-devise-token-authenticable-work-with-grape-apis/
[21:51:37] dcope: has anyone used warden + other middleware?

2016-02-12

[04:00:55] dcope: has anyone used tcocca/acts_as_follower ?
[04:11:12] dcope: has left #ruby: ()
[14:06:42] dcope: has anyone in here used tcocca/acts_as_follower?
[14:06:47] dcope: would love to hear thoughts about it.
[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: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

2016-01-31

[12:25:16] dcope: *.net *.split
[12:28:35] dcope: has joined #ruby
[12:28:38] dcope: has joined #RubyOnRails

2016-01-29

[16:16:54] dcope: has joined #ruby
[16:17:06] dcope: is there any way to add a timer or some sort of timeout to wrap a potentially long running http call?
[16:46:43] dcope: Ox0dea: it doesn't, that's why im having to look at alternatives
[16:46:53] dcope: it's a gem that makes an http request... so im trying to figure out how to wrap that

2016-01-22

[15:52:20] dcope: i have a dalli / memcached cache store. whenever i call Rails.cache.fetch(key) (with no expiration or options) the cache does not seem to live indefinitely
[15:52:28] dcope: it's almost like it's being auto purged after time. why is this?
[17:00:42] dcope: i have a dalli / memcached cache store. whenever i call Rails.cache.fetch(key) (with no expiration or options) the cache does not seem to live indefinitely

2016-01-18

[22:42:27] dcope: memcache doesn't have some sort of auto expiry built in does it? i used to have a key that was supposed to expire every 24 hours but now i've removed that option and the query still seems to run every 24h.
[22:43:19] dcope: perhaps i should just write this to redis
[22:43:22] dcope: instead of memcache
[22:43:38] dcope: just a few serialized objects
[22:44:41] dcope: FailBit: will memcache only purge under heavy load? i just checked and memory usage never surpasses 25%
[22:45:16] dcope: total ram
[22:45:28] dcope: of the system memcache is running on
[22:45:35] dcope: interesting
[22:48:14] dcope: FailBit: 1 gig
[22:49:03] dcope: redis + memcache usage never exceeds 256 mb :P
[22:49:12] dcope: this machine is solely used for cachce
[22:49:59] dcope: FailBit: is this part of a rails app?
[22:50:34] dcope: FailBit: interesting. i bet you've found the solution to every scaling problem i've come across :D
[22:50:37] dcope: that's pretty impressive
[22:52:03] dcope: FailBit: only 4gb for the app server?
[22:53:00] dcope: FailBit: how many concurrent http connections are you handling with that setup?
[22:54:45] dcope: ah gotcha

2016-01-17

[23:30:12] dcope: if a cache is written with no expiry... it should never auto-expire, correct? there's no memcache implementation that does this or anything, right?
[23:31:06] dcope: trying to track down how a slow query is happening and its driving me nuts LOL
[23:40:23] dcope: rhizome: thanks for the suggestion, looks interesting

2016-01-11

[01:50:50] dcope: anyone using ActiveAdmin in a large-scale production environment? it seems to get VERY slow when it tries to load some data. and times out a ton.
[01:50:59] dcope: almost like it's loading (joining?) much more data than it needs to
[01:51:04] dcope: sevenseacat: lol!
[01:51:54] dcope: n00bdev: heh, i'd like to do the same. AA hsa just saved up a lot of time thus far... but it is time to look elsewhere
[02:13:49] dcope: Cohedrin: i love the idea behind it... it's just very slow.
[02:14:14] dcope: having a little DSL to show data and make a quick form for someone to work with is amazing imo
[02:14:17] dcope: Cohedrin: to load
[02:23:25] dcope: no, just for internal folks to manage models.
[02:23:39] dcope: and view data (trends, graphs, etc.)
[02:24:18] dcope: the more the merrier :D

2016-01-09

[02:51:04] dcope: hey all, if im trying to get records that have at least one relationship (it's a to many), i thought i could just do an inner join. it seems to return records * relationships.

2016-01-07

[02:35:05] dcope: hey all, i have a Company with a Person in it. what's the best way to query for companies with at least one person or more?
[02:35:36] dcope: i'm trying a join with group & having but i keep getting SQL errors about the having not containing the same column as group
[02:36:06] dcope: Radar: interesting, i didn't know the join would discard non-joined rows

2015-12-10

[21:15:09] dcope: has left #ruby: ()

2015-12-06

[04:17:16] dcope: has joined #ruby
[04:17:29] dcope: if i do a system() call, is there a way to cd into another directory?
[04:21:22] dcope: awesome, thanks pontiki
[14:17:14] dcope: do delayed job jobs execute from the rails application directory?

2015-12-04

[20:49:02] dcope: is there a way to bundle platform binaries in a rails app so it can call to them?
[20:49:10] dcope: without installing the dependencies on the system itself
[20:49:39] dcope: tubbo: yeah, just like a linux binary
[20:51:55] dcope: yeah, i figured that was the 'right' way to do it
[21:04:38] dcope: tubbo: the issue is that im in charge of these binaries

2015-12-03

[15:35:47] dcope: will add_column :table, :column, :boolean allow nulls by default?
[15:36:41] dcope: i want to allow, so the default is to allow?
[15:37:08] dcope: great, arup_r so i assume any existing data will default to null since the column is being added after there is existing data?
[18:05:10] dcope: i'm going to run a migration (pg) on a table without about 500k rows tonight. it will just add a column (nothing else). anything to be cautious of?

2015-12-02

[15:38:48] dcope: *.net *.split
[15:41:42] dcope: has joined #RubyOnRails
[15:51:36] dcope: *.net *.split
[16:48:02] dcope: has joined #RubyOnRails

2015-11-29

[21:11:21] dcope: *.net *.split
[21:13:56] dcope: has joined #RubyOnRails
[21:13:56] dcope: Changing host
[21:13:56] dcope: has joined #RubyOnRails

2015-11-27

[10:20:29] dcope: Ping timeout: 272 seconds
[10:20:31] dcope: has joined #RubyOnRails
[10:21:10] dcope: has joined #RubyOnRails
[10:21:10] dcope: Changing host

2015-11-24

[15:43:40] dcope: hey all, i moved my deploy (git) machine to a new network and now i'm having trouble deploying with capistrano. cap keeps saying fatal: The remote end hung up unexpectedly. is there a problem with the ssh key?
[15:44:15] dcope: i'm using ssh forwarding agent with capistrano and i can access the git repository locally just fine.
[15:45:24] dcope: CornishPasty: to the app serve from my local machine?
[15:45:35] dcope: yes, it works fine.
[15:45:48] dcope: this worked fine before moving the git box to a new network :(
[15:45:56] dcope: i can clone on my local machine just fine, too
[15:50:19] dcope: arup_r: i'm not using github :(
[15:50:43] dcope: i wonder if it's getting confused because the hostname is the same, but the ip has changed since moving the box to the new network

2015-11-16

[06:27:30] dcope: Ping timeout: 240 seconds
[06:27:52] dcope: has joined #RubyOnRails

2015-10-30

[03:43:36] dcope: if i have a belongs to many, i can just use << to create a new relationship and save it right?
[03:47:53] dcope: Radar: if i have User that has many Roles, but there is just a single record per role
[03:48:23] dcope: i could add a user to a role by doing User.roles << Role.find_by_name("Copy Editors")
[03:48:28] dcope: Radar: awesome, thank you! :)

2015-10-17

[15:47:30] dcope: is there a way to mark a delayed job as incomplete?
[15:47:53] dcope: ie if the job relies on a service, but the call to the service fails is there a way to keep the job in the queue so it can be retried later?
[15:51:12] dcope: renegadeandy: yes

2015-10-16

[00:10:16] dcope: has joined #RubyOnRails