Activity Graph

Page 1 of 2 | Next »


[16:02:30] dostoyevsky: Quit: leaving
[16:07:33] dostoyevsky: has joined #ruby


[18:13:29] dostoyevsky: Quit: leaving
[18:13:41] dostoyevsky: has joined #ruby
[18:15:16] dostoyevsky: has joined #ruby


[18:23:17] dostoyevsky: Quit: leaving
[18:23:28] dostoyevsky: has joined #ruby


[21:04:31] dostoyevsky: Ping timeout: 252 seconds
[21:05:12] dostoyevsky: has joined #ruby
[21:10:07] dostoyevsky: Ping timeout: 246 seconds
[22:05:25] dostoyevsky: has joined #ruby


[08:45:09] dostoyevsky: Quit: leaving
[08:45:22] dostoyevsky: has joined #ruby
[08:47:10] dostoyevsky: has joined #ruby
[08:57:20] dostoyevsky: Quit: leaving
[08:57:53] dostoyevsky: has joined #ruby


[22:35:46] dostoyevsky: Quit: leaving
[22:37:10] dostoyevsky: has joined #ruby


[10:47:44] dostoyevsky: Ping timeout: 244 seconds
[10:48:58] dostoyevsky: has joined #ruby
[13:22:12] dostoyevsky: Quit: leaving
[13:22:24] dostoyevsky: has joined #ruby


[20:15:03] dostoyevsky: Ping timeout: 250 seconds
[20:22:53] dostoyevsky: has joined #ruby


[10:54:39] dostoyevsky: Ping timeout: 268 seconds
[10:55:16] dostoyevsky: has joined #ruby
[10:55:59] dostoyevsky: has joined #ruby
[11:02:21] dostoyevsky: Ping timeout: 258 seconds
[11:09:21] dostoyevsky: has joined #ruby


[12:07:25] dostoyevsky: irb crashes on me when I accidentally enter a character like โ‰ ยข which happens some times when I enter []{} ... I often spot my mistake and delete the character but irb will get an exception the next time I hit enter, as some residue of that character is still there somehow
[12:09:11] dostoyevsky: > /usr/local/lib/ruby/2.5/irb/ruby-lex.rb:721:in `block in lex_int2': invalid byte sequence in UTF-8 (ArgumentError)
[12:17:03] dostoyevsky: phaul: LC_CTYPE=en_US.UTF-8
[12:17:16] dostoyevsky: but a German keyboard...
[12:17:42] dostoyevsky: And readline in irb requires two backspace to delete โ‰ 
[12:17:57] dostoyevsky: if I only do one backspace, then I will get that UTF-8 error
[12:18:14] dostoyevsky: I tried irb -E UTF-8:UTF-8 and -U but it didn't help
[12:21:06] dostoyevsky: hmmm... I just tried python and there โ‰  also requires two backspace to be deleted...
[12:21:47] dostoyevsky: hmmmm... also works on my linux box...
[12:22:05] dostoyevsky: but not on the openbsd box...


[00:14:31] dostoyevsky: phaul: Yeah, ruby is the under dog again, almost like 8 years ago when I first used it :)


[12:20:47] dostoyevsky: > "((1) (2)) <- match until here )" # do ruby's regexpes have something that could keep track of the open vs closed parens count in a regular expression?
[12:25:52] dostoyevsky: I thought so too
[12:28:07] dostoyevsky: > "{{ab} {cd}}}".match(/(\(([^)(\]\[}{]+|\g<1>)*+\)|\[\g<2>*+\]|\{\g<2>*+\})/)
[12:28:21] dostoyevsky: but something like this actually matches as I want it...
[12:38:25] dostoyevsky: but because it's so easy to keep track I always wondered if regexpes couldn't just support it... and it seems they have done so for a while...
[12:58:09] dostoyevsky: In my case I want to match the parameter after a `\def command {{}}' and (\{([^{}]+|\g<2>)*+\}) just did the job
[12:58:28] dostoyevsky: (matching something out of a latex document)
[13:29:14] dostoyevsky: Quit: leaving
[13:29:28] dostoyevsky: has joined #ruby
[14:51:47] dostoyevsky: ruby on rails top3 of the most dreaded web frameworks in the stackoverflow survey... ruby is top-7 in the most dreaded languages... :-/
[16:49:56] dostoyevsky: *.net *.split


[15:13:33] dostoyevsky: I want to transform an array: [1, 2, 3, 4] -> [[1, 2],[3, 4]] # is there an easy way to do that?
[15:16:31] dostoyevsky: thanks phaul! :)


[07:17:07] dostoyevsky: Ping timeout: 245 seconds
[07:18:02] dostoyevsky: has joined #ruby
[23:18:13] dostoyevsky: Quit: leaving
[23:18:34] dostoyevsky: has joined #ruby


[21:04:58] dostoyevsky: > equations = []; t.gsub(%r{\\begin{equation}.*?\\end{equation}}m) {|m| equations.push(m) }
[21:05:33] dostoyevsky: is there a more idiomatic/correct way to match one regexp as much as possible and remember the results?


[20:20:03] dostoyevsky: Quit: leaving
[20:22:32] dostoyevsky: has joined #ruby


[13:26:28] dostoyevsky: Quit: leaving
[13:27:19] dostoyevsky: has joined #ruby


[10:55:09] dostoyevsky: > Exception `SyntaxError' at /home/sck/.gem/ruby/2.3.0/gems/method_source-0.9.0/lib/method_source/code_helpers.rb:71 - (eval):26: syntax error, unexpected end-of-input, expecting keyword_end
[10:55:31] dostoyevsky: pry tells me there is a syntax error in my code?
[10:55:52] dostoyevsky: how did it execute pry in the first place?


[19:04:37] dostoyevsky: Ping timeout: 240 seconds
[21:28:30] dostoyevsky: has joined #ruby


[00:34:46] dostoyevsky: Quit: leaving
[00:44:56] dostoyevsky: has joined #ruby


[00:27:18] dostoyevsky: Quit: leaving
[00:28:18] dostoyevsky: has joined #ruby


[09:28:30] dostoyevsky: Quit: leaving
[09:47:08] dostoyevsky: has joined #ruby
[10:21:48] dostoyevsky: Quit: leaving
[10:26:27] dostoyevsky: has joined #ruby
[18:37:57] dostoyevsky: Quit: leaving
[18:38:06] dostoyevsky: has joined #ruby


[06:00:16] dostoyevsky: Quit: leaving
[06:00:52] dostoyevsky: has joined #ruby


[00:03:34] dostoyevsky: has joined #ruby


[23:59:20] dostoyevsky: Quit: leaving


[22:11:03] dostoyevsky: Quit: leaving
[22:11:14] dostoyevsky: has joined #ruby


[19:41:22] dostoyevsky: Changing host
[19:41:23] dostoyevsky: has joined #ruby


[18:48:53] dostoyevsky: *.net *.split


[23:27:50] dostoyevsky: Read error: Connection reset by peer


[14:09:42] dostoyevsky: has joined #ruby
[14:10:38] dostoyevsky: Hi. Does jupyter have support to plot graphs etc via Ruby? I installed the Ruby kernel for jupyter, so I can use Ruby, but I am not sure how much more support there actually is
[14:15:15] dostoyevsky: balo: Thanks!


[12:48:59] dostoyevsky: *.net *.split


[00:07:27] dostoyevsky: *.net *.split
[00:15:52] dostoyevsky: has joined #ruby


[02:47:17] dostoyevsky: *.net *.split
[02:48:14] dostoyevsky: has joined #ruby


[12:26:00] dostoyevsky: *.net *.split
[12:27:25] dostoyevsky: has joined #ruby
[15:01:31] dostoyevsky: *.net *.split
[15:03:09] dostoyevsky: has joined #ruby


[17:03:56] dostoyevsky: Is rails less popular these days? I was surprised that there are more people on #ruby than on #rails
[17:05:51] dostoyevsky: I started using ruby in 2001 and never really had much of an interest in rails, which emerged around 2006... but it was impossible to get a job as a ruby programmer, people thought the only ruby was rails
[17:12:16] dostoyevsky: I learned many programming languages but never PHP, makes me kind of proud :)
[17:18:48] dostoyevsky: dionysus69: try ##programming


[00:01:51] dostoyevsky: > ASTBuilder > @parser_class and return_value = return_value.tree
[00:02:13] dostoyevsky: what does that ruby syntax mean? ASTBuilder <greater than> other_class
[13:49:39] dostoyevsky: I love ruby, but man, it is slow
[18:33:49] dostoyevsky: Is jupyter good to use with the ruby kernel?


[12:24:56] dostoyevsky: Does anyone know a project that uses antlr for ruby? I want to see how I can access the parsed data after calling my"string") ... documentation seems very sparse
[12:40:34] dostoyevsky: leitz: Are you using a SingletonFactoryForestRunForest to guard the book's visibility?


[18:21:31] dostoyevsky: > undefined method `type_suffix' for #<struct :"CommonTree type_suffix"=nil> (NoMethodError)
[18:22:01] dostoyevsky: I wonder what kind of struct data type antlr is using here
[18:30:27] dostoyevsky: apeiros: Yeah, thanks
[18:41:16] dostoyevsky: So it wasn't too hard after all to port that antlr parser from Java to ruby... :)
[18:41:43] dostoyevsky: (The grammar.g used Java syntax at places)


[10:40:42] dostoyevsky: I have a command pipleine like this, dealing with AWS instances: scp data server && ssh server "unpack data; run commands" && ssh server "setup configuration" && ssh server "run test cases" && ssh server "obtain results"
[10:41:34] dostoyevsky: But ssh/scp can fail in many ways, e.g. "lost connection" in ssh might not set the exit code to error... So I was wondering if there was some library for Ruby that would help me there
[10:42:17] dostoyevsky: essentially, the library should try to repeat steps when they fail
[13:21:39] dostoyevsky: ah, sshkit is part of capistrano... I thought that capistrano might be what I want


[02:03:57] dostoyevsky: has joined #ruby
[02:04:54] dostoyevsky: What's the best way to quote my filename if I want to: system "ls -ald #{Dir["*something*"][0]}" ?


[20:01:35] dostoyevsky: Quit: Lost terminal


[02:28:50] dostoyevsky: has joined #ruby


[01:28:18] dostoyevsky: has joined #ruby
[01:28:26] dostoyevsky: Max SendQ exceeded
[01:28:38] dostoyevsky: has joined #ruby


[16:16:32] dostoyevsky: Ping timeout: 248 seconds
[16:52:55] dostoyevsky: has joined #ruby


[18:21:31] dostoyevsky: Too many interesting channels...


[20:42:15] dostoyevsky: has joined #ruby
[20:42:35] dostoyevsky: Does Python have something similar to Ruby's Dir["*/somefile"].each {|filename| puts filename } ?
[20:45:43] dostoyevsky: Seems it's glob.glob something
[20:50:22] dostoyevsky: Papierkorb: I did.. they didn't grok ruby though in the beginning... so I asked here...


[16:07:06] dostoyevsky: Quit: leaving


[07:39:37] dostoyevsky: has joined #ruby
[07:40:45] dostoyevsky: I've ported some regular expression code (500 loc or regexpes) over to node.js and the code is now 200 times faster... :/
[07:43:30] dostoyevsky: xybre: "parsing" wiktionary data dumps
[07:46:43] dostoyevsky: hanmac: so your xml parser understands wikimedia commands?
[07:52:43] dostoyevsky: hanmac: I haven't... also not sure how fast it would be wiktionary dumps are usually around 3G... wikipedia dumps are like 20G per language
[07:58:59] dostoyevsky: the way I envision my design atm is that I parse everything roughly and save everything into a big sqlite db... so if I see parsing bugs later I only need to process those entries where the bugs are, if I can recognized them with an SQL query... and maybe even use wikicloth for certain things
[08:48:34] dostoyevsky: Does your oauth2 work with google or other more common providers?


[07:08:19] dostoyevsky: Quit: leaving


[11:39:31] dostoyevsky: I cannot gem install tokyocabinet with ruby2.3 ... does it not exist anymore?
[11:42:31] dostoyevsky: kyotocabinet even ...


[20:29:05] dostoyevsky: Ping timeout: 268 seconds


[22:05:10] dostoyevsky: Remote host closed the connection
[22:05:18] dostoyevsky: has joined #ruby


[17:13:46] dostoyevsky: has joined #ruby


[11:06:41] dostoyevsky: Ping timeout: 260 seconds


[11:37:06] dostoyevsky: Ping timeout: 264 seconds
[11:50:27] dostoyevsky: has joined #ruby


[23:36:59] dostoyevsky: hmmmm... there is no unicode symbol for batman... how are you supposed to call him when you need him?


[09:39:50] dostoyevsky: Ping timeout: 240 seconds


[11:05:36] dostoyevsky: Ping timeout: 276 seconds
[11:12:42] dostoyevsky: has joined #ruby
[11:49:30] dostoyevsky: Ping timeout: 246 seconds
[11:50:50] dostoyevsky: has joined #ruby
[12:22:26] dostoyevsky: Ping timeout: 244 seconds
[12:22:33] dostoyevsky: has joined #ruby


[15:58:50] dostoyevsky: >> /๐Ÿ˜Š{2}/.match('๐Ÿ˜Š๐Ÿ˜Š')
[15:58:58] dostoyevsky: ruby is so cool


[19:12:28] dostoyevsky: Not sure if that works yet :)
[19:12:56] dostoyevsky: I do not get why we need symbols like this in unicode, though


[00:33:06] dostoyevsky: has joined #ruby
[00:33:42] dostoyevsky: Hey, unicode question: is there an easy way to make ``"ะฐัะต" == "ace" '' return true in ruby?
[00:38:10] dostoyevsky: but shouldn't all unicode compliant systems also implement the normalization methods? NFC, NFD, NFKC, and NFKD? I am not sure if those two strings would be equal when nomalized under these methods, though
[00:41:11] dostoyevsky: for me they actually look the same... do they look different for anyone of you?
[00:42:05] dostoyevsky: yeah, the codepoints are different for sure..
[00:42:11] dostoyevsky: that that's what matters for ==
[00:42:36] dostoyevsky: apeiros: but I'd have to implement that myself, right?
[00:43:13] dostoyevsky:
[00:43:35] dostoyevsky: so many i :-/
[00:44:32] dostoyevsky: > Transliteration between cyrillic <-> latin ... hehe.. that solves 1% of all the unicode problems :)
[00:47:00] dostoyevsky: > tr39_confusables --- that might be a good ruby gem
[00:51:56] dostoyevsky: Ox0dea: yeah, one would e.g. need a gem that uses that file to make comparisons... still, these only include equality for characters that have the same width.. I am not sure if one could detect "Administator" == "Administrator" # where one of the strings e.g. has a zero width space...
[00:52:38] dostoyevsky: but tr39 also includes security checks so maybe that's the thing I want
[00:52:57] dostoyevsky: Ox0dea:
[00:53:38] dostoyevsky: Confusables doesn't list and other comma char for "ใ€ " even though I'd say , looks similar
[00:54:41] dostoyevsky: that's because confusables only assumes that characters with the same width can be confusable
[20:14:06] dostoyevsky: Is there something like bindin.pry that can also step through the ruby program from that binding.pry call?
[20:16:25] dostoyevsky: norc__: can I call pry-debugger from binding.pry?
[20:17:21] dostoyevsky: > pry-byebug adds next, step, finish, continue and break commands to pry using byebug.
[20:17:33] dostoyevsky: oh... seems great! thanks norc__ !
[20:19:38] dostoyevsky: norc__: is that missing any features from pry?
[22:53:30] dostoyevsky: Is ruby making any moves towards increasing performance? I am using a bit more node.js atm and everything seems quite fast by default..
[22:57:29] dostoyevsky: havenwood: ah, good to hear.. stil love the easyness of writing code in Ruby and wouldn't want to give it up


[00:50:42] dostoyevsky: has joined #ruby
[00:50:51] dostoyevsky: > \\ud862\\udf46\\u7684\\u540c\\u4f4d\\u7d20".gsub(/((\\u[a-f\d]{4})+)/i) { p $1; a= $1.split('\\u'); p a[1..-1].map{|v| v.to_i(16)}.pack("U")} =~ /\\u/
[00:51:08] dostoyevsky: > ArgumentError: invalid byte sequence in UTF-8
[00:51:56] dostoyevsky: Anybody knowing what's going on there? I try to read a dump from wikidata but I cannot convert the encoded characters...
[00:53:26] dostoyevsky: that looks much better...
[00:54:28] dostoyevsky: > "\\ud862\\udf46\\u7684\\u540c\\u4f4d\\u7d20".gsub(/((\\u[a-f\d]{4})+)/i) { a= $1.split('\\u'); a[1..-1].map{|v| v.to_i(16)}.pack("U*")} =~ /t/
[00:54:41] dostoyevsky: but the error persists: ArgumentError: invalid byte sequence in UTF-8
[01:00:30] dostoyevsky: apeiros: thanks. I am going to check if I read it the string correctly from the wikidata dump
[01:08:15] dostoyevsky: >> "\ud862\ude0f\u7684\u540c\u4f4d\u7d20".valid_encoding?
[01:08:39] dostoyevsky: alas, that's really what's in the wikidata dump
[01:12:08] dostoyevsky: And also: node > "\ud862\ude0f\u7684\u540c\u4f4d\u7d20" -> '๐จจ็š„ๅŒไฝ็ด '
[01:12:51] dostoyevsky: hmmm... I cannot copy & paste that string from node...
[01:13:24] dostoyevsky: but node displays "\ud862\ude0f\u7684\u540c\u4f4d\u7d20" just like it's written in wikidata
[01:36:30] dostoyevsky: Seems like ruby is unable to process utf16 strings?
[01:36:49] dostoyevsky: Which is what wikidata is using.. or just emojis
[01:37:43] dostoyevsky: > Encoding::UTF_16
[01:37:51] dostoyevsky: > "\ud83d\ude0d".valid_encoding? # -> false
[01:38:21] dostoyevsky: node has no problem with that emoji, though... and they use utf16 natively
[01:41:40] dostoyevsky: drbrain: ok, that seems to work now!!
[01:43:20] dostoyevsky: The only thing is that I read "\ud83d\ude0d" from that wikidata dump... so I'd like to convert that string... but there is only [].pack("U*") ... so only utf8.. or could I just use force_encoding on that result?
[01:45:31] dostoyevsky: >> s = "\\ud83d\\ude0d".gsub(/((\\u[a-f\d]{4})+)/i) { a= $1.split('\\u'); a[1..-1].map{|v| v.to_i(16)}.pack("U*")}; s.force_encoding Encoding::UTF_16BE; s =~ /t/
[01:48:06] dostoyevsky: drbrain: hmmm... that's not a smiley... :)
[01:48:22] dostoyevsky: I am not sure if emojis are available in utf8
[01:49:03] dostoyevsky: drbrain: interesting, I cannot even c&p emojis from my browser to my utf8 terminal here.. they just become broken characters
[01:56:47] dostoyevsky:
[01:57:10] dostoyevsky: Over on #unicode they say that javascript's unicode implementation is broken...
[02:04:06] dostoyevsky: drbrain: maybe because it's a json dump, the JS \u semantics are used too.. and that's why it's no problem for me to display these dump strings in node..
[02:17:56] dostoyevsky: drbrain: yeah.. now I can see that smiley in ruby too!!! :)
[02:21:04] dostoyevsky: >> JSON.parse('["\\ud83d\\ude0d"]')
[02:21:16] dostoyevsky: >> require 'json'; JSON.parse('["\\ud83d\\ude0d"]')
[10:23:31] dostoyevsky: Quit: leaving


[18:17:23] dostoyevsky: Quit: leaving


[14:38:20] dostoyevsky: Is code in set_trace_func not traced or are there certain constraints into what code is allowed in a trace_func?
[14:39:01] dostoyevsky: > Tracing is disabled within the context of proc.
[17:01:22] dostoyevsky: norc: you mean: java? :)


[01:21:15] dostoyevsky: Ox0dea: yeah, blocks..
[01:24:02] dostoyevsky: Can I read the parameters of a block being called in set_trace_func?


[14:42:21] dostoyevsky: Ping timeout: 260 seconds
[15:31:02] dostoyevsky: has joined #RubyOnRails
[15:31:02] dostoyevsky: has joined #ruby
[23:45:52] dostoyevsky: Hi. Does ruby's set_trace_func also include Procs? Like: do {|a| a.something }


[17:23:03] dostoyevsky: Can one actually use dtrace to see ruby's stack traces? Does one need a driver of some kind? Or is that just: compile ruby with dtrace support?


[21:28:04] dostoyevsky: has joined #ruby
[21:28:36] dostoyevsky: Is it ok to ask rails questions here? #rails doesn't exist though...
[21:29:15] dostoyevsky: has joined #RubyOnRails
[21:29:21] dostoyevsky: havenwood: thx!
[21:29:49] dostoyevsky: Hey, can someone explain me what makes having many routes slow when starting an application?
[21:30:34] dostoyevsky: Is there some kind of o(N) overhead or more involved with adding another route?
[21:41:36] dostoyevsky: tubbo: Ok, I think I explained it wrong. Adding routes is not slow but set_routes_reloader is... but I am not sure what it does or why it might be slow
[21:42:04] dostoyevsky: someone also had this problem before:
[21:42:10] dostoyevsky: (doesn't explain the why, though)
[21:42:29] dostoyevsky: tubbo: reducing number of routes
[21:44:34] dostoyevsky: does routesreloader run everytime a new module is loaded on starting an application? Not sure why there is the need to reload when an application is starting
[21:44:56] dostoyevsky: havenwood: thanks


[07:18:42] dostoyevsky: has left #ruby: ()