Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

User Posts

( [id://1135479]=superdoc: print w/replies, xml ) Need Help??
Posts by jdporter
User Profile Element: CPAN author ID in Perl Monks Discussion
8 direct replies — Read more / Contribute
by jdporter
on Apr 04, 2022 at 14:38

    We have just added a new field to the user profile: CPAN author ID. You can put your PAUSE author ID in this field. When someone views your profile, they will see it and it will be a link to the corresponding page on metacpan.

    Do you like this? It can be removed if it is unpopular.

    Update:

    I have turned off users' ability to set this value themselves.
    The field itself is still supported, and you can see it displayed on certain monks' homenodes.
    If you would like to have your CPAN ID on your homenode, please just /msg gods with your request. Thanks!

    Update 2:

    As a convenience, I have added the CPAN IDs to user profiles based on the info provided in this CPAN api (about 30 monks) and in this MetaCPAN api (about 185 monks). Interestingly, there was almost no intersection between those two sets of data.

    I reckon we are the only monastery ever to have a dungeon staffed with 16,000 zombies.
In Praise of Web 1.0 in Meditations
2 direct replies — Read more / Contribute
by jdporter
on Dec 15, 2021 at 13:39

    The Web Is F**ked, by Kev Quirk

    Web 1.0 wasn’t just about personal blogs, GeoCities and scrolling marquees. Oh no, dear reader. We had our own version of social media back in the day - the web forum.

    They were fantastic pieces of software that allowed communities to come together, discuss specific topics and generally hang out.

    If you read no other part of it, I encourage you to

    Familiarise yourself with POSSE and make your site the single source of truth for all your online content.
Perl/Raku community involvement survey in Perl News
4 direct replies — Read more / Contribute
by jdporter
on Jul 16, 2021 at 13:53

    Episodic Volunteering in Free/Libre/Open Source (FLOSS) Communities - a survey by kudra

    TPF announcement

    ... research to understand episodic, or occasional, participation in the Perl and Raku communities... The results of the research will be provided as a TPF report and will assist the community in improving practices for managing episodic participation to provide insights into what FLOSS projects could do to become more sustainable.
Markdown is now supported for comments, experimentally in Perl Monks Discussion
4 direct replies — Read more / Contribute
by jdporter
on Jun 09, 2021 at 15:15

    Due to "popular demand", PerlMonks now supports Markdown formatting for writeups. Note: Initially, Markdown is only supported for comments (aka notes). If everyone likes it, we will extend the capability to root-level posts as well (SOPW posts, etc.)

    Some relevant past discussions:

    Sorry it took me a minute to implement this feature. :-D

    To enable the use of Markdown in your comments, go to your User Settings and change the "Format writeups as:" selection from 'conventional' to 'markdown'.

    Be aware that this is a global setting. You can't select the format at the time you submit the writeup.

    When you are looking at a writeup entry box (textarea), you will see a short note immediately above it indicating which markup you can use.

    This change was actually relatively simple to implement, since modules for converting markdown to HTML already existed.
    I would like to know if there is any demand for any other Lightweight markup languages.
    For example, we could add support for Textile or some flavor of wiki text.

    I reckon we are the only monastery ever to have a dungeon staffed with 16,000 zombies.
TPF's Marketing Strategy for the Next Two Years in Perl News
1 direct reply — Read more / Contribute
by jdporter
on May 20, 2021 at 15:56

    This is actually from last August, but I haven't come across it until today.

    Marketing Strategy for the Next Two Years (perlfoundation.org)

    The question for us, I think is: What impact will this have on PerlMonks? Will we be required to modify/restrict our "look and feel" to conform to the branding guidelines set by TPF?

    I reckon we are the only monastery ever to have a dungeon staffed with 16,000 zombies.
History of PerlMonks' Perl News in Meditations
No replies — Read more | Post response
by jdporter
on May 04, 2021 at 16:37

    History of PerlMonks' Perl News

    Originally, the Perl News section of the site was not a place where ordinary monks could post. Rather, it was designed to be a local "feed" of Perl-related news extracted from another site. That other site was called Perl News, at news.perl.org.

    Posts to the section were created in the name of a 'bot' account, perlnewsbot. (Presumably, perlnewsbot was the actual name of the automated background process. In all likelihood, it was vroom who created and ran the perlnewsbot.

    vroom announced New Perl News Section on 2000-07-21, and perlnewsbot made its first post that same day.

    news.perl.org was, of course, already in operation by then. the earliest snapshot in the Wayback Machine is dated 2000-01-05.

    *Confusingly, the perlnewsbot user account has a creation date of 2000-07-26 — several days after its first few posts. One possible explanation is as follows: Initially, posts were being inserted in the Perl News section by a different bot user or by some process outside of the perlmonks user-level framework. After the perlnewsbot user was created, the ownership of the prior existing posts was transferred to him. However, this is conjectural.

    perlnewsbot's run only lasted a few months, however.

    Its last post was on 2001-02-16, apparently having been halted even before news.perl.org went dark.

    The last post on news.perl.org was on 2001-03-18, with the following item:

    See use Perl;

    Perl News is going away soon (one might argue it already has :). use Perl is this site's sister site, having all the same news, plus reviews, articles, discussions, and more. The coincidence of the technical difficulties of this site and the imminent migration of use Perl to its new home makes now a good time to finalize the closing of Perl News.
    Indeed, barely a month later news.perl.org was gone.

    Even though use.perl.org - the site called use Perl; - was the ostensible replacement for news.perl.org, at least as a source of news, the perlnewsbot was never updated to pull news from use.perl.org.

    (Interestingly, use.perl.org met a similar fate a few years later. The last post there, announcing its imminent shutdown, was on 2010-09-08.)

    vroom opened up the Perl News section for posting by ordinary users in late May of 2002. Prior to that time, only perlnewsbot was able to post there. (vroom posted there himself once or twice before that, using his godly powers. The couple other posts you now see in that section prior to that date were originally posted in other sections and later moved to Perl News.)

    A noteworthy figure in all of this is Chris "pudge" Nandor. He was the man behind news.perl.org and use.perl.org. He was one of the lead developers of Slash, the perl-based engine which powered both Slashdot and use.perl.org. Of course, Slash was also the predecessor of the Everything Engine, upon which PerlMonks is built. Both are products of the tiny outfit called Blockstackers Intergalactic (BSI). Sound familiar? That is where vroom, nate, and other early creators of PerlMonks were working at the time. However, pudge says that he didn't really know those guys, even though he was in the same place at about the same time. Different projects. Here's what he told me in a private correspondence:

    I wasn’t involved in perlmonks much, but I did news.perl and use.perl. IIRC perlmonks was based on Everything, which was a separate project from Blockstackers, which also created Slash, from which Slashdot and use Perl resulted.


    Relevant chronology:

    • 2000-07-21 - New Perl News Section - vroom creates the perlnews nodetype and dbtable. He posts an announcement, saying that perlnewsbot "just sucks news from the RDF from news.perl.org".
    • 2000-07-26 - Perl News Going Away? - perlnewsbot posts here the article from news.perl.org about that site's impending demise.
    • 2001-01-09 - Perl News Credits - KM alludes to a discussion he had with pudge about it.
    • 2001-02-16 - YAPC::Europe Set for Amsterdam in August - perlnewsbot's final post.
    • 2001-04-13 - The PerlNewsBot - A user notices that perlnewsbot is no longer posting to Perl News. A commenter suggests that the bot could be redirected to use.perl.org.
    • 2001-06-04 - Is brother perlnewsbot ill? - Another exchange almost identical to the preceding.
    • 2001-06-23 - News section not being kept current? - A user notes that the section is inactive and suggests opening it up to general users, with possibly a level requirement.
    • 2001-07-28 - Why no new news? - A user notes that the section is inactive. In a comment, the OP says" "if there's no automatic news gathering (ok fine), then why doesn't vroom (or whoever) open up the news area to manual posted news?"
    • 2001-08-06 - Member Submitted News - A user suggests opening up the Perl News section to posting by general users.
    • 2001-10-21 - randomnode - (patch) - vroom creates the first patch to mention perlnews (node type) by name in its code.
    • 2001-11-03 - New use for old news - A user suggests opening up the Perl News section to posting by general users.
    • 2002-02-11 - What's happening with Perl News? - "Since it appears to be dead, Perl News should either be killed or opened up to general postings." A commenter again suggests that the bot could pull news from use.perl.org.
    • 2002-02-22 - Make (Perl News == Use.Perl.Org) Or Is This Heresy? - A user suggests that the Perl News section link directly to use.perl.org, vs reposting content here.
    • 2002-04-26 - "Perl News" is old - A user notes that "the most recent news in the Perl News node date back to one year ago."
    • 2002-05-07 - Posting Unrelated News Items - A user suggests reactivating Perl News as a "normal" section (rather than mirroring off-site news stories) where monks can post links to relevant stories." This sparked a surprising amount of debate.
    • 2002-05-24 - tye notes in the editors' wiki:
      I fixed several problems with the (apparently rather hastilly) reopened Perl News section. There is one potentially ugly problem remaining...

      Since the work to set up the (unduely complicated) "approval link type" and related baggage has not been done, you can't "approve" Perl News nodes. This means that the approval nodelet won't show. Which means that some ppl can move a node to Perl News after which only editors will be able to move it anywhere else. The best solution is probably to create all of the baggage and make Perl News items require approval.

      You have been warned. Also, if this becomes a point of abuse before an enterprising god gets around to adding "approval" for Perl News, then the ability to move to/from Perl News can very quickly be taken away by deleting one line from writeupmover.
      At the same time, in the pm-port wiki:
      I fixed several things wrong with Perl News, which included changes to: perlnews (the node type), Perl News, perlnews display page, preview settings, vote settings, writeupmover, and perhaps a few others.

      The first problem was that adding new Perl News actually added new poetry. Of course, I noticed this because someone added news so I wanted to move it into the proper section. However, the node type of perlnews uses the dbtable of perlnews in order to add a linklocation field which makes it impossible to simply "move" to/from that node type. But search internal code shows that this extra field is not used currently so I changed the node type to not use that dbtable and then made "Perl News" one of the available move-to types. And I made it so you can vote on "Perl News" nodes.

      Since the work to set up the (unduely complicated) "approval link type" and related baggage has not been done, you can't "approve" Perl News nodes. This means that the approval nodelet won't show. Which means that some ppl can move a node to Perl News after which only editors will be able to move it anywhere else. The best solution is probably to create all of the baggage and make Perl News items require approval.
      Oddly, I don't see any patches from tye (nor tye&) in that timeframe, nor any patches to any of the nodes he mentioned. I believe he must have mucked with all those codes directly, using godly powers. (He became a god on 2002-02-01.)
    • 2002-05-24 - Dr. Damian Conway to speak at Dallas/Ft. Worth Perl Mongers meeting in June - This post by atcroft in the Perl News section was probably originally in Meditations and then moved. I think so because there are records in the db showing that it was at one point "approved", yet perlnews never needed approval (at that time).
    • 2002-05-26 - Perl News reopened - vroom's announcement: "I've reopened Perl News. You can now post Perl News stories there. Currently approval isn't necessary." Unfortunately, modifications to a nodetype definition (e.g. its authorized creators & writers) are not tracked and do not use the patch system. maintenances are; but unfortunately perlnews did not get its sole maintenance - perlnews maintenance create - until three months later (2002-08-23).
    • 2002-05-26 - Boston Perl Classes - uri posts what is likely the first human-user submission directly to the newly opened Perl News section. Its records in the db show no evidence of having been approved.
    • 2002-05-26 - Voting in Perl News - A user thanks vroom for reviving the Perl News section, and offers this insight:
      "One of the reasons it was originally taken out of commission was that many people thought http://use.perl.org did a better job of providing Perl-related news. While use.perl.org is an excellent site, it focuses on larger stories and probably wouldn't publish most module releases and other small events. I think Perl News would be an excellent place to announce these smaller events."
    • 2002-05-31 - Perl Monks User Search - (patch) - VSarkiss submits a patch to Perl Monks User Search "so nodes in the newly re-opened Perl News will show up"; he notes it in the pmdev wiki. Interestingly, this patch was never applied; and also interestingly predates any other patches to Perl Monks User Search! Even so, the code was updated to include perlnews at some point before the first applied patch.
    • 2002-08-23 - perlnews maintenance create - (patch) - the first patch to mention "news" in its reason.
    • 2010-10-13 - What exactly counts as "Perl News"? - Interesting commentary, especially by tye.
The Categorized Questions and Answers section has been decommissioned in Perl Monks Discussion
1 direct reply — Read more / Contribute
by jdporter
on Apr 09, 2021 at 15:47

    Effective today, the section of PerlMonks known as "Categorized Questions and Answers" is no longer in service. The section page is a tombstone. It is no longer possible to post Categorized Questions or Answers. It is also not possible to search such posts via Super Search. It wouldn't be useful anyway, because all of the posts which were Categorized Questions have been converted into SOPW posts. Likewise, all posts which were Categorized Answers have been converted into replies to those SOPW posts. In each case, the name of the CatQA 'section' in which the Question was placed has been added to the SOPW post as a keyword.

    The intent of the CatQA section will, going forward, be fulfilled by a new system, whereby "good" questions (in SOPW) and their "best" answers will be given a special flag, as well as relevant keywords. (Update: This is fulfilled in Illuminations!)

    Some documentation and linkage changes remain to be made. If you see any, feel free to sent a msg to SiteDocClan, pmdev, or gods, depending.

    For more information on this change, see prior discussion: RFC: Better Best Answers Gets Real

    I reckon we are the only monastery ever to have a dungeon staffed with 16,000 zombies.
Banal Configuration Languages in Meditations
1 direct reply — Read more / Contribute
by jdporter
on Feb 26, 2021 at 14:10

    This is so great, I have to share it here. This guy nails it on the head. (Spring, we're looking at you.)

    I suspect a lot of abuse of config files comes from moving logic out of source code for bad reasons. There are good reasons for not hard-coding, say, ports and service endpoints in your source code, because it makes it easier to run the code in different environments. However, there are also bad reasons for taking things out of code. A couple that I have encountered:

    Pride in creating a "generic" system that can be configured to do all kinds of new things "without touching the code." Reality check: only one or two programmers understand how to modify the config file, and changes have to go through the same life cycle as a code change, so you haven't gained anything. You've only made it harder to onboard new programmers to the project.

    Hope that if certain logic is encoded in config files, then it can never get complicated. Reality check: product requirements do not magically become simpler because of your implementation decisions. The config file will become as expressive as necessary to fulfill the requirements, and the code to translate the config file into runtime behavior will become much more complex than if you had coded the logic directly.

    Hope that you can get non-programmers to code review your business logic. Reality check: the DSL you embedded in your config file isn't as "human readable" as you think it is. Also, they're not going to sign up for a Github account and learn how to review a PR so they can do your job for you.

    Marketing your product as a "no code" solution. Reality check: none for you; this is great! Your customers, on the other hand, are going to find out that "no code" means "coding in something that was never meant to be a programming language."
Detect whether a writeable filehandle has closed? in Seekers of Perl Wisdom
10 direct replies — Read more / Contribute
by jdporter
on Jan 13, 2021 at 12:26

    In my perl program I open a subprocess for writing via a pipe. It appears that this child process can decide to exit at times I don't expect. Is it possible to detect that the filehandle to the pipe is no longer usable? As it is, I now get SIGPIPE occasionally, but it seems to happen later, after I've possibly already written (tried to write) additional lines to the pipe. I want something synchronous.

    I've seen Scalar::Util's openhandle function. Does it work on pipe handles, opened for writing?

    TIA!

    I reckon we are the only monastery ever to have a dungeon stuffed with 16,000 zombies.
Export (extract) Mozilla Firefox Bookmarks in Cool Uses for Perl
1 direct reply — Read more / Contribute
by jdporter
on Mar 05, 2020 at 12:52

    Probably reinventing the wheel, but...

    (NB: You may need to cpan install DBD::SQLite first.)

    use DBD::SQLite; use strict; use warnings; =pod This program reads a file named places.sqlite which is found somewhere under your folder named Mozilla/Firefox/Profiles You pass the pathname of this file as a command-line argument. This program outputs html. =cut my $dbfile = shift; $dbfile or die "Usage: $0 <path>/places.sqlite \n"; -r $dbfile or die "Unreadable $dbfile\n"; $dbfile =~ /\bplaces\.sqlite$/ or die "File should be places.sqlite\n" +; my $dbh = DBI->connect("dbi:SQLite:dbname=$dbfile","","") or die "Erro +r opening db $dbfile\n"; my $bookmarks = $dbh->selectall_hashref("select * from moz_bookmarks", +'id'); my $places = $dbh->selectall_hashref("select * from moz_places",'id +'); # construct the tree: my $root; for my $b ( values %$bookmarks ) { if ( $b->{parent} ) { my $p = $bookmarks->{ $b->{parent} }; push @{ $p->{children} }, $b; } else # yep, there's exactly one. { $root = $b; } } # produce the html: local($,,$\)=("\t","\n"); sub walk; # because it recurses. sub walk { my $depth = shift; my $n = shift; my $indent = "\t" x $depth; if ( $n->{type} == 2 ) # folder { print $indent . ($depth?"<li>":'') . "<h4>$n->{title}</h4>"; if ( $n->{children} ) { print $indent . "<ol>"; for my $c ( sort { $a->{position} <=> $b->{position} } @{ +$n->{children} } ) { walk($depth+1,$c); } print $indent . "</ol>"; } $depth and print $indent . "</li>"; } else # leaf bookmark { my $link = $n->{title}; if ( $n->{fk} and $places->{$n->{fk}} and $places->{$n->{fk}}{ +url} ) { my $url = $places->{$n->{fk}}{url}; $link =~ /\S/ or $link = $url; $link = qq(<a href="$url">$link</a>); } else { $link =~ /\S/ or $link = "$n->{type}:$n->{id}"; } print $indent . "<li>$link</li>"; } } walk(0,$root);
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2024-03-29 08:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found