weaksauce

Activity Graph

Page 1 of 40 | Next »

2019-05-25

[00:04:50] weaksauce: in a loop amperry? is it just a basic ruby object or an active record model?
[00:05:14] weaksauce: existing object or new?
[00:11:36] weaksauce: and you can't use update(thehash)
[00:17:24] weaksauce: i mean you can loop over the hash by k,v and update each
[00:17:45] weaksauce: do lease[k] = v
[00:17:56] weaksauce: then lease.save when you are done
[00:18:51] weaksauce: `the_hash.each do |k, v| lease[k] = v; end`
[00:24:55] weaksauce: you're welcome

2019-05-24

[21:53:24] weaksauce: xco https://github.com/rails/rails/blob/master/railties/lib/rails.rb#L7
[21:56:02] weaksauce: also xco https://edgeguides.rubyonrails.org/active_support_core_extensions.html

2019-05-22

[02:37:42] weaksauce: why rails in the first place
[18:41:29] weaksauce: axsuul end_at paired with start_at?
[18:42:20] weaksauce: the old saying goes there are 2 hard things in computer science: cache invalidation, naming things and off by one errors
[19:11:50] weaksauce: what's causing you trouble with uuids?
[19:23:38] weaksauce: i guess you could keep the uuid as a backup and use an int as the primary key if it's causing you issue

2019-05-21

[00:02:14] weaksauce: and there's no typos in the app policy initializer?
[00:19:30] weaksauce: not familiar with rolify really
[12:39:40] weaksauce: Ping timeout: 246 seconds
[21:53:39] weaksauce: has joined #RubyOnRails
[21:59:31] weaksauce: is there a common pattern to handling webrequests that defer to a background job and then notify the client that a job has completed (say to download a payload as a response)?
[23:43:37] weaksauce: thanks havenwood!

2019-05-20

[23:10:27] weaksauce: ziyadb ask your question and if someone knows the answer they will respond. also, irc takes a while to respond a lot of the time
[23:15:50] weaksauce: if you can gist code too that is a help to people
[23:16:08] weaksauce: it's hard to conceptualize what might be going wrong with a small description
[23:27:39] weaksauce: and you're sure @space is an object before calling authorize in set_space
[23:35:22] weaksauce: a quick puts @space before that authorize call would show you in the terminal
[23:38:40] weaksauce: is there an initialize method in spacespolicy
[23:45:30] weaksauce: oh lol it should be @record not record
[23:51:17] weaksauce: ah yeah if you have attr_reader it wouldn't matter
[23:52:05] weaksauce: or not. my ruby is a bit rusyt
[23:54:22] weaksauce: user.has_rsole
[23:54:30] weaksauce: might want to change that
[23:56:27] weaksauce: which request are you testing? edit/show/?
[23:56:35] weaksauce: only update?
[23:58:21] weaksauce: pundit is pretty simple so it's surprising

2019-05-18

[02:05:42] weaksauce: probably a path issue with bundler
[02:14:52] weaksauce: i imagine there is a way to change the path using a bundler setting to make it accessible to both users
[02:15:08] weaksauce: check the bundler settings
[02:37:48] weaksauce: you're welcome randomuser1012
[19:18:44] weaksauce: perhaps changing bundle config path /some/shared/path would help randomuseragain
[19:19:15] weaksauce: but you do have to be on the same ruby
[19:21:26] weaksauce: IGnorAND not sure what your question is actually. can you be a bit more specific than "And I am somewhat succesful, but I feel I am doing something wrong"
[19:22:03] weaksauce: what is stopping you from converting the data to a json response directly?
[19:29:06] weaksauce: i'm not sure but something accessible by both accounts and not likely to be overwritten by a cache purge.
[19:29:12] weaksauce: should work
[19:29:55] weaksauce: you can do it under ./vendor/bundler if you want. just .gitignore that directory
[19:32:28] weaksauce: well you do need bundler installed but you also need the same ruby
[19:32:52] weaksauce: you can try gem install bundler
[19:33:18] weaksauce: and move all the gems under the same path. in ./vendor/bundler
[19:33:29] weaksauce: after you make the config change you need to bundle install
[19:35:13] weaksauce: that's because you are using the system ruby i guess.
[19:35:40] weaksauce: which ruby are you using on the other account?
[19:36:50] weaksauce: well that's part of the problem
[19:37:06] weaksauce: make both use ruby2.6
[19:40:38] weaksauce: i don't use rvm sorry
[19:43:22] weaksauce: either install a system ruby and keep that up to date (not always the best move) or install rvm on the postgres account or set postgress permissions temporarily to install bundler or give your app account permissions to run db migrations
[20:37:52] weaksauce: randomuseragain that works. i doubt there is a "best" way on things like that.

2019-05-17

[23:55:30] weaksauce: IGnorAND can you expand on what you are trying to do?

2019-05-15

[23:03:12] weaksauce: has joined #RubyOnRails

2018-12-16

[22:44:30] weaksauce: has left #ruby: ("Textual IRC Client: www.textualapp.com")

2018-12-15

[21:49:31] weaksauce: has left #RubyOnRails: ("Textual IRC Client: www.textualapp.com")

2018-12-13

[00:02:25] weaksauce: has joined #ruby
[00:02:45] weaksauce: has joined #RubyOnRails
[17:01:26] weaksauce: Ping timeout: 272 seconds
[18:11:22] weaksauce: has joined #RubyOnRails
[18:11:54] weaksauce: has joined #ruby

2018-12-12

[05:18:29] weaksauce: Read error: Connection reset by peer
[19:25:37] weaksauce: has joined #RubyOnRails
[19:25:49] weaksauce: has joined #ruby
[21:56:12] weaksauce: Quit: Textual IRC Client: www.textualapp.com
[21:58:45] weaksauce: has joined #RubyOnRails
[21:59:13] weaksauce: has joined #ruby
[23:28:20] weaksauce: Quit: Textual IRC Client: www.textualapp.com

2018-12-10

[00:00:40] weaksauce: Read error: Connection reset by peer
[21:34:46] weaksauce: has joined #RubyOnRails
[21:35:06] weaksauce: has joined #ruby

2018-12-08

[12:49:38] weaksauce: Ping timeout: 245 seconds
[20:25:36] weaksauce: has joined #RubyOnRails
[20:25:52] weaksauce: has joined #ruby

2018-12-06

[08:25:54] weaksauce: Ping timeout: 268 seconds
[17:11:48] weaksauce: has joined #RubyOnRails
[17:12:03] weaksauce: has joined #ruby

2018-12-05

[02:58:20] weaksauce: Read error: Connection reset by peer
[19:45:01] weaksauce: has joined #RubyOnRails
[19:45:19] weaksauce: has joined #ruby

2018-11-25

[23:58:22] weaksauce: has joined #ruby
[23:58:25] weaksauce: has joined #RubyOnRails

2018-11-23

[05:20:49] weaksauce: Ping timeout: 246 seconds

2018-11-22

[22:22:44] weaksauce: has joined #RubyOnRails
[22:22:46] weaksauce: has joined #ruby

2018-11-19

[08:09:38] weaksauce: Ping timeout: 245 seconds

2018-11-18

[14:00:24] weaksauce: Ping timeout: 268 seconds
[19:41:10] weaksauce: has joined #RubyOnRails
[19:41:14] weaksauce: has joined #ruby

2018-11-17

[22:19:55] weaksauce: has joined #ruby
[22:20:16] weaksauce: has joined #RubyOnRails

2018-11-13

[01:16:38] weaksauce: has joined #RubyOnRails
[01:16:42] weaksauce: has joined #ruby
[22:11:10] weaksauce: Read error: Connection reset by peer

2018-11-11

[02:16:07] weaksauce: Ping timeout: 240 seconds

2018-11-10

[19:39:31] weaksauce: has joined #RubyOnRails
[19:39:35] weaksauce: has joined #ruby

2018-11-08

[14:02:13] weaksauce: *.net *.split

2018-11-07

[19:23:56] weaksauce: has joined #ruby
[19:24:08] weaksauce: has joined #RubyOnRails

2018-11-06

[01:33:47] weaksauce: has joined #ruby
[01:33:57] weaksauce: has joined #RubyOnRails
[08:12:06] weaksauce: Ping timeout: 252 seconds

2018-11-05

[00:52:55] weaksauce: has joined #RubyOnRails
[00:53:10] weaksauce: has joined #ruby
[19:20:20] weaksauce: Quit: My MacBook Pro has gone to sleep. ZZZzzz…
[20:36:40] weaksauce: has joined #ruby
[20:36:41] weaksauce: has joined #RubyOnRails
[22:03:54] weaksauce: Ping timeout: 252 seconds

2018-11-02

[09:29:19] weaksauce: Ping timeout: 246 seconds

2018-10-29

[19:44:42] weaksauce: Quit: Textual IRC Client: www.textualapp.com
[19:45:16] weaksauce: has joined #ruby
[19:45:42] weaksauce: has joined #RubyOnRails

2018-10-20

[20:20:15] weaksauce: has joined #RubyOnRails
[20:20:24] weaksauce: has joined #ruby

2018-10-17

[05:49:21] weaksauce: Ping timeout: 244 seconds

2018-10-09

[08:28:57] weaksauce: Ping timeout: 252 seconds
[18:26:19] weaksauce: has joined #ruby
[18:26:21] weaksauce: has joined #RubyOnRails
[22:17:48] weaksauce: Ping timeout: 252 seconds
[23:33:34] weaksauce: has joined #ruby
[23:33:58] weaksauce: has joined #RubyOnRails

2018-10-08

[03:47:55] weaksauce: Ping timeout: 268 seconds
[04:01:17] weaksauce: has joined #ruby
[04:01:27] weaksauce: has joined #RubyOnRails

2018-10-04

[02:41:29] weaksauce: has joined #ruby
[02:41:37] weaksauce: has joined #RubyOnRails

2018-10-03

[16:52:13] weaksauce: Quit: My MacBook Pro has gone to sleep. ZZZzzz…
[18:31:07] weaksauce: has joined #ruby
[18:31:41] weaksauce: has joined #RubyOnRails
[20:43:38] weaksauce: Read error: Connection reset by peer

2018-09-20

[00:16:59] weaksauce: has joined #RubyOnRails
[00:17:14] weaksauce: has joined #ruby

2018-09-19

[00:27:28] weaksauce: has joined #ruby
[00:27:38] weaksauce: has joined #RubyOnRails
[18:32:51] weaksauce: Quit: My MacBook Pro has gone to sleep. ZZZzzz…
[19:48:19] weaksauce: has joined #RubyOnRails
[19:48:56] weaksauce: has joined #ruby
[21:33:52] weaksauce: Ping timeout: 272 seconds

2018-09-18

[00:53:29] weaksauce: has joined #RubyOnRails
[00:53:48] weaksauce: has joined #ruby
[16:59:36] weaksauce: Quit: My MacBook Pro has gone to sleep. ZZZzzz…
[18:20:54] weaksauce: has joined #ruby
[18:21:08] weaksauce: has joined #RubyOnRails
[19:02:09] weaksauce: Ping timeout: 252 seconds
[21:04:05] weaksauce: has joined #ruby
[21:04:21] weaksauce: has joined #RubyOnRails
[22:31:34] weaksauce: Ping timeout: 240 seconds

2018-09-17

[21:59:57] weaksauce: has joined #RubyOnRails
[22:00:09] weaksauce: has joined #ruby
[23:57:08] weaksauce: Ping timeout: 245 seconds

2018-09-15

[04:53:46] weaksauce: Ping timeout: 246 seconds

2018-09-13

[02:26:33] weaksauce: has joined #RubyOnRails
[02:26:41] weaksauce: has joined #ruby

2018-09-12

[02:09:40] weaksauce: Ping timeout: 272 seconds
[20:12:54] weaksauce: has joined #ruby
[20:13:12] weaksauce: has joined #RubyOnRails
[20:47:18] weaksauce: Ping timeout: 264 seconds

2018-09-11

[22:12:17] weaksauce: has joined #ruby
[22:12:25] weaksauce: has joined #RubyOnRails

2018-09-06

[23:03:07] weaksauce: Read error: Connection reset by peer

2018-09-04

[19:14:38] weaksauce: has joined #RubyOnRails
[19:14:46] weaksauce: has joined #ruby

2018-08-29

[23:47:14] weaksauce: Read error: Connection reset by peer

2018-08-22

[00:13:45] weaksauce: has joined #RubyOnRails
[00:13:51] weaksauce: has joined #ruby
[17:06:44] weaksauce: Read error: Connection reset by peer

2018-08-21

[23:42:09] weaksauce: Read error: Connection reset by peer

2018-08-20

[15:19:41] weaksauce: Ping timeout: 244 seconds
[19:18:50] weaksauce: has joined #ruby
[19:19:04] weaksauce: has joined #RubyOnRails
[21:30:45] weaksauce: try rubular
[21:31:06] weaksauce: http://rubular.com/
[21:32:28] weaksauce: http://rubular.com/r/m1NPiK54yD
[21:33:33] weaksauce: seems like a pretty permissive match though
[21:37:06] weaksauce: what are you trying to match on?
[21:37:38] weaksauce: is there something more useful to act as boundary conditions?
[21:45:06] weaksauce: it should work for both of those
[21:45:51] weaksauce: http://rubular.com/r/Spe7AJbJmr
[21:45:56] weaksauce: not really no
[21:46:20] weaksauce: does the second example actually have whitespace around the numbers?
[21:46:38] weaksauce: your regex is expecting whitespace before and after the numbers
[21:47:15] weaksauce: can you share what you are actually matching against and not example?

2018-08-19

[20:59:48] weaksauce: what does your lib do that a few basic functions wouldn't do nofxx
[21:00:08] weaksauce: i've done some industrial process engineering and it's a pretty simple algorithm
[21:34:03] weaksauce: i'd end up using no derivative term a lot of the time
[21:37:31] weaksauce: nofxx you just translating that cpp code into ruby?
[21:37:41] weaksauce: any anti-windup features?
[21:44:41] weaksauce: there are a few other forms that you can use too instead of the naive variant
[21:45:15] weaksauce: the velocity method is nicer to tweak and tune
[21:45:20] weaksauce: http://www.infoplc.net/files/descargas/rockwell/infoplc_net_logix_wp008_en_p_.pdf
[21:45:27] weaksauce: there are a few different equations in there

2018-08-18

[22:21:59] weaksauce: BigDecimal is one option if you need precision
[22:22:50] weaksauce: a general solution to that is to use integers and convert it to two decimal places when needed
[22:23:04] weaksauce: floats are not accurate for money
[22:23:46] weaksauce: but bigdecimal is
[22:24:37] weaksauce: but i wouldn't use it for that. i would store it as an integer and convert when needed
[22:26:29] weaksauce: there are some values that floats simply cannot handle and round. it really depends.
[22:26:51] weaksauce: https://ruby-doc.org/stdlib-2.5.1/libdoc/bigdecimal/rdoc/BigDecimal.html
[22:27:02] weaksauce: you can see why in that first example
[22:27:09] weaksauce: er second example
[22:30:09] weaksauce: if it's just for a game without precision worries you can get away with it
[23:23:20] weaksauce: RedNifre what are you actually trying to accomplish?
[23:23:33] weaksauce: oh nevermind.
[23:40:32] weaksauce: oh i just misread your question
[23:42:10] weaksauce: glad it's working!

2018-08-10

[18:22:03] weaksauce: Ping timeout: 244 seconds
[18:46:33] weaksauce: has joined #RubyOnRails
[18:47:02] weaksauce: has joined #ruby

2018-08-04

[08:25:36] weaksauce: Ping timeout: 244 seconds

2018-08-03

[18:09:46] weaksauce: has joined #RubyOnRails
[18:10:14] weaksauce: has joined #ruby

2018-08-02

[20:40:24] weaksauce: Quit: Textual IRC Client: www.textualapp.com
[20:44:44] weaksauce: has joined #ruby
[20:45:04] weaksauce: has joined #RubyOnRails
[20:52:04] weaksauce: Quit: My MacBook Pro has gone to sleep. ZZZzzz…
[21:23:27] weaksauce: has joined #ruby
[21:23:53] weaksauce: has joined #RubyOnRails
[21:25:11] weaksauce: Client Quit

2018-08-01

[18:35:12] weaksauce: Quit: Textual IRC Client: www.textualapp.com
[18:37:10] weaksauce: has joined #RubyOnRails
[18:37:20] weaksauce: has joined #ruby

2018-07-26

[00:32:34] weaksauce: Quit: Textual IRC Client: www.textualapp.com
[00:45:54] weaksauce: has joined #RubyOnRails
[00:46:26] weaksauce: has joined #ruby
[06:05:05] weaksauce: Ping timeout: 240 seconds
[18:23:50] weaksauce: has joined #RubyOnRails
[18:24:10] weaksauce: has joined #ruby

2018-07-25

[06:10:54] weaksauce: Ping timeout: 260 seconds
[17:52:09] weaksauce: has joined #RubyOnRails
[17:52:09] weaksauce: has joined #ruby

2018-07-24

[01:00:15] weaksauce: has joined #ruby
[01:00:43] weaksauce: has joined #RubyOnRails

2018-07-23

[11:07:29] weaksauce: Ping timeout: 276 seconds

2018-07-20

[18:19:39] weaksauce: has joined #ruby
[18:19:51] weaksauce: has joined #RubyOnRails