I Botched a Perl 6 Release And Now a Robot Is Taking My Job

Deconfusion note: if you're just a regular Perl 6 user, you likely use and only ever heard of Rakudo Star, which is a distribution that includes the Rakudo Perl 6 Compiler, some modules, and the docs. This post details a release of that compiler only, which gets released more often than Rakudo Star. So please don't think there's a new release, if Star is all you use.

Part I: Humans Make Errors

Today is the third Saturday of the month, which is an awesome day! It's when the Rakudo Perl 6 Compiler sees its monthly release. I was at the helm today, so I chugged along through the Rakudo release guide and the NQP release guide, whose release is part of the process as well.

We're All Green To Go

As I was nearing the end of the process, the first hint of a problem surfaced when a user joined the #perl6-dev IRC channel:

Sparrowdo automation. Part 6. Sparrowdo modules - getting a bigger things using light primitives.

This is what have been seen before:

Well, while keep writing a sparrowdo tutorial the tool keep growing too. Let me introduce something new and excited about sparrowdo automation - how one can easily create a higher level entities using so called sparrowdo modules.

Sparrowdo modules ...

So far we have talked about some sparrowdo primitives. They are light, they are small and they relate to a small specific tasks, under the hood they are just sparrow plugins with parameters - sparrowdo tasks.

Well, here is the list to recall a few:

  • System packages - package-generic plugin
  • CPAN packages - cpan-package plugin
  • Users and groups - are user and group plugins
  • Linux Services are represented by service plugin
  • And more and more and more ...

Perl Executing Browser version 0.2

I am happy to announce the release of version 0.2 of Perl Executing Browser (PEB) - our minimalistic HTML GUI for Perl desktop applications similar to Electron and NW.js.

Despite its low version number, PEB is already used in a small, specialized EpiDoc XML application called Epigraphista and is proving its usability.

PEB also contains an HTML interface for the default Perl debugger. The debugger output is displayed together with the syntax highlighted source code of the debugged script and its modules. Syntax highlighting is achieved using Syntax::Highlight::Engine::Kate CPAN module by Hans Jeuken and Gábor Szabó.

I will be glad to read any comments, suggestions or feedback.

New Log::Any Trial Release 1.041

I've just released a new Log::Any trial release. This release improves performance immensely when there are no log output adapters configured. This release also now returns the formatted log string from logging methods, allowing the log message to be used by a die or warn call.

Because of these changes, there is a very small chance of an incompatibility: Log::Any logging methods used to return whatever the configured adapter returned (this was undocumented and was not a feature). Now they always return the formatted log message.

So if you depend on Log::Any, please give Log-Any-1.041-TRIAL a test run through and report any issues to the Log-Any Github tracker.

Base conversion

Earlier this year I added some commands to the ntheory module, inspired by Pari/GP and Mathematica, to split numbers into digits and put them together again. Of course this isn't terribly exciting by itself since Perl has split and join, but with optional bases it gets more interesting.

I recently took a look at the various modules that do base conversion (at least 9 modules, plus various standalone subroutines). Each has slightly different features and interfaces, and the performance at the extremes differs by over 10,000x. I've made some internal changes to ntheory based on my tests, which should show up in the next release.

Add: This is for Perl 5. Perl6 has native support for base conversions for bases 2-36 and seamless Bigint support. It Just Works. For larger bases or alternate encodings, bbkr's TinyID module can be used.

Perl don't work well in "bash on ubuntu on windows"

I tried bash on ubuntu on windows in windows 10.

Perl have problems.

File::Find dosen't work

File::Find dosen't work. In bash on windows, hard link in directory count is "2" .

In this case File::Find assume the directory don't have sub directories.

        # File::Find::_find_dir
	if ($nlink == 2 && !$no_nlink) {
	    # This dir has no subdirectories.
	    for my $FN (@filenames) {
		if ($Is_VMS) {
		# Big hammer here - Compensate for VMS trailing . and .dir
		# No win situation until this is changed, but this
		# will handle the majority of the cases with breaking the fewest

		    $FN =~ s/\.dir\z//i;
		    $FN =~ s#\.$## if ($FN ne '.');
		next if $FN =~ $File::Find::skip_pattern;
		$name = $dir_pref . $FN; # $File::Find::name
		$_ = ($no_chdir ? $name : $FN); # $_
		{ $wanted_callback->() }; # protect against wild "next"


cpan, make don't work

File::Find not working means cpan and make don't work because ExtUtils::MakeMaker depend on File::Find.

This is very bad status for Per user on bash on windows.

I hope Perl porters communicate with Windows team and have efforts to fix Perl problem on bash on windows early.

Please discuss and report this problems.

CPAN Day! Raspberry Pi wiringPi API wrapper released

I was going to hold off on announcing my new WiringPi::API distribution until my larger project that depends on it is done, but since it's CPAN day, well...

The module wraps the majority of documented and undocumented functions in wiringPi.

wiringPi is a set of C libraries that allow you to muck with a Raspberry Pi, it's GPIO pins and other things.

You can import the C functions directly keeping their original names as is:

    use WiringPi::API qw(:wiringPi);

...import the renamed Perl functions:

    use WiringPi::API qw(:perl);

...or use the module in the normal OO way:

    use WiringPi::API;
    my $wpi = WiringPi::API->new;

Thus far, my module has/can:

Nqp-js update.

nqp-js/rakudo.js is now targeting ECMAScript 6

Scott McWhirter helped a ton with the transitions (as well as with some general cleanup).
Most of the modern browsers now support ECMAScript 6 so I feel it makes sense to target it.
When targeting old ones that don't we can use polyfills and compilers from ECMAScript 6 to 5.

After doing most of the obvious and promising nqp-js optimizations I'm focusing again on getting rakudo.js to work.
Before that I'm cleaning up the nqp-js code base to remove hacks that might shoot us in the back while working on rakudo.js

About blogs.perl.org

blogs.perl.org is a common blogging platform for the Perl community. Written in Perl and offering the modern features you’ve come to expect in blog platforms, the site is hosted by Dave Cross and Aaron Crane, with a design donated by Six Apart, Ltd.