<FromGitter>
<iamonkara> Any idea if Crystal has or plans to support Erlang style Supervisors http://erlang.org/doc/design_principles/sup_princ.html ?? ⏎ This would be a killer feature and for me at least would be a no brainer to move from RoR to Crystal instead of RoR to Elixir
wes[phi] has joined #crystal-lang
wes[phi] has quit [Ping timeout: 240 seconds]
<FromGitter>
<faustinoaq> @iamonkara Someone already commented this in a disqus comment and in reddit and now here 😅 ⏎ ⏎ I think core developers are using Erlang at Manas, so maybe They already took some ideas from Erlang. ⏎ ⏎ But as far I know They are thinking in something similar to Guild in Ruby 3. Also currently we are using CSP model for concurrency. [https://gitter.im/crysta
<FromGitter>
<opensas> I was wondering the same, perhaps with just the public types (return value and input params of every public method) would be enough to compile every source file independently, and allow for incremental compilation. More over, the compiler could warn you when there's a missing typ preventing it from doing incremental compilation. That way you would only need to define types if you need/want to compile faster.
greengriminal has quit [Quit: Leaving]
<FromGitter>
<ansarizafar> Mandatory types is a great idea.
snsei has joined #crystal-lang
solarluneAFK is now known as SolarLune
hightower4 has joined #crystal-lang
DissonantGuile has joined #crystal-lang
hightower3 has quit [Ping timeout: 240 seconds]
baweaver is now known as baweaver_away
rohitpaulk has joined #crystal-lang
alex`` has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 240 seconds]
alex`` has quit [Client Quit]
rohitpaulk has joined #crystal-lang
baweaver_away is now known as baweaver
Papierkorb_ has joined #crystal-lang
<Papierkorb_>
Ohayo ~
snsei has quit [Remote host closed the connection]
mark_66 has joined #crystal-lang
<Groogy_>
Morning! o/
Groogy has quit [Disconnected by services]
Groogy_ is now known as Groogy
Groogy2 has joined #crystal-lang
<FromGitter>
<sdogruyol> Morning everyone
rohitpaulk has quit [Ping timeout: 246 seconds]
rohitpaulk has joined #crystal-lang
<FromGitter>
<faustinoaq> Morning :)
<FromGitter>
<faustinoaq> I was thinking that I did more answers than questions in AMA last week. 😅
ShalokShalom has quit [Ping timeout: 252 seconds]
<FromGitter>
<sdogruyol> that's great @faustinoaq
ShalokShalom has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 246 seconds]
<FromGitter>
<faustinoaq> 👍
rohitpaulk has joined #crystal-lang
alex`` has joined #crystal-lang
alex`` is now known as alexherbo2
alexherbo2 is now known as alex``
<FromGitter>
<krypton97> Morning :)
DTZUZO has quit [Ping timeout: 252 seconds]
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
<FromGitter>
<marin117> hi :D
<FromGitter>
<crisward> Trying to trigger something on a bunch on listeners. Can anyone see anything wrong with this https://play.crystal-lang.org/#/r/2q4x thanks.
<FromGitter>
<crisward> Apart from the horrible indenting 😉
<FromGitter>
<sdogruyol> it seems ok
bmcginty has quit [Ping timeout: 240 seconds]
bmcginty has joined #crystal-lang
ShalokShalom has quit [Read error: Connection reset by peer]
<Groogy>
Also on > I want Windows support, but I agree with Doug. I think after 1.0, more people will join to Crystal community and do Windows port easier.
<Groogy>
I think 1.0 should not be announced before Windows support is somewhat done because you only get one first impression. And knowing the internet, even if Windows support ocmes a month later the idea will already be stuck for a long time following as "the language that don't support Windows"
<FromGitter>
<faustinoaq> Yeah, I agree, but I don't know how much work is needed to support Windows ;)
<Papierkorb_>
Nice. My awful bag of words processor script runs (with minimal changes) thrice as fast as the ruby version.
rohitpaulk has quit [Ping timeout: 248 seconds]
<hightower4>
++
SolarLune has quit [Quit: Leaving]
ShalokShalom_ has joined #crystal-lang
ShalokShalom has quit [Ping timeout: 248 seconds]
<FromGitter>
<bararchy> Papierkorb_ bag of words you say ? Normalizing data for a classifier ? ;)
<Papierkorb_>
Yup. Gotta clean that thing a "bit" more though I guess. I'll learn how lol.
<FromGitter>
<bararchy> If its open on github , let me know ,I might be able to help a bit
<Papierkorb_>
Ain't exactly classified, though I guess our customers wouldn't be fazed by me putting it up there :P
<Papierkorb_>
AI is pretty new to me. Always wanted to do something with it, but never knew what to do, so I never really learned it
<Papierkorb_>
If you can recommend any blogs or so, I'm all ears
<Papierkorb_>
Basically, I have a fair amount of ecommerce data, and want to fiddle with it. Classification is a big one. The data is already category-tagged too. Have about >60M records available.
<FromGitter>
<bararchy> What do you want to classify it by ?
<FromGitter>
<bararchy> If its already categorised
<Papierkorb_>
Well basically, I want to have a classifier I can give a search term, and it then tells me which category/ies it fits best
<FromGitter>
<bararchy> So a bayes classifier is the best , you will need to teach it on current data (which you have a good amount of) and let it learn what data goes to what category , then it should be able to make the decision it self for new data
<crystal-gh>
[crystal] RX14 closed pull request #4945: GC.enable: raise if GC is not disabled (master...bug/gc-enable) https://git.io/v5PIf
<Papierkorb_>
bararchy, sounds good. Will try that :)
<FromGitter>
<bararchy> Good luck , ping me if you need any advice :)
<Papierkorb_>
Unrelated to that, Say I collect data when I do an action in my smart house (when I open windows, ...). How could I build it that when the software detects a pattern of me doing an action?
<Papierkorb_>
Like "Korb opens the window on Monday to Thursday at 5pm, but on friday at 4pm"
<FromGitter>
<bararchy> Neural network , its the best approach to non-liner classifying and pattern detection
sija has joined #crystal-lang
<FromGitter>
<bararchy> Papierkorb_ as in , day 1 you brought a bottle of water , day 2 you brought 2 bottles , day 3 etc.. This is statistics and a liner growth even us simple humans can recognize the pattern , but when its day 1 brought 2 bottles , day 2 no battles , day 3 brought 6 bottles , etc... We need a neural network to cluster the data and try to find a pattern
<FromGitter>
<bararchy> For this specific example (smart house) I would use unsupervised learning , maybe GNG or other algorithm for data clusterrning , its basically a class of problems named "user behavior analysis" , it is used to find human patterns
<FromGitter>
<Qwerp-Derp> I feel like every time I bring up an issue it's been dealt with already (that's a good thing, not a bad thing :D)
<Papierkorb_>
input "blue green working shoes" -> `Home & Garden > Kitchen & Dining > Tableware > Drinkware` ... nailed it.
<RX14>
well if you ask daniel ricciardo...
<Groogy>
have an event this weekend so I get no crystal coding done :(
<Groogy>
I'll have to settle with just looking at whatever you guys link here
<FromGitter>
<sdogruyol> @RX14 who's that?
<Papierkorb_>
that football player?
<Papierkorb_>
or was that some other dude?
<FromGitter>
<sdogruyol> watching asterite doing awesome work is also great @Groogy :)
<FromGitter>
<sdogruyol> OT Aur still doesn't have LLVM 5.0 on extra...
<RX14>
Papierkorb_, formula 1 driver who drinks from his shoes on the podium
<Groogy>
yeah really nice he fixed the GC issue
<FromGitter>
<sdogruyol> @RX14 that's gross :/
<RX14>
lol
<Papierkorb_>
Well, let's hope there's enough alcohol to kill anything in that shoe that may live lol
<FromGitter>
<ekremkaraca> Hey guys, I'm the one who was created some screencasts about Crystal language. I've recognized that there's huge visit from here, gitter. I'd like to thank you all!
<FromGitter>
<ekremkaraca> Especially my friend, @sdogruyol!
<FromGitter>
<sdogruyol> hey @ekremkaraca welcome
<FromGitter>
<sdogruyol> we have some crowd here 😄
<Groogy>
Need English TL though :/
<FromGitter>
<ekremkaraca> Thanks so much again. Hope there will be English 🙏
<crystal-gh>
[crystal] RX14 closed pull request #4972: debug: don't set end_location at function exit (master...bug/debug-end-location) https://git.io/v5HUm
<Groogy>
awesome!
<FromGitter>
<ekremkaraca> I mean, screencasts in English
rohitpaulk has joined #crystal-lang
<FromGitter>
<sdogruyol> Cool 💯
<FromGitter>
<bararchy> @ekremkaraca thanks for spreading the Crystal religion further ;)
<FromGitter>
<bararchy> Eng version would be really appreciated
<FromGitter>
<zyriuse75> hi everyone
<FromGitter>
<sdogruyol> We have a strong community in Turkey
<FromGitter>
<sdogruyol> 😉
<FromGitter>
<zyriuse75> i've a question i fork the doc repository and i would want to push on my fork and not on the master how i can do that ?
<FromGitter>
<zyriuse75> i already create my feature
<FromGitter>
<exts> dynamic controllers, but this seems really hacky at a second look
<FromGitter>
<exts> mmm time to shake off my and test something
LastWhisper____ has joined #crystal-lang
snsei has joined #crystal-lang
thews has quit [Ping timeout: 240 seconds]
thews has joined #crystal-lang
<crystal-gh>
[crystal] bcardiff closed pull request #4962: Make Tuple and NamedTuples .types to return tuples of metaclasses (master...fix/tuple-types) https://git.io/v5yJN
rohitpaulk has quit [Ping timeout: 248 seconds]
<FromGitter>
<ekremkaraca> Hi again, in my free time, I made a Crystal screencast in English. It's short introductory video: https://youtu.be/MmL1_GZu6aM
<FromGitter>
<ekremkaraca> Thanks for your feedback!
mark_66 has quit [Quit: Leaving.]
<FromGitter>
<sdogruyol> @ekremkaraca 👍 👏
mark_66 has joined #crystal-lang
<FromGitter>
<ekremkaraca> I may begin a new series depending on your feedback, I know there are some pronunciation issues.
<FromGitter>
<ekremkaraca> That's the thing I'm worrying about :(
Papierkorb_ has quit [Quit: Konversation terminated!]
<FromGitter>
<sdogruyol> @ekremkaraca how about removing your face from the screencast
<FromGitter>
<sdogruyol> that's a bit distracting tbh
<crystal-gh>
[crystal] RX14 closed pull request #4974: Don't find type parameter T of generic type that's not the current type (master...bug/4460-fix-generic-type-bug) https://git.io/v5Qcl
<FromGitter>
<jwaldrip> what is the `?`
<FromGitter>
<asterite> It probably means what comes next is a key of a mapping
<FromGitter>
<jwaldrip> gotcha
<FromGitter>
<asterite> "A question mark and space (“? ”) indicate a complex mapping key"
<FromGitter>
<faustinoaq> Opal is a good reference too
<crystal-gh>
[crystal] asterite opened pull request #4978: String: optimize gsub and tr for ascii char and single byte string (master...perf/optimize-gsub-and-tr) https://git.io/v57je
<FromGitter>
<asterite> It seems like a huge and very difficult task. I don't know how you'll handle lib calls, for example. Or fibers and context switch. Or the GC. I also think typescript, flow or elm are better suited for javascript
<FromGitter>
<sandelius> evening from Sweden!
<FromGitter>
<faustinoaq> Ok, Thanks for your advice, I enjoy TypeScript, so I think Crystal for backend is good as is. Maybe in the future we can compile Crystal to WebAssembly instead. :)
<FromGitter>
<ekremkaraca> @bararchy wikipedia was blocked in Turkey :(
<FromGitter>
<bararchy> Oo
<FromGitter>
<bararchy> Sorry :\
<FromGitter>
<ekremkaraca> @bararchy no problem, hope it will be unblocked soon :)
<FromGitter>
<bararchy> @ekremkaraca you should add "variable assginments" , and maybe "classes and objects" ?
<FromGitter>
<ekremkaraca> I've opened both English & Turkish articles in wikipedia
<FromGitter>
<ekremkaraca> sorry, started
<FromGitter>
<eliasjpr> @eliasjpr ⏎ Anyone has an idea on how to start a java -jar process in the background with Crystal? ⏎ I am using Process.run(command)Is there any way to add
<FromGitter>
<ekremkaraca> @bararchy I did it, thanks
<FromGitter>
<bararchy> @eliasjpr keep in mind, argument (`-jar`) should come in as a 2nd argument
<oprypin>
just remove the `.join(' ')` and it might actually work
<oprypin>
(and remove shell too)
<FromGitter>
<eliasjpr> okay the process ran and it booted but it seems to be attached to the current process or is just waiting for it to terminate, I would like to just start the process in the backgroun and shutting down when needed
<oprypin>
eliasjpr, well you might expect that if you run `.wait`
<FromGitter>
<eliasjpr> gotcha,
<oprypin>
did you use a fiber like originaly intended?
<Papierkorb>
apart from the quote .. what is it saying?
<oprypin>
can't go without mentioning top reddit comment
wes[phi] has joined #crystal-lang
<FromGitter>
<drujensen> `production` is a relative term. If you work for nasa or a hospital, you will have a different standard for `production` than say a small startup company trying to find a first customer. The former, you should get fired, the latter you should be promoted. Most of us are somewhere in between the two extremes and trying to find a safe place to use such an awesome language/tool.
<FromGitter>
<crisward> @drujensen couldn't agree more. As the writer of the article, I'm very surprised what happened. I didn't post it to reddit or anywhere else. One of my colleagues in the office tweeted it.
<Papierkorb>
I wouldn't advise to use Crystal in production yet. But that mainly stems from the fact that there are things that may blow up, which would reflect badly on the project. As long the developers know of the risks it's fine though. Oh, and I too use the occasional Crystal script @ work.
<Papierkorb>
Though those whiny comments on reddit .. oh well. /r/programming in a nutshell.
<FromGitter>
<crisward> We're mainly creating marketing websites for small companies. Nothing too demanding.
<Papierkorb>
Yes, and on top of that, you're part of the community and know of the involved risks. You wouldn't run around for years saying that Crystal is awful cause you hit a hiccup in the current state. And thus, I applaud your investment into the project!
SolarLune has joined #crystal-lang
<FromGitter>
<drujensen> same here 😄
<FromGitter>
<crisward> There are more than a few hiccups discoverable in any language, even the very well established ones. The only real danger for crystal is it doesn't reach its full potential.
<FromGitter>
<crisward> You use express in the past?
<FromGitter>
<wwselleck> yep
<FromGitter>
<crisward> Globals aren't quite as bad in crystal / ruby as you can wrap stuff in modules for name spacing. But I also like it more when methods aren't made global.
<FromGitter>
<crisward> Also done a lot with node.
<FromGitter>
<wwselleck> That PR seems to have stalled :(
<FromGitter>
<crisward> Performance issues I seem to remember
<FromGitter>
<crisward> You can pass blocks around, sort of. Bit like callbacks.
<FromGitter>
<wwselleck> you happen to know why? considering you can define middleware as a HTTP::Handler, I don't see why you couldnt do the same for the routes
jhpratt has joined #crystal-lang
jhpratt has left #crystal-lang [#crystal-lang]
<FromGitter>
<crisward> I'm pretty sure the router is middleware, when it matches one of your passed in routes, it calls your block
<FromGitter>
<crisward> If you just want to separate your routes and handlers you can do...
<FromGitter>
<wwselleck> I suppose that's not the end of the world, i coudl probably just make a wrapper class that does that
<FromGitter>
<wwselleck> well actually, maybe middelware could be used for that
<FromGitter>
<crisward> In my app I've wrapped kemals routes in a module which exposes the routes with a permission handler and only calls the callback if they have the permission. Otherwise it returns 401 if they need to login or 403 if they're logged in without permission. Works well. You could do something similar.
<FromGitter>
<wwselleck> Is ur app public by any chance?
<FromGitter>
<crisward> So my routes are like `Api.get "/duocms/api/users", "users_all", ->all(Ctx)`
<FromGitter>
<faustinoaq> @wwselleck Well, Also you can also check Amber (amberframework.org) isn't as simple as Kemal but is really easy to use generators for auth, blogs, crud, models, etc, Amber include some tools for frontend too. In fact the creator of Kemal @sdogruyol is part of Amber community too 😉
<FromGitter>
<crisward> Amber looks promising... looking forward to see it develop.
<FromGitter>
<crisward> Had roll most of my own stuff when I started this last year.
<FromGitter>
<crisward> Above all is just a proc to a method. Ctx is an alias of server context ie, `alias Ctx = HTTP::Server::Context`
<FromGitter>
<wwselleck> Amber looks really interesting. I'm generally not a huge fan of mega-frameworks for apps that are more or less just REST APIs, but I might give it a shot.
<FromGitter>
<crisward> What I like about this is it forces every route to have a permission. We have a permission called everyone.
<FromGitter>
<crisward> I'm the same, I like smaller stuff, hence why I use kemal.
<FromGitter>
<crisward> There is also router.cr is you want really small.
<FromGitter>
<crisward> I believe Kemal was originally based on something the core devs did before they realise they were stretching themselves too thin.
<FromGitter>
<crisward> So is Amber going to be Crystal's Rails I wonder?
wes[phi] has quit [Ping timeout: 248 seconds]
<FromGitter>
<crisward> It'll be interesting to see if they decide on a js view layer + json api, instead of the classic html crud app.
<FromGitter>
<crisward> @wwselleck How did you find out about Crystal?
<FromGitter>
<mverzilli> Kemal was a fork from a Sinatra clone Ary, Brian and Waj wrote at Manas, which was named Frank
<FromGitter>
<faustinoaq> Amber was a Kemalyst fork, Kemalyst was a Kemal fork , Kemal was a Frank fork. 😄 ⏎ ⏎ So, We are all reusing and collaborating together ✨