« Back to channel list

#ruby - 17 February 2019

« Back 1 day Forward 1 day »
[00:07:24] ricer2: has joined #ruby
[00:11:16] donofrio: has joined #ruby
[00:36:06] scrptktty: has joined #ruby
[00:49:30] x77686d: has joined #ruby
[00:52:25] jcarl43: has joined #ruby
[00:54:29] my1es: has joined #ruby
[00:58:16] hotpancakes: has joined #ruby
[01:18:34] my1es: has joined #ruby
[01:37:48] Swyper: has joined #ruby
[01:45:16] Nicmavr: has joined #ruby
[01:59:21] ogres: has joined #ruby
[02:13:35] x77686d: has joined #ruby
[02:26:54] hotpancakes: has joined #ruby
[02:38:24] ur5us: has joined #ruby
[02:40:46] dbugger_: has joined #ruby
[03:01:50] hotpancakes: has joined #ruby
[03:05:34] ByronJohnson: has joined #ruby
[03:51:09] _whitelogger: has joined #ruby
[04:10:37] braincrash: has joined #ruby
[04:39:26] DTZUZO_: has joined #ruby
[05:00:36] segy: has joined #ruby
[05:08:14] hotpancakes: has joined #ruby
[05:17:33] cd: has joined #ruby
[05:18:33] TheSpectre: has joined #ruby
[05:56:08] tdy1: has joined #ruby
[06:01:56] rippa: has joined #ruby
[06:12:56] maryo: has joined #ruby
[06:33:30] hotpancakes: has joined #ruby
[06:45:10] _whitelogger: has joined #ruby
[06:53:16] ddffg: has joined #ruby
[07:42:31] rippa: has joined #ruby
[07:59:52] mikecmpbll: has joined #ruby
[08:07:25] apparition: has joined #ruby
[08:31:55] kapil____: has joined #ruby
[08:33:56] gix: has joined #ruby
[08:58:20] postmodern: has joined #ruby
[08:59:19] r3m: has joined #ruby
[09:01:05] hotpancakes: has joined #ruby
[09:01:20] phaul: has joined #ruby
[09:14:53] blackmesa: has joined #ruby
[09:47:14] conta: has joined #ruby
[09:50:18] phaul: https://www.codeconquest.com/coding-quizzes/ruby-knowledge-quiz/
[09:51:09] phaul: it's really cr*p.
[09:51:50] phaul: What is the name of the element that is used to define what an object looks like after it is created?
[09:57:30] lxsameer: has joined #ruby
[09:58:00] evdubs_: has joined #ruby
[10:12:48] hightower2: has joined #ruby
[10:13:31] hightower2: Hey how do I run a regex match and return result in one go? Like var = 'value'.match '(regex)'
[10:14:02] phaul: String#[] takes regex
[10:14:22] phaul: &>> 'hightower2'[/to./]
[10:14:25] rubydoc: # => "tow" (https://carc.in/#/r/69yk)
[10:15:26] hightower2: Pretty cool, thanks phage
[10:25:39] ravenousmoose[aw: has joined #ruby
[10:27:14] hiroaki: has joined #ruby
[10:31:15] ravenousmoose[aw: has joined #ruby
[10:32:26] Fernando-Basso: has joined #ruby
[10:40:34] mikecmpbll: has joined #ruby
[10:43:41] ravenousmoose: has joined #ruby
[10:44:58] nemesit|znc: has joined #ruby
[10:47:29] cd: has joined #ruby
[10:54:36] wolfshappen_: has joined #ruby
[11:02:19] hotpancakes: has joined #ruby
[11:12:43] conta: has joined #ruby
[11:57:47] Inline: has joined #ruby
[12:33:20] aqd: has joined #ruby
[12:35:27] markoong: has joined #ruby
[12:38:30] aqd: has joined #ruby
[12:48:56] AJA4350: has joined #ruby
[13:06:41] wolfshappen: has joined #ruby
[13:16:10] hotpancakes: has joined #ruby
[13:17:19] Dbugger: has joined #ruby
[13:26:24] quipa: has joined #ruby
[13:37:04] maryo: has joined #ruby
[13:57:56] conta: has joined #ruby
[14:00:36] segy: has joined #ruby
[14:06:11] _whitelogger: has joined #ruby
[14:19:15] lucasb: has joined #ruby
[14:27:34] hotpancakes: has joined #ruby
[14:30:16] maryo_: has joined #ruby
[14:49:09] \13k: has joined #ruby
[14:57:22] Pillus: has joined #ruby
[15:15:46] hotpancakes: has joined #ruby
[15:20:25] dellavg__: has joined #ruby
[15:28:00] orbyt_: has joined #ruby
[15:30:09] hotpancakes: has joined #ruby
[15:36:27] cow[moo]: has joined #ruby
[15:49:16] blackmesa: has joined #ruby
[15:55:28] DTZUZO: has joined #ruby
[16:05:30] tdy1: has joined #ruby
[16:18:33] al2o3-cr: has joined #ruby
[16:23:49] uplime: has joined #ruby
[16:32:00] jcarl43: has joined #ruby
[16:42:11] fanta7531: has joined #ruby
[16:57:01] clemens3_: has joined #ruby
[17:01:05] cow[moo]: has joined #ruby
[17:06:06] venmx: has joined #ruby
[17:14:54] houhoulis: has joined #ruby
[17:19:47] blackmesa: has joined #ruby
[17:20:51] Tempesta: has joined #ruby
[17:22:52] blackmesa1: has joined #ruby
[17:43:43] cow[moo]: has joined #ruby
[17:59:20] foxxx0: has joined #ruby
[18:02:21] akem: has joined #ruby
[18:06:33] blackmesa1: has joined #ruby
[18:17:25] catbusters: has joined #ruby
[18:24:21] cow[moo]: has joined #ruby
[18:35:34] govg: has joined #ruby
[18:52:43] moei: has joined #ruby
[18:53:53] djuber: has joined #ruby
[18:56:46] conta: has joined #ruby
[19:05:57] wolfshappen_: has joined #ruby
[19:11:54] Nexos: has joined #ruby
[19:12:24] Nexos: I installed ruby 2.5.3-1 (x64) on windows with ruby+devkit, but when I launch irb, as soon as I try to enter a non-ascii (say é), it doesn't work anymore (any further input is not shown, Enter works)
[19:12:25] Nexos: Any idea why? (win10, console is in UTF-8 with chcp 65001 ; setting LANG variable to xx_YY.UTF-8 doesn't help)
[19:12:55] hansol: has joined #ruby
[19:14:02] hansol: I have created : rails new IndexEngine
[19:14:36] hansol: then : bin/rails server
[19:15:35] hansol: opening it : http://web.hayknews.com/ -- i got error page
[19:15:38] hansol: Pleae check it
[19:17:12] my1es: has joined #ruby
[19:19:29] hansol: where im wrong ?
[19:26:34] keanny479: has joined #ruby
[19:26:58] keanny479: I use OpenBSD system
[19:27:04] keanny479: there's a bug with PTY
[19:27:21] keanny479: unable to open master/slave
[19:27:38] keanny479: What can i do ?
[19:32:20] Joufflu: has joined #ruby
[19:35:06] \void: has joined #ruby
[19:39:32] dviola: has joined #ruby
[19:46:43] phaul: hansol: you are not connected to the database
[20:05:59] hansol: phaul i that
[20:06:43] phaul: I see. Yay! You’re on Rails! :)
[20:07:44] hansol: error was from sqlite3_adapter.rb
[20:08:11] orbyt_: has joined #ruby
[20:08:12] hansol: added gem "sqlite3", "~> 1.4.0"
[20:16:08] hansol: rails generate active_admin:install
[20:16:31] hansol: Could not find generator 'active_admin:install'. Maybe you meant 'active_record:model', 'active_record:migration' or 'test_unit:system'
[20:20:35] clemens3_: has joined #ruby
[20:29:28] jcarl43: has joined #ruby
[20:32:49] akem: has joined #ruby
[20:33:34] sticaz: has joined #ruby
[20:39:30] Joufflu: has joined #ruby
[20:48:14] hansol: remote: git://github.com/activeadmin/activeadmin.git
[20:48:14] hansol: revision: 81537db3610797fbe69067d2b15a96d75d543305
[20:48:39] hansol: i have this error:
[20:48:44] hansol: rb:235:in `allowed_in_path': The git source https://github.com/activeadmin.git is not yet checked out. Please run `bundle install` before trying to start your application (Bundler::GitError)
[20:50:42] ua: has joined #ruby
[20:55:38] icarus: has joined #ruby
[20:57:20] cow[moo]: has joined #ruby
[21:01:32] hansol: afther i made change to my Gemfile.lock
[21:02:16] hansol: i run bundle install, but its loading old Gemfile not new changed what must i do to reload Gemfile.lock ?
[21:07:48] orbyt_: has joined #ruby
[21:10:16] AJA4350: has joined #ruby
[21:11:51] TvL2386: has joined #ruby
[21:13:07] dviola: has joined #ruby
[21:22:14] remi: has joined #ruby
[21:23:29] hansol: remote: git://github.com/activeadmin/activeadmin.git
[21:23:29] hansol: revision: 0a5a15b88bffbe5efad7ff2a072ec4fe6eb09511
[21:23:36] hansol: this two lines are correct ?
[21:26:34] spacesuitdiver: has joined #ruby
[21:44:18] akem: has joined #ruby
[21:48:23] nowhere_man: has joined #ruby
[21:49:22] blackmesa1: has joined #ruby
[21:58:16] akem: has joined #ruby
[21:58:54] dmwit: has joined #ruby
[22:03:43] my1es: has joined #ruby
[22:17:04] valadares: has joined #ruby
[22:17:10] AJA4351: has joined #ruby
[22:23:16] cow[moo]: has joined #ruby
[22:30:46] akem: has joined #ruby
[22:31:08] spacesuitdiver: has joined #ruby
[23:08:26] rubydoc: has joined #ruby
[23:16:15] dmwit: I'd like to represent infinite streams, and have a way for multiple consumers to cleanly iterate over them independently. I've got something working, but the approach I took feels like I'm forcing my Python-based thoughts into Ruby (it uses iterators).
[23:16:21] dmwit: A small example is here: https://pastebin.com/ujvsLseA
[23:16:22] ruby[bot]: dmwit: we in #ruby do not like pastebin.com, it loads slowly for most, has ads which are distracting and has terrible formatting. Please use https://gist.github.com
[23:17:12] dmwit: Okay, a small example is also here: https://gist.github.com/dmwit/6e4af9138bd96729d4b746a127aa21f6
[23:17:23] dmwit: I'd love to hear any suggestions about how a more idiomatic version would look.
[23:18:19] jcalla: has joined #ruby
[23:18:24] code_zombie: has joined #ruby
[23:18:51] dmwit: (esp. if there's a library that already does this)
[23:23:47] AJA4351: has joined #ruby
[23:36:10] phaul: dmwit: this looks interesting. Are you familiar with the Enumerator class?
[23:37:06] phaul: Iterator looks quite similar to Enumerator as far as the interfaces go
[23:43:05] dmwit: I'm having a look now.
[23:43:14] phaul: &ri Enumerator
[23:43:14] rubydoc: https://ruby-doc.org/core-2.6/Enumerator.html
[23:43:40] phaul: they can represent infinite streams, lazily:
[23:44:13] phaul: &>> Enumerator.new { |y| loop { y << 1 } }.take 10
[23:44:17] rubydoc: # => [1, 1, 1, 1, 1, 1, 1, 1, 1, 1] (https://carc.in/#/r/6a3x)
[23:44:27] phaul: notice how the loop is an infinite loop
[23:45:33] dmwit: Huh. I don't know loop.
[23:45:42] rubydoc: https://ruby-doc.org/core-2.6/Kernel.html#method-i-loop
[23:45:48] phaul: it's just while true
[23:48:02] dmwit: Hm. It doesn't seem like you can "restart" an Enumerator, though, which my Stream+Iterator can do.
[23:48:44] dmwit: Ah, I think I understand what you're proposing.
[23:49:16] dmwit: You're not proposing replacing both, just Iterator, and so Stream.iterator (which I guess now that I understand the suggestion I should call Stream.each) would return an Enumerator.
[23:49:28] dmwit: Does that sound like what you've got in mind?
[23:50:26] phaul: hm. I haven't got that far :) I was just observing and pointing out similarities between your stuff and stuff that's there :D
[23:51:51] dmwit: thanks =)
[23:52:17] phaul: but since you mentioned "infinite streams" I immediately thought of Enumerators and lazyness. because they use fibers internally, and without those you can't afaik replicate lazy behaviour. the infinite loop with strict evaluation will be infinite
[23:55:00] dmwit: Ah well, you can always get lazy behavior with some pain by exploiting the fact that you don't evaluate a function's body when evaluating the function itself (only when calling it).
[23:55:17] dmwit: That's the trick I'm currently exploiting in Stream.
[23:55:37] dmwit: But I'll take a look at what fibers are, too, for good measure.