ChanServ changed the topic of #crystal-lang to: The Crystal programming language | | Fund Crystal's development: | GH: | Docs: | Gitter:
Starfoxxes has quit [Ping timeout: 248 seconds]
Starfoxxes has joined #crystal-lang
hightower3 has joined #crystal-lang
hightower2 has quit [Ping timeout: 256 seconds]
ur5us_ has quit [Ping timeout: 260 seconds]
jhass has quit [Ping timeout: 248 seconds]
jhass has joined #crystal-lang
<FromGitter> <> Why hasn't there been much interest in Crystal considering it's faster than Python and has an easier learning curve?
ur5us_ has joined #crystal-lang
brw has quit [Read error: Connection reset by peer]
ur5us_ has quit [Ping timeout: 260 seconds]
quazimodo has quit [Ping timeout: 248 seconds]
quazimodo has joined #crystal-lang
ur5us_ has joined #crystal-lang
_ht has joined #crystal-lang
ur5us_ has quit [Remote host closed the connection]
ur5us_ has joined #crystal-lang
alexherbo2 has joined #crystal-lang
ur5us_ has quit [Ping timeout: 252 seconds]
<FromGitter> <mekhla18> What I feel is each language has its own capabilities and Crystal too comes with its advantages. There is usually an idea of believing languages like python,Java to be sparking interest as they have gone mainstram however if the mainstream languages are better than the less popular ones , that's an arguable topic 😊
<FromGitter> <mekhla18> While I believe Crystal has an amazing and passionate community, I agree to the fact that Crystal as a product and the community hasn't been much visible, hence one of my focus areas would be to develop n support influencers evangelising local Crystal communities, that would help create local Crystal chapters in each geography and would definitely add to the visibility.
alexherbo2 has quit [Remote host closed the connection]
quazimodo has quit [Ping timeout: 252 seconds]
<FromGitter> <> python has ML, ruby has rails, crystal doesn't have its killer app, yet - that's probably all
jmdaemon has quit [Ping timeout: 248 seconds]
brw has joined #crystal-lang
alexherbo2 has joined #crystal-lang
alexherbo2 has quit [Remote host closed the connection]
alexherbo2 has joined #crystal-lang
<FromGitter> <mjblack> What is the best way to debug a crystal application on windows? I tried visual studio debugger but I cant view variables and all it gives me is disassembly.
alexherbo2 has quit [Remote host closed the connection]
<FromGitter> <Blacksmoke16> a good ol `pp` would prob be the simpliest
jmdaemon has joined #crystal-lang
mjblack has joined #crystal-lang
oprypin has quit [Remote host closed the connection]
<FromGitter> <HertzDevil> atm you have to grab the natvis definitions from the crystal repo itself
<FromGitter> <HertzDevil> more details in
<FromGitter> <HertzDevil> otherwise you should still be able to see local variables
<FromGitter> <HertzDevil> oh yeah you'll need `--debug` while building
FromGitter has quit [Remote host closed the connection]
oprypin has joined #crystal-lang
FromGitter has joined #crystal-lang
jmdaemon has quit [Ping timeout: 252 seconds]
<riza> honestly, Crystal's killer feature is it's type system
<riza> i'm working in elixir these days and the compile times are worse than crystal for a project of similar size...and there are no types. the developers what came before me have done a pretty incredible job of wedging structs in literally every junction to fake a type system but it's a really verbose process
<riza> meanwhile in literally every meeting the front end folks are saying "thank god for types because X would have taken me so much longer without typescript"
jmdaemon has joined #crystal-lang
<FromGitter> <> i think elixir only exists because phoenix. do people use it for anything else?
<FromGitter> <> agree. but that's a killer feature. i was talking about a killer *app*.
<FromGitter> <> something like rails, or an impl of OTP ("look mom, telco grade scalability without having to use a language that doesn't even have strings").
<FromGitter> <> but i'm optimistic it will happen eventually anyway. the crystal mix of performance/productivity is just unmatched - i don't see any other lang that comes even close. it'll just keep snowballing and pick up refugees from these lesser languages.
<FromGitter> <Blacksmoke16> id argue it doesnt have to be a killer app, but at least a killer ecosystem
<FromGitter> <Blacksmoke16> give the people the tools/libs to do what they want, to be productive and performant
<FromGitter> <> well yea, can be either. e.g. if someone builds some great ML shards we could bite a huge chunk out of python very quickly.
<FromGitter> <> "imagine playing with tensors and not suffering through python dependency hell at every step of the road"
<FromGitter> <> same for rails... imagine all the fun convenience, but with type-safety, crazy performance, and you can actually upgrade major versions without randomly breaking everything
<FromGitter> <Blacksmoke16> i got that one covered ;)
<FromGitter> <Blacksmoke16> hehe
<FromGitter> <> then code faster, i don't see it yet :P
<FromGitter> <Blacksmoke16> *soon*
<FromGitter> <Blacksmoke16> be releasing a new version here soon. have some cool features so we're getting there ha 💪
<yxhuvud> eh, upgrades have been pretty painfree lately. Not like the devilish ones around 2->3->4 (and inside 3)
<FromGitter> <> only if you are very intimately familiar with rails, don't depend on strange gems, didn't do "special" stuff etc.
<FromGitter> <> on average it's still the same hell as always
_ht has quit [Quit: _ht]
<FromGitter> <azurelmao> What could be the cause behind a "Unhandled exception: Missing hash key: 0 (KeyError)"?
<FromGitter> <azurelmao> the place where I'm accesing it is behind a nil check
<FromGitter> <azurelmao> and 0 is indeed a key in the hash
<FromGitter> <azurelmao> so how is that possible?
<FromGitter> <RespiteSage> What's the type of your hash?
<FromGitter> <RespiteSage> Or, I guess, what's the type of your hash key?
<FromGitter> <azurelmao> (UInt8 | String)
<FromGitter> <azurelmao> the var that im using to access it is (UInt8 | Nil)
<FromGitter> <RespiteSage> Huh.
<FromGitter> <azurelmao> but it's behind a .nil? check so it shouldnt matter
<FromGitter> <RespiteSage> It's not an instance variable, right? Or it's reassigned?
<FromGitter> <RespiteSage> But I wouldn't expect that error if it's an issue with the key being nilable.
<FromGitter> <azurelmao> it is reassigned from = nil
<FromGitter> <azurelmao> only did it so the scope would be a level higher
<FromGitter> <RespiteSage> So it's not an instance variable, then?
<FromGitter> <azurelmao> instance as in? I don't understand
<FromGitter> <RespiteSage> Like a variable inside of an instance of a class or struct
<FromGitter> <azurelmao> oh, no it isn't
<FromGitter> <azurelmao> it's just a local variable in a method
<FromGitter> <RespiteSage> Are you doing something roughly like this?
<FromGitter> <azurelmao> I think it has to do with the hash not being initialized at the time of accessing it
<FromGitter> <Blacksmoke16> is the code public?
<FromGitter> <azurelmao> no
<FromGitter> <Blacksmoke16> can you share that single method?
<FromGitter> <azurelmao> sure
<FromGitter> <Blacksmoke16> or make a small example that demonstrates the error?
Sankalp- has joined #crystal-lang
Sankalp has quit [Ping timeout: 252 seconds]
Sankalp- is now known as Sankalp
<FromGitter> <azurelmao> this is basically it
<FromGitter> <azurelmao> im not sure if i can replicate it
<FromGitter> <Blacksmoke16> and where does the error originate from?
<FromGitter> <azurelmao> `Block.blocks[id_neg_y]`
<FromGitter> <azurelmao> where it accesses the hash
<FromGitter> <azurelmao> i tried to manually input 0 for example and it also errored, so the hash really does not have the key
<FromGitter> <azurelmao> even though it should
<FromGitter> <azurelmao> it's in the class init
<FromGitter> <Blacksmoke16> well just because its not `nil` doesnt mean its in the hash?
<FromGitter> <Blacksmoke16> the id that is*
<FromGitter> <Blacksmoke16> `neg_y = Block.blocks[id_neg_y]?.try &.opaque? || false`
<FromGitter> <azurelmao> but you can see the `air` block in the class_getter
<FromGitter> <azurelmao> shouldnt the compiler initialize it? and add the 0 to the hash
<FromGitter> <Blacksmoke16> right, but the air block would have its own class var
<FromGitter> <Blacksmoke16> so `AirBlock.blocks` would have key `0`, but not `Block`
<FromGitter> <azurelmao> hm
<FromGitter> <azurelmao> now that's a bit of an issue
<FromGitter> <Blacksmoke16> move it to a module or a constant within the block type
<FromGitter> <azurelmao> I guess I could store the hash somewhere else
<FromGitter> <Blacksmoke16> yea
<FromGitter> <Blacksmoke16> a const would be shared between children, and if you're only mutating it it being a const is fine
<FromGitter> <azurelmao> on another note, ive recently tried rust and it's strange how similar they are in features
<FromGitter> <azurelmao> mainly just macros and its type system
<FromGitter> <azurelmao> there were some other things but i forgot
<FromGitter> <Blacksmoke16> dunno, never used it
<FromGitter> <azurelmao> you should give it a try, best way i would describe it is an improved C, like what kotlin is to java
<FromGitter> <Blacksmoke16> i think ill stick to my crystal ;)
<FromGitter> <azurelmao> crystal is and will always be in my heart too :p
<mps> rust is more improved C++ and not C
<mps> most hyped language in last years
hightower3 has quit [Remote host closed the connection]