jhass changed the topic of #crystal-lang to: The Crystal programming language | https://crystal-lang.org | Crystal 0.35.1 | 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
<FromGitter> <Blacksmoke16> has there even been the thought of allowing parsing yaml/json at compile time and returning a `HashLiteral`?
f1reflyylmao has joined #crystal-lang
f1refly has quit [Ping timeout: 272 seconds]
avane has quit [Quit: ZNC - https://znc.in]
avane has joined #crystal-lang
zorp_ has joined #crystal-lang
zorp has quit [Ping timeout: 256 seconds]
f1reflyylmao has quit [Ping timeout: 246 seconds]
f1refly has joined #crystal-lang
DTZUZU has quit [Ping timeout: 240 seconds]
DTZUZU has joined #crystal-lang
louis771 has joined #crystal-lang
Liothen has quit [Ping timeout: 244 seconds]
<louis771> hi there, before I file a bug report could someone confirm a bug for me? The HTTP::Client#post instance method should accept a String or URI as the first argument, corrent?
<louis771> -n+c ... when I pass a URI it breaks
Liothen has joined #crystal-lang
<louis771> In /usr/share/crystal/src/http/client.cr:754:19
<louis771> 754 | HTTP::Request.new(method, path, headers, body)
<louis771> ^--
<louis771> Error: no overload matches 'HTTP::Request.new' with types String, URI, HTTP::Headers, Nil
<FromGitter> <grkek> Added scoping support
<FromGitter> <grkek> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5f8d46c8631a250ab27a8b31]
deavmi has quit [Remote host closed the connection]
deavmi has joined #crystal-lang
<FromGitter> <Blacksmoke16> louis771: got some example code?
<Andriamanitra> louis771: according to the documentation it only accepts string https://crystal-lang.org/api/0.35.1/HTTP/Request.html
<Andriamanitra> probably would be a good idea to accept uri too but i guess it's a missing feature rather than a bug
<jhass> The problem with accepting URI for #post (opposed to .post) is, what do you do with the host component of it? Remember a HTTP::Client instance is created for a specific host already
duane has quit [Read error: No route to host]
gangstacat has quit [Ping timeout: 272 seconds]
gangstacat has joined #crystal-lang
<FromGitter> <kingsleyh> evening
<FromGitter> <kingsleyh> can anyone help me with this: https://play.crystal-lang.org/#/r/9uov
<FromGitter> <kingsleyh> I want to merge 2 hash together but keep the values
<FromGitter> <kingsleyh> in ruby I would do: `h1.merge(h2){|key, old, new| Array(old).push(new) }` but doesn't work in Crystal as merge doesn't support it
<FromGitter> <kingsleyh> nevermind got it - it's old+new
<FromGitter> <Blacksmoke16> https://crystal-lang.org/api/master/Hash.html#merge(other:Hash(L,W),&block:K,V,W-%3EV%7CW)forallL,W-instance-method are quite a few merge related methods as well
Stephie has quit [Ping timeout: 265 seconds]
Stephanie has joined #crystal-lang
o5r has joined #crystal-lang
<o5r> Hello, I’ve installed Alpine Linux on my Raspberry Pi 4, and upgraded my repositories to Edge, so I can install Crystal on there. That “works”, in the sense that I get the crystal command spits out the usage info, but if I do `crystal eval ‘puts “yay”’` I have a bunch of fun errors about missing things: Scrt1.o, crti.o, -lm, -lpthread, -lrt, and -lssp_nonshared
<FromGitter> <Blacksmoke16> afaik arm isn't natively supported, so might run into some problems ^
<FromGitter> <Blacksmoke16> however im not super familiar with that, so ill defer to someone else :p
zorp_ has quit [Ping timeout: 272 seconds]
<o5r> :P I tried a lot of things, and to be frank I’m a bit outside of my area of expertise myself. I couldn’t cross-compile the compiler correctly, and when I saw that there was a community package in Alpine I got my hopes up and installed that on top
<FromGitter> <Blacksmoke16> can you share the exact error?
<o5r> Yep, please hold
<FromGitter> <Blacksmoke16> i mean did you try installing these things? `apk add musl-dev`
<FromGitter> <Blacksmoke16> should handle at least one of those
<o5r> Oh boy. -lm stands for “musl”?
<FromGitter> <Blacksmoke16> https://github.com/blacklabelops-legacy/rsnapshot/issues/4 idk, just found this issue
<FromGitter> <Blacksmoke16> that lib contains the c libs crystal needs to link id imagine so yea
<o5r> Well, it works. I’m not even going to blame monday for it, I’ll just fully accept that I failed miserably lol
<o5r> Thanks a million
<FromGitter> <Blacksmoke16> np
<o5r> I’ll hit up the maintainer and see if I can somehow get him to shove musl-dev in his dependencies for Crystal. That way my failure can actually help someone else someday!
<FromGitter> <Blacksmoke16> I think that would be @mps
<FromGitter> <Blacksmoke16> er at least thats his name on irc
<o5r> I can see an mps on #alpine-linux
<FromGitter> <Blacksmoke16> 👍
<o5r> He apparently does not maintain it anymore, but I reached out via email to the current maintainer. I’ll read contribution guildelines for Alpine Linux later this week and provide my own patch if I can get there before they do
<FromGitter> <Blacksmoke16> ah darn, 👍
<o5r> Thanks again for your help!
<FromGitter> <wontruefree> I am running a dockerfile with crystal:0.35.1 as the base. ⏎ https://github.com/luckyframework/avram/blob/master/Dockerfile#L1 ⏎ I am having trouble it is returning `E: The repository 'https://dist.crystal-lang.org/apt crystal Release' does not have a Release file.` ⏎ Am I doing something wrong? [https://gitter.im/crystal-lang/crystal?at=5f8e0bc4bbffc02b5828e364]
yukai has joined #crystal-lang