Welcome the channel on the development of Cro, a set of libraries for building reactive distributed systems, lovingly crafted to take advantage of all the Raku Programming Language has to offer (cro.services). This channel is being logged for historical purposes.
Set by lizmat on 24 May 2021.
00:09 lizmat joined 06:57 Xliff joined
Xliff \o 06:57
Is there a way I can stop a SIGINT? 06:58
08:18 sena_kun joined 09:14 Geth left, Geth joined
jnthn Write a signal handler that does nothing? 09:19
start react whenever signal(SIGINT) { #`( disregard ) }
10:37 sena_kun left 10:38 sena_kun joined
Xliff \o 12:12
Hi, jnthn. Thanks for the suggestion. 12:13
Sadly, my Cro-based server died just now after a solid 23 hours of operation.
Died with: Unhandled exception in code scheduled on thread 8
malloc(): smallbin double linked list corrupted
What's the best way to debug that?
I have the core file and hourly telemetry reports from the server if that will help. 12:20
Ah.. nope... no core file. Said it dumped, but it's not here. 12:21
jnthn Cro is pure Raku code, so it'd either be a VM bug or a bug in a module with native code. Presumably the core file can be used to get a stack trace. Without the core file, not much can be said. 12:32
Xliff OK, thanks. 13:05
jnthn Ah, also a tip: make sure the MoarVM is built with debug symbols, as that'll give more info. 13:15
Xliff Yep. I do that every week. :) 13:19
jnthn: Are Cro::WebApp templates compiled to code or bytecode? 15:52
Could precompiled templates be stored on a database, for example?
16:08 xinming left
jnthn Turned into Raku code that is EVAL'd on first use of the template 16:12
Xliff Ah, thanks. 16:23
Does ::Template support comments?
I'd like to remove parts of a template without actually removing them. 16:24
Could such be added by the simple rule of: 16:27
token sigil-tag:sym<comment> { '<#' .+? '>' }?
Ah, no... because I need it to NOT end on any ending tag. 16:28
So maybe...
token sigil-tag:sym<comment> { '<#' .+? '#>' }? 16:29
jnthn Maybe the syntax should be <#> ... </#> 16:32
Xliff Don't mind either. How would yours be implemented? 16:34
token sigil-tag:sym<comment> { '<#>' .+? '</.#>' } 16:35
Would I need a <sequence-element>* in there? 16:36
Nope. Neither one works. 16:49
Last one fails with "Type check failed in assignment to @!children; expected Cro::WebApp::Template::AST::Node but got Any (Any" and that's probably because of the
action on sigil-tag
Wionder if this will work... method sigil-tag:sym<comment>($/) { make Nothing.new; } 16:53
16:53 sena_kun left
Xliff Oh shit! That worked! =D 16:56
18:32 xinming joined
Xliff jnthn: Is there a way to trace cro routes? 18:33
Geth cro-webapp: Xliff++ created pull request #78:
- Adds the ability to write comments between <#> and </#> tags
jnthn Depends what you mean by trace; there's CRO_TRACE=1 which traces the progression through the pipeline 20:55
Xliff No. I want the ability to trace the router. But thanks. 21:52
21:53 lizmat_ joined 21:55 patrickb_ joined 21:56 ecocode____ joined 21:58 ecocode___ left 21:59 patrickb left, lizmat left, jjatria left, ecocode____ is now known as ecocode___, patrickb_ is now known as patrickb 22:10 jjatria joined 22:35 Xliff left