Comments (7)
It's not affecting anyone as far as I know, and I suspect it's a generic gotcha with Raku rather than an actual bug. But I've left this bug open as a warning and reminder to any future maintainer that something brittle and poorly understood may be going on. And as an invitation for anyone who knows better to proffer an improvement.
from raku-template-mustache.
Odd. I get something different:
An operation first awaited:
in block at t/11-iterable.t line 71
in block <unit> at t/11-iterable.t line 38
Died with the exception:
A worker in a parallel iteration (hyper or race) initiated here:
in block at /home/cbwood/.zef/store/Template-Mustache-1.2.3.tar.gz/Template-Mustache-1.2.3/lib/Template/Mustache.rakumod (Template::Mustache) line 577
in block at /home/cbwood/.zef/store/Template-Mustache-1.2.3.tar.gz/Template-Mustache-1.2.3/lib/Template/Mustache.rakumod (Template::Mustache) line 566
in sub format at /home/cbwood/.zef/store/Template-Mustache-1.2.3.tar.gz/Template-Mustache-1.2.3/lib/Template/Mustache.rakumod (Template::Mustache) line 537
in sub format at /home/cbwood/.zef/store/Template-Mustache-1.2.3.tar.gz/Template-Mustache-1.2.3/lib/Template/Mustache.rakumod (Template::Mustache) line 397
in sub format at /home/cbwood/.zef/store/Template-Mustache-1.2.3.tar.gz/Template-Mustache-1.2.3/lib/Template/Mustache.rakumod (Template::Mustache) line 397
in method render at /home/cbwood/.zef/store/Template-Mustache-1.2.3.tar.gz/Template-Mustache-1.2.3/lib/Template/Mustache.rakumod (Template::Mustache) line 295
in block at t/11-iterable.t line 57
Died at:
Cannot invoke object with invocation handler in this context
This is from Raku v2021.02.1-64-gbf67b1f71
from raku-template-mustache.
Yes, Xliff, I get the same error as you. I'd accidentally switched to an older Raku and forgot to switch back before reporting.
from raku-template-mustache.
This bug is triggered by calling .Str
or .gist
on the HyperSeq prior to calling .map
. In Template::Mustache
, the call to .Str
is in sub resolve
, and removing line 426 causes the test case to succeed.
This is a golfed down test case:
my $hyp = (gather { take $(:line("line 1")) }).hyper;
# XXX THIS TRIGGERS THE SUBSEQUENT CRASH
$hyp.Str;
my $result = $hyp.map({ .raku }).join;
put "RESULT «{$result}»";
What remains to be resolved is whether this is a bug in Template::Mustache or in Rakudo.
from raku-template-mustache.
Workaround pushed as b1fbd76. I don't know what the right solution really is, so leaving this open.
from raku-template-mustache.
Nice job, @softmoth!
from raku-template-mustache.
What's the current state of the issue?
from raku-template-mustache.
Related Issues (20)
- Not working after glr merge HOT 4
- Test fails on Windows as of 2016.11 HOT 3
- Build fails on Rakudo 2017.3-232-gfbc6697
- Template Mustache is test fails while installing Bailador HOT 1
- Weird ordering in rendered output HOT 1
- Template::Mustache fails to install/recognize dependencies HOT 3
- The digit 0 doesn't print HOT 1
- Tag names can only contain what is considered an <ident> HOT 1
- Content of section tags spills out HOT 2
- Triple Mustache doesn't work when the field name contains a minus HOT 2
- Failing to install with Rakudo master HOT 2
- Inheritance templates HOT 5
- Speed problems HOT 7
- Doubt about Mustache specification HOT 6
- Cannot install Template::Mustache with rakudo 2019.11 HOT 1
- Allow HTML escaping to be disabled HOT 1
- Can't install Template::Mustache HOT 2
- Fails to install on windows HOT 2
- deprecation warning HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from raku-template-mustache.