<FromGitter>
<crisward> Out of interest, are there any documented memory leaks in crystal. Our site when first launched uses around 7mb of ram inside a docker container. After 24hrs it is up to 140Mb.
<FromGitter>
<crisward> @Sija Very cool. We use sentry and that was on my list of things to write soon. I'll give it a go and let you know how I get on.
<FromGitter>
<sdogruyol> @sija good job :)
<sija>
@crisward gr8! let me know how did it go :)
<Papierkorb>
and just now I notice that `end`s indention being way off
<jokke>
Papierkorb: we need crystalcop :P
<Papierkorb>
Well there's the format tool which I never use..
<jokke>
dito
<jokke>
but that's just formating
<jokke>
and i don't like tools that automatically change my code
<Papierkorb>
I don't agree with all syntax formatting rules, so without being able to configure it it's not for me. (Is there a way to configure it?)
<RX14>
well personally I think that's just stubborn
<RX14>
you shouldn't have an opinion about how your code looks
<Papierkorb>
Oh but a program has it?
<Papierkorb>
Am I serving the machine now?
<RX14>
you should use the standard format for the programming language you're using
<RX14>
for personal projects it doesn't really matter
<RX14>
but for team projects it does
<RX14>
and I like to get in the habit
<RX14>
crystal tool format is what you should use
<RX14>
(it's a tad buggy at times with corner cases but thats another matter)
<Papierkorb>
Syntax formatting doesn't matter as long the grand scheme is consistent
<Papierkorb>
Annoying someone to put a single space somewhere while everything else is great is just being picky and not helpful
<RX14>
but you don't have to annoy them
<RX14>
because it's automatic
<jokke>
i agree that formatting should not be a matter of opinion but i still would rather have a tool that complains about my code so that i can change it and learn from my "mistakes" than one that silently changes my code
<RX14>
my editor just does it before i save
braidn[m] has joined #crystal-lang
<RX14>
but I disagree
<RX14>
because when you just ctrl-s and your code is formatted it's great
<RX14>
you don't have to care any more
<RX14>
you just ctrl-s and it's done
<jokke>
nah
<jokke>
not for me
<Papierkorb>
Sometimes, a rule violation is helping readability
<jokke>
it's creepy and it requires you to set up your editor so that it does that
<Papierkorb>
And thus, anything that does changes without asking is more harmful
<RX14>
Papierkorb, crystal tool format is nearly always right
<Papierkorb>
> nearly
<RX14>
bugs
<Papierkorb>
It's not a human, it can't decide if a trailing if or a if-with-block is more readable
<Papierkorb>
Deciding just on line length doesn't cut it
<RX14>
yes but crystal tool format doesn't do that
<RX14>
it doesn't touch on either of those
<RX14>
go got it right on this one - it's time for developers to swallow their opinions
<FromGitter>
<sdogruyol> @crisward are you using connection pooling e.g?
<FromGitter>
<crisward> @sdogruyol on the database, yes.
<FromGitter>
<sdogruyol> connection pool reserves some memory for sure but 7 to 140 is a bit much
<FromGitter>
<sdogruyol> are you rendering or fetching many objects at once
<FromGitter>
<crisward> The increase in memory if very slow. I restarted it a few hours ago, it went down to 7mb, is upto around 60mb at the moment.
<FromGitter>
<sdogruyol> i'd be happy to help you track down what's causing that @crisward
<FromGitter>
<tekjar> Hi. Are channels mpmc in crystal?
Renich has joined #crystal-lang
gloscombe has quit [Remote host closed the connection]
soveran has quit [Remote host closed the connection]
<Yxhuvud>
Not yet. It is in the works.
<Yxhuvud>
or hmm, if that 'p' is 'producer' and not process, then I don't know
lacour has joined #crystal-lang
<FromGitter>
<tekjar> I mean multi producer multi consumer
<RX14>
they are
<RX14>
any fiber can send or recieve from a channel
<FromGitter>
<tekjar> Ahh I wish these docs are working. I want to understand how `close` semantics work in crystal. IIRC golang people call `chan.close()` or something similar in `defer`so that transmitter knows when a fibre is down
<FromGitter>
<tekjar> In rust, you don't even have to `close` explicitly
<FromGitter>
<tekjar> `tx` just errors out when `rx` is out of scope
<RX14>
I set the cache dir and it's reporting it as "@2/.crystal-cache"
<RX14>
when it's really not
<Papierkorb>
The cache needs a revamp eitherway. I still suspect the gradual slowdown some ppl face is due to it placing everything into the same directory, which some FS drivers don't like much. Will be especially slow for HDD users
<Papierkorb>
Can't you run each runner in its own Docker container or so?
<RX14>
how would that help?
<RX14>
they're all running in dirrect directories
<RX14>
with different cache directories
<Papierkorb>
each would be forced to use their own everything
<RX14>
but they already should be
<Papierkorb>
I'd actually admire it if they'd still clash
<RX14>
they would clash on memory
<RX14>
also i'm not running docker for this
<RX14>
it's a million times too much work
<RX14>
well
<RX14>
I guess building in parallel is out
<Papierkorb>
Wanna "finish" (well, this one will never be finished I guess) my current project first, which can take be anything between days and a month or two. Else I'd actually be interested in trying my hand at the caching stuff
<RX14>
the problem is that merely running the specs, and compiling the compiler at the same time uses more than 8gb of memory
<RX14>
crystal is such a memory hog
<Papierkorb>
For me it's a 500MiB difference between --release and not (so, optimizations on/off) when pulling in the whole compiler
<Papierkorb>
That's 25% of residential memory for that thing here just for LLVM poking at the code
<RX14>
Papierkorb, crystal will just straight not compile unless it has > 4gb ram
<Papierkorb>
To be fair, many compilers need tons of memory to compile and link themselves
<Papierkorb>
or other projects like firefox, with their interesting hacks to get around the memory limit for their 32bit builds
<RX14>
actually crystal itself isn't bad
<RX14>
it just needs a few gb
<RX14>
the spec suite needs > 4gb
fazibear has joined #crystal-lang
Renich has quit [Quit: leaving]
fazibear has quit [Ping timeout: 260 seconds]
theodorton has quit [Read error: Connection reset by peer]
theodorton has joined #crystal-lang
<FromGitter>
<drosehn> Btw, I meant to mention that the memory usage might not seem so painful on MacOS because Apple does tricks with compressing virtual memory.
<FromGitter>
<drosehn> I had turned that feature off long ago (when it first appeared, and was a little buggy), and just turned it back on in the last month. It's pretty impressive how much farther 16-gig goes when the compression is on!
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pawnbox has quit [Remote host closed the connection]
soveran has quit [Remote host closed the connection]
<RX14>
!memo jhass test
<DeBot>
RX14: Added memo for jhass.
<RX14>
!memo jhass could you update carc.in for 0.21.0 please?
<DeBot>
RX14: Added memo for jhass.
<RX14>
nice
akwiatkowski has quit [Ping timeout: 260 seconds]
<crystal-gh>
[crystal] RX14 opened pull request #4090: Change Spec::JUnitFormatter to use XML::Builder (master...feature/junit-rewrite) https://git.io/vyYKe