ChanServ changed the topic of #crystal-lang to: The Crystal programming language | https://crystal-lang.org | Fund Crystal's development: https://crystal-lang.org/sponsors | GH: https://github.com/crystal-lang/crystal | Docs: https://crystal-lang.org/docs | Gitter: https://gitter.im/crystal-lang/crystal
Chillfox has joined #crystal-lang
<FromGitter> <Dan-Do> @frojnd I can just use new(string) without any problem (no encoding)
<FromGitter> <Dan-Do> So, it should be `parser = Lexbor::Parser.new(verse_response.body, encoding: Lexbor::EncodingConverter.new("cp1251", "utf-8"))`
ua_ has quit [Quit: Leaving]
ua_ has joined #crystal-lang
ua_ has quit [Ping timeout: 268 seconds]
ua_ has joined #crystal-lang
ur5us has quit [Ping timeout: 264 seconds]
<frojnd> @Dan-Do yeah, I had to do it like that: `parser = Lexbor::Parser.new(Lexbor::EncodingConverter.new("windows-1250", "utf-8"), verse_response.body)`
ur5us has joined #crystal-lang
ur5us has quit [Ping timeout: 260 seconds]
guniberas has joined #crystal-lang
<frojnd> Any ideas on how to get only text: "foo bar text" without "baz text" https://carc.in/#/r/c6v9
<frojnd> Like, I would just like text inside .text class but exclude from class .ft
<frojnd> Ah, that .ft class name is changing :/
hightower2 has joined #crystal-lang
guniberas has quit [Ping timeout: 268 seconds]
Guest51 has joined #crystal-lang
Guest51 has quit [Client Quit]
taupiqueur has joined #crystal-lang
dmgk has joined #crystal-lang
<FromGitter> <plambert> Anyone know how I can do a reverse DNS lookup from crystal? i.e. a PTR dns request for x.x.x.x.in-addr.arpa?
<FromGitter> <plambert> I'm hoping I can do it without using a resolver library like crystal-dns, or writing my own resolver...
<FromGitter> <eliasjpr> Authority ⏎ ⏎ Repo - https://github.com/azutoolkit/authority ⏎ ⏎ Authority is an easy to use highly cuztomizable OpenID Connect and OAuth Provider written in Crystal - Security-first, open source API security for your infrastructure. SDKs to come. ... [https://gitter.im/crystal-lang/crystal?at=6182d8c629ddcd02935f7f85]
<FromGitter> <eliasjpr> Sharing ^
<FromGitter> <aaaScript> @plambert I think your best bet if you don't want to to use a full library may be to rip out the functionality that you need. I took al look at the library that you mentioned (https://gitlab.com/jgillich/crystal-dns) and it looks very neatly organized so the task itself shouldn't be too difficult
<FromGitter> <aaaScript> @eliasjpr wow very nice
<FromGitter> <eliasjpr> Thank you
<FromGitter> <eliasjpr> Feel free to contribute is not perfect
<FromGitter> <plambert> Thanks, @aaaScript...
<FromGitter> <plambert> It looks like `getnameinfo` is available in LibC::Addrinfo
<FromGitter> <plambert> Maybe I can wrap it with enough to do what I need?
<FromGitter> <plambert> I'm definitely doing something wrong, it only returns 14 (argument buffer overflow)
<FromGitter> <plambert> `$ bin/dns-test ⏎ calling getnameinfo(addr: Socket::IPAddress(8.8.8.8:8080), addr_len: 48, host_slice: 1025, NI_MAXHOST: 1025, service: "80", service_len: 2, flags: None) ⏎ result: 14: argument buffer overflow`
<FromGitter> <plambert> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=6182e886fb3dcd4e88665c2b]
<FromGitter> <plambert> AHA! Figured it out. :)
ur5us has joined #crystal-lang
taupiqueur has quit [Quit: taupiqueur]
yxhuvud has quit [Remote host closed the connection]
yxhuvud has joined #crystal-lang
ua_ has quit [Ping timeout: 260 seconds]