Baby Moose struts his stuff

Well is still container day here in the Moose-pen.

So now that I have the 'execute_array' all fixed up and working I think I will carry on the same past and get the container to work with an array of 'classes'. In that end I created this little class;

package Test::User;
use Moose;
has username => ( is  => 'rw',
               isa => 'Str',);
has address => ( is  => 'rw',
               isa => 'Str',);
1;
Now the next thing I needed to do was make a test out of what I fixed yesterday;

Scott Wiersdorf on Functional Refactoring with Perl

Perl 5 Porters Mailing List Summary: June 6th-11th

Hey everyone,

Following is the p5p (Perl 5 Porters) mailing list summary for the past week.

Enjoy!

Portable GitHub system "GitPrep 2.6" is released - "Wiki system" is added. You can write documentation.

Portable GitHub system "GitPrep 2.6" is released at 2017-06-10.

Finally, "wiki" system is added. You can write documentation on GitPrep.

At first, Let's try
GitPrep example. You will find GitPrep is real portable GitHub system.

The features of GitPrep

I introduce the featrues of GitPrep for people who see GitPrep for the first time.

  • Github clone: GitPrep has the same interface as GitHub. All of repository, pull request, issue, and wiki is used.
  • Support issue system
  • Portable: You can install GitPrep on your own Unix/Linux server.
  • Only needs Perl 5.10.1+.
  • Smart HTTP support: you can pull and push repository via HTTP.
  • Built-in web server, and reverse proxy support.
  • CGI support.
  • SSL support.
  • Public key authentication support

Installation is very easy. You run only two commands. Difficult settings is unnecessary.

Even if you have troubles by your mistake, for example "git push -f origin master", you can access all of your git repositories directory and fix them.

All reporitories are yours. All repositories exists on your own server.

Yes Baby Moose had a Bug.

Well it is look at another module day here in the Moose-Pen.

So yesterday I ran into this problem;
DBD::DBM::st execute_array failed: 4 bind values supplied but 2 expected [for Statement "INSERT INTO user ( user.address, user.username ) VALUES( ?, ? )"] at …
Which rather peeved me as I tried the same code on two other DBs and the both ran. So it it just me? I took a look at example in the DBI POD;

$dbh->{RaiseError} = 1;        # save having to check each method call
$sth = $dbh->prepare("INSERT INTO staff (first_name, last_name, dept) VALUES(?, ?, ?)");
$sth->bind_param_array(1, [ 'John', 'Mary', 'Tim' ]);
$sth->bind_param_array(2, [ 'Booth', 'Todd', 'Robinson' ]);
$sth->bind_param_array(3, "SALES"); # scalar will be reused for each row
$sth->execute_array( { ArrayTupleStatus => \my @tuple_status } );

The Perl Conference Newsletter

In this issue:

  • Sunday Arrival Dinner
  • Tuesday Night Social: Get to know your fellow attendees!
  • Tutorials spaces still available
  • Call for Speakers: Lightning Talks
  • Call for Volunteers

Arrival Dinner - Sunday June 18

Arrangements have been made with Zikrayet Restaurant and Lounge to host a large crowd for The Perl Conference Arrival Dinner.

Given the nature of the place, it will be possible to make this event more of a come and hang out destination than we've been able to have in past years. Just the same we have an official time of 6pm set for the dinner so everyone can have a common plan for arrival.

This is an arrivals dinner but not necessarily the arrivals dinner. It's also a tradition that others who prefer smaller crowds and/or a more vegan-friendly menu organize an Alt Arrival Dinner.

For more information, or to note your intended attendance, please visit: https://github.com/dcbpw/tpc-2017-dc/wiki/Arrivals-Dinner#attendees

Blog engine in Perl 6

I've started to build a blog engine in Perl 6 using the Bailador web framework. Primarily as an example for the Bailador book, but if it works well it might even be used as a replacement for the blog engine running blogs.perl.org.

If you are interested, follow the GitHub project. If you'd like to help with the development, let me know, and I'll invite you to the Bailador Slack channel where we can discuss things. If you'd like to support the project financially then the best thing you can do is to back the crowdfunding campaign of my book about Bailador.

Add Structured Data to Log::Any

NB: The proposed changes have been accepted, there is now a release candidate waiting for your feedback.

A few months ago, I proposed a few changes to Log::Any with the goal of

  1. extending the API between applications and Log::Any::Adapters to allow passing hashrefs in addition to the log message
  2. allow applications to specify localized context data for Log::Any to add to each log message in that scope
  3. allow system owners to globally specify a default adapter other than Null

To get the bigger picture, you might want to revisit the original blog post and the reply by dagolden.

Based on the follow-up discussion on- and offline, I've tried to come up with a pull request that implements the proposed changes. To give it a try, clone it, and use my sample adapter to produce some output:

Baby Moose Has a Bug?

Well it get lucky postette day here in the Moose-Pen.

Well I left off yesterday a little worried that I was only testing half of the execute_array as I never actually got down into the DBI code of things. So I decided lets give it a try on that pre-installed 'DBD::DBM' that I used in my '10_crud_basic.t' test case as according to the DBI docs there shold be a defult implimentsion of 'execute_array''

Well I opened that sucker up and added this in

$container = [{username=>'Bill',address =>'ABC'},
              {username=>'Jane',address =>'DEF'},
              {username=>'John',address =>'HIJ'},
              {username=>'Joe',address =>'KLM'},
              ];
$user->create( $utils->connect(),$container);
and then got

The Perl Conference 2017 in DC - Schedule Posted

Check out our super-cool schedule, which links to talk and speaker details, at http://www.perlconference.us/tpc-2017-dc/schedule/!

The conference is a few weeks away (June 19-21 for the core conference, 18th and 22-23 for tutorials), so be sure to register and we'll see you soon!

Rakudo.js update - builds sanely and passes some spec tests

Rakudo.js now should build in much more sane manner and passes some tests.

In directory containing a checkout of the js branch of rakudo

Once you grab a node.js (tested with 7.10.0)

$ git clone https://github.com/rakudo/rakudo.git rakudo-js-fresh
$ git checkout js
$ cd rakudo-js-fresh
$ perl Configure.pl --backends=moar,js --gen-nqp --gen-moar
$ make js-all
$ ./perl6-js -e 'say(123)'
$ make js-spectest

Rakudo.js now passes some tests https://github.com/rakudo/rakudo/blob/js/t/spectest.js.data .
The remaining majority tests are stopped from passing mostly rampant bugs and a few missing bits.
OTOH some of the more advanced features like precompilation/junctions/multi methods (including callsame) work showing that once the building blocks work we can reuse the ton of good work put into Rakudo itself.

The Rakudo js has been recently update so it's now tracking nom clearly.
nqp.js is now using the new buffer IO and character based IO ops have been removed.

On the positive side our custom C++ synchronous extension that allowed piping to a spawned process has been deleted as it was a quick and dirty hack and the way node.js extensions are done is being currently reworked.

Perl 5 Porters Mailing List Summary: May 23rd - June 5th

Hey everyone,

Following is the p5p (Perl 5 Porters) mailing list summary for the past two weeks.

Enjoy!

An Array of Baby Moose

Its a little harder day here in the Moose-Pen.

Carrying on with adding to the '32_params.t' case I though today I would tackle one of the harder parts of prams and that is passing an array of params or in my case containers into a query statement.

So in my test I could have this;

$container = [{first_name=>'Bill',last_name =>'Bloggings'},
              {first_name=>'Jane',last_name =>'Doe'},
              {first_name=>'John',last_name =>'Doe'},
              {first_name=>'Joe',last_name =>'Blow'},
              ];

Updated list of drawing tools

After 11 years, I've updated the list! If you have any suggestions, please comment or email me.

Amazing: The preview feature worked. Submitting for the last time...

Type::Tiny 1.2.0 Released

So, Type::Tiny 1.2.0 (a.k.a. 1.002000 using Perlish decimals) is now available on CPAN.

Highlights since 1.0.0:

Strawberry Perl 5.26.0.1 released

Strawberry Perl 5.26.0.1 is available at http://strawberryperl.com

More details in Release Notes:
http://strawberryperl.com/release-notes/5.26.0.1-64bit.html
http://strawberryperl.com/release-notes/5.26.0.1-32bit.html

I would like to thank our sponsor Enlightened Perl Organisation for resources provided to our project.

Baby Moose Makes a Stand

Its fix typo and a little programming day here in the Moose-Pen.

Before I get back on track and start working on test case '32_params.t' but before that I had to clean-up in my code. Seems I had 'parenthes' all over the place when it should really be 'parentheses' so the last thin I did last night was clean all those up. Thank goodness for Padre and it search and replace functions.

Anyway on to '32_params.t' and the fist thing I did was cut out some tests from other places and put them in there as it made a little more logical sense. From 20_where_basic.t I striped out all the tests that check params and ended with these tests;

Perl 5.26.0 is now available!

I am delighted and proud to announce the release of Perl 5.26.0! You can read the release announcement.

It has been the first release done under my fidgety guidance. I want to take this opportunity to share my thoughts on this release and the process we had producing it.

SPVM is developed little by little

SPVM is the language to speed up numerical operation and array operation in Perl.
SPVM is deveoped little by little. I don't know it will be success to embded SPVM to Perl , but I introduce SPVM in this entry.


SPVM-solo

SPVM means Static Perl Virtual Matchine. This is Perlish static typed language.

Today I will introduce the test script. All variables have a static type and automatic type conversion is not done. Variable declaration can be omitted because it has type inference. It is designed to be same as Perl language as possible.

COMPLETION Report / Perl 6 IO TPF Grant

This document is the May, 2017 progress report for TPF Standardization, Test Coverage, and Documentation of Perl 6 I/O Routines grant. I believe I reasonably satisfied the goals of the grant and consider it completed. This is the final report and may reference some of the work/commits previously mentioned in monthly reports.

Thank You!

I'd like to thank all the donors that support The Perl Foundation who made this grant possible. It was a wonderful learning experience for me, and it brings me joy to look back and see Perl 6 improved due to this grant.

Thank You!

Completeness Criteria

Here are the original completeness criteria (in bold) that are listed on the original grant proposal and my comments on their status:

About blogs.perl.org

blogs.perl.org is a common blogging platform for the Perl community. Written in Perl with a graphic design donated by Six Apart, Ltd.