The answer comes down to two words: Security and Reliability.
As a bonus, less work on your part.
It's surprising to find that there are modules on CPAN that aren't using
ppport.h that could stand to benefit from it.
ppport.h is a file that is part of the Devel::PPPort distribution. As you
know, Perl has evolved over the years, adding new features, and new API for XS
writers to use. Some of that is to support the new features, and some to make
tasks easier to accomplish. ppport.h implements portions of the API that
people have found desirable to have when a module gets installed in a Perl that
was released before that API element was created. You can write your module
using the latest API, and have it automatically work on old Perls, simply by
#including ppport.h in your XS code. ppport.h generally provides support for
an API element as is reasonably practicable, with many supported to 5.03007.
Spoiler Alert: This weekly challenge deadline is due in a few days from now (on November 28, 2021 at 24:00). This blog post offers some solutions to this challenge, please don’t read on if you intend to complete the challenge on your own.
Task 1: Add Binary
You are given two decimal-coded binary numbers, $a and $b.
Write a script to simulate the addition of the given binary numbers.
The script should simulate something like $a + $b. (operator overloading)
This blog post describes a common task my colleagues ask often about repeating a dynamic string in a defined token and adding some or, and, = in between, plus finishing smartly.
This is a quick reminder that the quarterly San Diego Perl Mongers meeting will be occurring on Tuesday evening, starting at our normal time of 7 PM PDT. As has been for the last several meetings, we’re going to meet online, as in-person meetings are discouraged, and online meetings seem to be a bit more popular.
Tau Station, "the free-to-play narrative sci-fi
MMORPG (TM)", has a nicely complex database. Currently, we have 190 tables with
740 relationships between those tables. DBIx::Class does an amazing job at
managing that complexity, since each relationship is simply an accessor on the
DBIx::Class::Row object.
However, there is a subtle issue when using those relationship accessors. Using
a relationship accessor creates a new Row object and stores it in the calling
object. This behavior can easily leads to duplicate DBIC Row objects for a
single database row. At best, the duplicates cause wasted resources duplicating
the Rows. At worst, they cause update anomalies, since updates done to one Row
object are not seen by the duplicate objects.
With a highly-connected schema like we have in Tau Station, trying to handle the
object duplication can pretty soon feel like we're trying to handle
rabbits in Australia.
In order to avoid this Row duplication, we have developed a cache of DBIC Row
objects that is shared within the application. In most cases, this allows us
to ensure that we have one DBIC Row object per database row while processing
an HTTP request, avoiding those subtle update anomalies.
Spoiler Alert: This weekly challenge deadline is due in a few days from now (on November 21, 2021 at 24:00). This blog post offers some solutions to this challenge, please don’t read on if you intend to complete the challenge on your own.
Task 1: JostSort
You are given a list of numbers.
Write a script to implement JortSort. It should return true/false depending if the given list of numbers are already sorted.
Example 1:
Input: @n = (1,2,3,4,5)
Output: 1
Since the array is sorted, it prints 1.
Several months ago I read a tutorial on module creation. It got me thinking about releasing some of my modules. I got to work getting my code organized. At the time I had all of my work in the directory for my site. So I moved my general purpose modules to their own directory and then started reading more about what is needed to get a module published on CPAN.
I first installed Module::Starter. It seemed like a good place to start, but then Dist::Zilla was suggested, so I installed it. Most recently Minilla suggested, and now it is installed. The problem is, I do not know which one to use. Do I use any of those at all, or is there yet another packaging module (with executable) out there?
Spoiler Alert: This weekly challenge deadline is due in a few days from now (on November 14, 2021 at 24:00). This blog post offers some solutions to this challenge, please don’t read on if you intend to complete the challenge on your own.
Task 1: Workdays
*You are given a year, $year in 4-digits form.
Write a script to calculate the total number of workdays in the given year.
For the task, we consider, Monday - Friday as workdays.
If you haven't heard, Hacktoberfest has now become opt-in, to reduce the number of spammy, or pointless, pull requests that people were doing, to get the t-shirt.
In this post I'll describe how to opt your repos in, how to find opted-in repos, and why your repo might not be turning up in searches.
So if you've got repos with issues that you'd be happy to receive pull requests on,
add the topic hacktoberfest, and make sure that your repo turns up in searches.
Spoiler Alert: This weekly challenge deadline is due in a few days from now (on October 31, 2021 at 24:00). This blog post offers some solutions to this challenge, please don’t read on if you intend to complete the challenge on your own.
Task 1: Two Friendly
You are given 2 positive numbers, $m and $n.
Write a script to find out if the given two numbers are Two Friendly.
Two positive numbers, m and n are two friendly when gcd(m, n) = 2 ^ p where p > 0. The greatest common divisor (gcd) of a set of numbers is the largest positive number that divides all the numbers in the set without remainder.
Not words you want to hear late at night before you're going to bed: "we accidentally launched our Kickstarter."
That's right, the Tau Station MMORPG Kickstarter is live and we didn't mean to. However, apparently Kickstarter doesn't allow you to "unlaunch" a campaign.
It may not have been our launch window, but we're owning this.
Share this!
Tau Station is the world's first Biblio-RPG. It's a massive, immersive, narrative sci-fi MMO. Missions in most games are things like "kill five rabid dogs and get a dagger." BORING. Our missions are rich, immersive, short stories where you control the outcome.
It's 400,000 plus lines of Perl, with a PostgreSQL backend.
In my last post, a meta issue for modules: bug tracking, I had noticed a problem with the bug tracking link for a module and discussed that problem. In the comments, one person said he preferred rt.cpan.org. I began thinking about where to have bugs tracked for my modules. Since I have not published one yet, this is something I would like to know. I would like to know the good and bad and ugly of the various systems to make a more educated choice on issue tracking before my first release.
Are there specific issues with GitHub's, GitLab's, or other issue tracking systems making rt.cpan.org the more attractive choice?
On a side note, I prefer reporting issues on sites like GitHub and GitLab since my reply email is hidden and does not get spammed, or at least not yet. However, my cpan.org email address gets a lot of spam, so much spam I had to make a rule to send all email I receive through that address to junk mail. So, should I receive a reply to an issue I opened on rt.cpan, I may miss it since it ends up in my junk mail, which I do not check that often.