Pupeno

Activity Graph

Page 1 of 14 | Next »

2019-01-28

[06:07:34] Pupeno: Remote host closed the connection

2019-01-27

[17:11:03] Pupeno: has joined #RubyOnRails
[17:12:23] Pupeno: I'm converting a project from MySQL to PostgreSQL. After configuring it, I get the error: ActiveRecord::ConnectionTimeoutError: could not obtain a connection from the pool within 5.000 seconds (waited 5.000 seconds); all pooled connections were in use. I tried increasing the pool to 50. Another rails project on the same machine uses postgresql just fine. Any ideas what might be going ?
[17:34:24] Pupeno: havenwood: this is happening during rake db:migrate or rake db:create, so, I'm not sure the web server would have any effect, would it?
[17:34:58] Pupeno: I am using puma though.
[17:36:23] Pupeno: What do you mean by test worker?
[17:37:22] Pupeno: This project uses delayed jobs.
[17:37:28] Pupeno: No sidekiq as far as I can se.
[17:37:31] Pupeno: Rails 5.1.x
[17:42:53] Pupeno: Found the problem. By an error in database.yml, the pool size ended up being 0.
[17:44:07] Pupeno: _facepalm_ sorry guys.

2018-10-04

[07:48:56] Pupeno: has joined #ruby
[07:49:18] Pupeno: Are there any guides about how to build Ruby on Windows?
[08:33:41] Pupeno: What do you mean by without changing the parameters?
[08:35:15] Pupeno: If you are overriding the method you are changing the behaviour of the method. Are you trying to wrap an existing method with your own functionality?
[08:36:43] Pupeno: I'm sorry, I was thinking of replacing the method, not overriding.
[08:37:38] Pupeno: I don't think it's possible to define a method with def and have it have the same arguments as the one in the parent class.
[08:38:48] Pupeno: In Ruby you can do pretty much whatever you want, so, you can write class Object; def to_s; end; end and re-define the the to_s method in the Object class.
[08:39:33] Pupeno: Yes, you can inspect the method in the parent class, find how many arguments it has, and create a new method with the same amount of arguments, but I don't think this is worthy.
[08:40:02] Pupeno: What I just described with Object is not inheritance, it's opening up an existing class and modifying it.
[08:40:57] Pupeno: No. There's no inheritance at play there. The moment you do that, every object in the system will have a new implementation of that method IIRC.
[08:41:23] Pupeno: Inheritance would doing class MyClass < Object ; def to_s....
[08:41:40] Pupeno: So there's a class called MyClass with a to_s method.
[08:42:24] Pupeno: It is redefining to_s for that class, yes. It's called monkey-patching and it's generally frowned upon because it's messy and dangerous.
[08:42:59] Pupeno: You can completely ignore it... I just missinterpreted your question as you doing monkey-patching, instead of proper inheritance overriding.
[08:44:45] Pupeno: Why are you trying to preserve the amount of arguments?
[08:45:53] Pupeno: Why not just hard-code the argument and argument names to match the parent's class's method?
[08:47:34] Pupeno: Yeah, that's what I thought. I see your point.
[08:48:31] Pupeno: If you get *args and then pass it to the method, and it doesn't match the new amount of arguments, do you get an error that's hard to understand? I can't remember.
[08:50:36] Pupeno: Another possibilty is to check, on-load-time, whether the amount of arguments of the parent class is what you expected when writing your code, and if it's not, fail to load your class with a descriptive error message about tweaking the class. Not the same as matching the parent method.
[08:50:54] Pupeno: It's possible there's another solution that I'm forgetting about. I just came back to Ruby after a while.
[09:14:34] Pupeno: This channel seems very quiet compared to other programming languages. Are Rubists hanging out somewhere else?
[09:15:42] Pupeno: has joined #RubyOnRails
[09:18:27] Pupeno: zenspider: take a look at #python, 2am pacific time and it's busting with activity.
[09:19:20] Pupeno: I know the Python community is biggen than Ruby, but the discrepancy in activity seems bigger, so, I'm wondering if people moved to Slack or something.
[09:47:21] Pupeno: dogweather: I'd tend to agree. I prefer my testing code to be closer to just plain ruby code, hence not a fan of neither rspec nor shoulda-matchers. I do find that shoulda-context helps a lot with tests that have common parts. I'm a fan.
[21:31:32] Pupeno: Quit: Going offline, see ya! (www.adiirc.com)

2018-07-17

[23:46:33] Pupeno: Quit: Going offline, see ya! (www.adiirc.com)

2018-07-12

[14:18:14] Pupeno: has joined #RubyOnRails
[14:18:57] Pupeno: Can I expect the latest mysql2 gem, 0.5.2, to work with MySQL 5? I have MySQL 8 on my dev machine, but the server has MySQL 5.

2018-07-09

[10:47:21] Pupeno: I'm using Rails 5.2, I'm getting an error on CircleCI about Devise.secret_key not set. I set up the SECRET_KEY_BASE environment variable. What else am I missing?
[11:01:51] Pupeno: It's not defined. According to the comment: Devise will use the `secret_key_base` as its `secret_key` by default.
[11:06:16] Pupeno: Let me try printing it out to see if CircleCI is doing something weird.
[11:07:59] Pupeno: echo $SECRET_KEY_BASE shows the key, so, yes, it's set.
[11:11:49] Pupeno: Running: https://circleci.com/gh/dashmantech/modulator
[11:13:00] Pupeno: Failed for another reason, but yeah, if I hardcode it, the value is there.
[11:13:49] Pupeno: Nope, it works fine on my machine.
[11:14:48] Pupeno: Thank you tbuehlmann.
[23:24:28] Pupeno: Ping timeout: 240 seconds

2018-07-08

[05:39:26] Pupeno: has joined #ruby
[05:39:43] Pupeno: Can the # frozen_string_literal: true be on the second line of the file?
[11:45:29] Pupeno: has joined #RubyOnRails
[11:48:34] Pupeno: I'm trying to get webpacker working. I installed it and I have the application.js with the Hello World console.log; but somehowe, it doesn't end up in the compiled application.js. I am javascript_pack_tag it. What am I missing?
[11:51:37] Pupeno: The whole application is here: https://github.com/dashmantech/modulator
[14:42:29] Pupeno: How do I link to a route that looks like this (without naming it): get "/java_modules/:group_id/:artifact_id/:version", to: "java_modules#show" ?
[16:08:05] Pupeno: fryguy: as far as I see, no name: GET /java_modules/:group_id/:artifact_id/:version(.:format) java_modules#show
[16:12:15] Pupeno: How do I pass each of the items, group_id, artifact_id and version?
[16:12:28] Pupeno: just keyword arguments for url_for?
[16:14:13] Pupeno: Ah... yeah, that seems to work. Thank you fryguy.

2018-07-07

[11:41:45] Pupeno: Ping timeout: 264 seconds
[14:00:16] Pupeno: has joined #RubyOnRails
[14:01:14] Pupeno: I haven't done Rails in quite a while. Back in the day I was using Bootstrap. Is it still a good option with good integration? Or should I explore something else?
[14:12:15] Pupeno: Should I handle it with webpack? This project is not going to use React or any of the other big frameworks for JS. It's still going to have some Javascrip.t
[14:45:48] Pupeno: Remote host closed the connection

2018-07-06

[16:28:43] Pupeno: has joined #RubyOnRails
[16:29:14] Pupeno: How do you keep your development database credentials out of your database.yml (that is, out of the repo)?
[16:30:48] Pupeno: This: https://github.com/motdotla/dotenv ?
[16:32:11] Pupeno: Ah... no, I take it it's this: https://github.com/bkeepers/dotenv

2018-07-04

[17:58:06] Pupeno: Quit: Going offline, see ya! (www.adiirc.com)

2018-07-03

[08:32:00] Pupeno: has joined #RubyOnRails
[08:32:45] Pupeno: What's a good way of testing the performance of Ruby and Rails on Windows to see how good or bad is this days and to compare using the Linux subsystem vs the native installer?
[09:05:58] Pupeno: sylario: I'm not using Windows in production. And last time I tested, which each request taking between 4 and 10 seconds, speed was a problem. Developing in Windows was unbearable.
[09:10:33] Pupeno: PostgreSQL is fine. I have postgresql installed and I'm using it for non-ruby projects.
[09:13:20] Pupeno: Last time I tried native Ruby on Windows, Ruby on the Windows Subsystem for Linux, and Ruby in a VM. They were all horribly slow due to I/O speed; even on my Intel 750 PCIe.
[10:11:45] Pupeno: sylario: yes, most likely, although it seems the way Ruby and Rails do IO to be the source of a lot of problems.
[15:31:20] Pupeno: I added a comments sub resource to post, and I ended up with this route: post_comments GET /posts/:post_id/comments(.:format) comments#show. Why is it show and not index? Why is there no single comment show route either? Is this new?
[15:38:08] Pupeno: No, I don't think it's shallow: https://gist.github.com/pupeno/1934d4faedede5c622a50b474f16ce26
[15:38:24] Pupeno: Also, I don't have /comments/:id, which would be what a shallow route would provide.
[15:51:46] Pupeno: Found the problem. I was using singular instead of plural, resource vs resources for the nested resource.
[16:17:34] Pupeno: Does anybody have an idea on how to test the current viability of developing Rails on Windows? performance seems to have improved since the last time I tried it, but I'm open to anything that would help me push my set up harder. Any popular gems that are hard to build?
[16:23:08] Pupeno: sylario: every time I tried running it in a VM it was clunky as hell (no way to run it from RubyMine, debug it, etc) and not faster than native thanks to I/O transaltion.
[16:24:26] Pupeno: Right now I'm not interesting in setting up Ruby differently but testing whether the native Ruby and Rails would work well enough to take some contract work without having to go and get a mac (or having to dual boot).
[16:24:57] Pupeno: sylario: I was using a VM without running X.
[16:26:44] Pupeno: sylario: when they released the last interation of mbp, instead of buying one, I spent the same amount building a beast of a desktop. I got annoyed enough at Apple and I'd rather stay away from Macs.
[16:27:27] Pupeno: I need some contract work to keep me going while I market my startup, so, I'm exploring doing some Ruby and Rails, if not, I'll stay in the Clojure world, but there's way more work in RoR rather than Clojure.
[16:34:03] Pupeno: sylario: I have an intel 720 PCIe. Not big enough for dual boot. I do need some of the "distractions" and I don't want to deal with the small idiosyncrasis of getting used to a different UI. If I have to put up with that, I'd rather do Clojure (or Python or whatever).
[16:49:39] Pupeno: What's the ImageMagick gem that uses the C library (instead of command line) that tends to be tricky to get working?
[16:58:03] Pupeno: Oh, I think it's rmagick.
[16:58:09] Pupeno: I'll try installing those two as well.
[17:17:04] Pupeno: Is it possible to install pg and nokogiri building the extensions locally?

2018-07-01

[10:07:14] Pupeno: Quit: Going offline, see ya! (www.adiirc.com)

2018-06-30

[22:05:51] Pupeno: has joined #RubyOnRails
[22:06:33] Pupeno: Is Ruby/Rails still unusable on Windows?
[22:06:48] Pupeno: I haven't tried it on Windows for a few years.
[22:30:19] Pupeno: One hopes so?

2016-07-30

[00:21:24] Pupeno: Remote host closed the connection
[00:29:14] Pupeno: has joined #ruby
[00:29:14] Pupeno: has joined #RubyOnRails
[00:29:14] Pupeno: Changing host
[00:29:14] Pupeno: has joined #RubyOnRails
[00:29:14] Pupeno: has joined #ruby
[02:32:03] Pupeno: Quit: Leaving...
[10:28:49] Pupeno: has joined #RubyOnRails
[10:28:49] Pupeno: has joined #ruby
[10:46:24] Pupeno: Quit: Leaving...

2016-07-29

[18:06:27] Pupeno: has joined #ruby
[18:06:27] Pupeno: has joined #RubyOnRails
[18:06:27] Pupeno: Changing host
[18:06:27] Pupeno: has joined #RubyOnRails
[18:06:27] Pupeno: has joined #ruby
[20:16:55] Pupeno: Remote host closed the connection
[23:31:16] Pupeno: has joined #RubyOnRails
[23:31:16] Pupeno: has joined #ruby

2016-07-27

[07:47:15] Pupeno: has joined #RubyOnRails
[07:47:15] Pupeno: has joined #ruby
[07:56:50] Pupeno: Quit: Leaving...
[08:41:29] Pupeno: has joined #RubyOnRails
[08:41:29] Pupeno: has joined #ruby
[10:36:05] Pupeno: Ping timeout: 258 seconds
[10:38:27] Pupeno: has joined #ruby
[10:38:28] Pupeno: has joined #RubyOnRails
[10:39:17] Pupeno: Remote host closed the connection
[11:10:27] Pupeno: has joined #ruby
[11:10:28] Pupeno: has joined #RubyOnRails
[11:17:52] Pupeno: Ping timeout: 264 seconds
[11:53:08] Pupeno: has joined #RubyOnRails
[11:53:08] Pupeno: has joined #ruby
[12:10:29] Pupeno: Ping timeout: 244 seconds
[14:27:42] Pupeno: has joined #RubyOnRails
[14:27:42] Pupeno: has joined #ruby
[14:40:47] Pupeno: Remote host closed the connection
[15:01:53] Pupeno: has joined #RubyOnRails
[15:01:53] Pupeno: has joined #ruby
[15:38:06] Pupeno: Remote host closed the connection
[15:59:02] Pupeno: has joined #RubyOnRails
[15:59:02] Pupeno: has joined #ruby
[16:03:39] Pupeno: Ping timeout: 276 seconds
[16:29:39] Pupeno: has joined #RubyOnRails
[16:29:39] Pupeno: has joined #ruby
[16:33:57] Pupeno: Ping timeout: 244 seconds
[17:04:42] Pupeno: has joined #RubyOnRails
[17:04:42] Pupeno: has joined #ruby
[17:45:39] Pupeno: Remote host closed the connection
[18:31:28] Pupeno: has joined #ruby
[18:31:29] Pupeno: has joined #RubyOnRails
[19:15:33] Pupeno: Remote host closed the connection
[19:41:13] Pupeno: has joined #RubyOnRails
[19:41:13] Pupeno: has joined #ruby
[19:44:48] Pupeno: Remote host closed the connection
[21:01:43] Pupeno: has joined #RubyOnRails
[21:01:43] Pupeno: has joined #ruby
[21:01:46] Pupeno: Remote host closed the connection

2016-07-26

[13:06:37] Pupeno: has joined #RubyOnRails
[13:06:37] Pupeno: has joined #ruby
[13:09:21] Pupeno: Remote host closed the connection
[13:31:53] Pupeno: has joined #RubyOnRails
[13:31:53] Pupeno: has joined #ruby
[13:38:27] Pupeno: Remote host closed the connection
[14:03:37] Pupeno: has joined #RubyOnRails
[14:03:37] Pupeno: has joined #ruby
[14:05:22] Pupeno: Remote host closed the connection
[14:23:30] Pupeno: has joined #ruby
[14:23:30] Pupeno: has joined #RubyOnRails
[14:23:30] Pupeno: Changing host
[14:23:30] Pupeno: has joined #RubyOnRails
[14:23:30] Pupeno: has joined #ruby
[14:34:44] Pupeno: Remote host closed the connection
[15:17:53] Pupeno: has joined #RubyOnRails
[15:17:53] Pupeno: has joined #ruby
[15:24:05] Pupeno: Remote host closed the connection
[15:44:00] Pupeno: has joined #RubyOnRails
[15:44:00] Pupeno: has joined #ruby
[16:07:52] Pupeno: Remote host closed the connection
[16:17:03] Pupeno: has joined #RubyOnRails
[16:17:03] Pupeno: has joined #ruby
[16:21:47] Pupeno: Ping timeout: 250 seconds
[16:22:31] Pupeno: has joined #ruby
[16:22:31] Pupeno: has joined #RubyOnRails
[16:22:31] Pupeno: Changing host
[16:22:31] Pupeno: has joined #RubyOnRails
[16:22:31] Pupeno: has joined #ruby
[16:24:53] Pupeno: Remote host closed the connection
[16:26:17] Pupeno: has joined #RubyOnRails
[16:26:17] Pupeno: has joined #ruby
[16:29:22] Pupeno: Remote host closed the connection
[18:38:17] Pupeno: has joined #RubyOnRails
[18:38:17] Pupeno: has joined #ruby
[19:44:48] Pupeno: Remote host closed the connection
[19:57:58] Pupeno: has joined #RubyOnRails
[19:57:58] Pupeno: has joined #ruby
[20:37:21] Pupeno: Remote host closed the connection
[20:38:29] Pupeno: has joined #RubyOnRails
[20:38:29] Pupeno: has joined #ruby
[20:43:05] Pupeno: Ping timeout: 240 seconds
[21:08:07] Pupeno: has joined #RubyOnRails
[21:08:07] Pupeno: has joined #ruby
[21:42:28] Pupeno: Ping timeout: 264 seconds
[22:34:17] Pupeno: has joined #RubyOnRails
[22:34:17] Pupeno: has joined #ruby
[22:34:55] Pupeno: Remote host closed the connection

2016-07-24

[09:57:30] Pupeno: has joined #RubyOnRails
[09:57:30] Pupeno: has joined #ruby
[11:17:39] Pupeno: Remote host closed the connection
[11:30:45] Pupeno: has joined #RubyOnRails
[11:30:45] Pupeno: has joined #ruby
[11:43:58] Pupeno: Remote host closed the connection
[12:54:39] Pupeno: has joined #RubyOnRails
[12:54:39] Pupeno: has joined #ruby
[13:00:11] Pupeno: Ping timeout: 240 seconds
[13:09:24] Pupeno: has joined #ruby
[13:10:44] Pupeno: has joined #RubyOnRails
[13:24:38] Pupeno: Remote host closed the connection
[13:55:34] Pupeno: has joined #RubyOnRails
[13:55:34] Pupeno: has joined #ruby
[13:59:53] Pupeno: Remote host closed the connection
[14:20:25] Pupeno: has joined #ruby
[14:20:28] Pupeno: has joined #RubyOnRails
[14:23:24] Pupeno: Remote host closed the connection

2016-07-23

[12:53:25] Pupeno: has joined #RubyOnRails
[12:53:25] Pupeno: has joined #ruby
[13:23:04] Pupeno: Ping timeout: 265 seconds
[13:32:20] Pupeno: has joined #RubyOnRails
[13:32:20] Pupeno: has joined #ruby
[19:38:58] Pupeno: Remote host closed the connection
[19:39:29] Pupeno: has joined #ruby
[19:39:30] Pupeno: has joined #RubyOnRails
[19:40:30] Pupeno: Remote host closed the connection
[19:41:46] Pupeno: has joined #RubyOnRails
[19:41:46] Pupeno: has joined #ruby
[20:30:49] Pupeno: Remote host closed the connection
[20:48:45] Pupeno: has joined #RubyOnRails
[20:48:45] Pupeno: has joined #ruby
[21:20:14] Pupeno: Remote host closed the connection
[21:47:27] Pupeno: has joined #RubyOnRails
[21:47:27] Pupeno: has joined #ruby
[22:00:33] Pupeno: Remote host closed the connection
[22:13:50] Pupeno: has joined #RubyOnRails
[22:13:50] Pupeno: has joined #ruby
[22:33:51] Pupeno: Remote host closed the connection
[22:37:17] Pupeno: has joined #RubyOnRails
[22:37:17] Pupeno: has joined #ruby
[23:09:56] Pupeno: Read error: Connection timed out
[23:10:39] Pupeno: has joined #ruby
[23:10:39] Pupeno: has joined #RubyOnRails
[23:10:39] Pupeno: Changing host
[23:10:39] Pupeno: has joined #RubyOnRails
[23:10:39] Pupeno: has joined #ruby
[23:36:18] Pupeno: Remote host closed the connection