Jump to content

User talk:Rich Farmbrough: Difference between revisions

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
Content deleted Content added
Gandsnut (talk | contribs)
Line 618: Line 618:


[[User:Gandsnut|Gandsnut]] ([[User talk:Gandsnut|talk]]) 20:17, 11 April 2012 (UTC)
[[User:Gandsnut|Gandsnut]] ([[User talk:Gandsnut|talk]]) 20:17, 11 April 2012 (UTC)

== Link to diffs from dates on clean-up tags ==

Would it be possible to link the date to a diff showing the edit that tagged an article. Something like ''This article may require cleanup to meet Wikipedia's quality standards. The specific problem is: See talk page. Please help improve this article if you can. The talk page may contain suggestions. ([link February 2007])'' As far as I can tell {{User|Helpful Pixie Bot}} adds the dates to these tags, so I was hoping it could link to the diffs at the same time. There was a discussion started at the [[Template talk:Cleanup#Suggestion - Link to edit where tag was added|clean-up tag talk page]] about doing this for that tag, but it could possible be useful on all all the tags in [[Wikipedia:Template messages/Cleanup]]. As you run Pixiebot I was hoping you would have some ideas on how this could be implimented (it would be good if it could be added to old tags as well as new ones, but even just new tags would be a start) and steps needed to achieve it. [[User:Aircorn|AIR<font color="green">'''''corn'''''</font>]]&nbsp;[[User talk:Aircorn|(talk)]] 04:28, 13 April 2012 (UTC)

Revision as of 04:28, 13 April 2012


Template:Mirror me

  • This page has been viewed 383949 times. Plus one when I wrote this, plus you looking at it now.
Femto's Box
Th 3
Ed 5
Ms 7
Links
FAQ
Talk Archive Index
follow my blog
This page-

Drama free days
4652


From SignPost

Approximately 3% of editors account for 85% of contributions to the project, according to the statistician, and participation among this group has declined "even more sharply" than the active registered userbase in toto.

Funny that. Rich Farmbrough, 16:22, 9 September 2011 (UTC).[reply]

Quote

User:Kotinski - for whom I have always had respect.

...find something more productive to do with my life than continually trying to present rational argument to people who aren't interested, in an environment where only the drama-mongers and edit-warriors are rewarded. ... I'm feeling a great sense of relief that I won't be spending tomorrow or the next day arguing with morons about trivia.

I know exactly what he means. The "real life" equivalent to how I feel, I suppose, would be an engineer who is working on various jobs and is constantly interrupted by a couple of guys with Home Depot tool-belts (and probably propeller caps) telling him the advantage of triangular slotted screws over hex drive, and occasionally emptying his boxes of screws in the gutter, replacing random screws with the preferred variety, and calling the police, saying "someone is vandalising safety structures with dodgy screws"... And the police believing them.

Rich Farmbrough, 22:55, 26 March 2012 (UTC).[reply]

Blocked

I have blocked you for a period of one month. Period is probably moot - the talk at AN is of opening a request for arbitration. If this happens, I expect you will be unblocked to participate.

The automated sockpuppet category creation is a truly monstrous failure of end-user (ie the community) testing. The community neither needs nor wants those categories - mostly if it needed them, it created them as it went along. You have succeeded in badging editors as socks/masters who were actually cleared, and you are connecting IPs with sockmasters, which is in breach of the privacy policy...not to mention that since the cases are older than Noah, the IPs are almost certainly being used by some poor innocent by now. --Elen of the Roads (talk) 23:34, 30 March 2012 (UTC)[reply]

That is a severe case of bollocks. The user pages are in the categories regardless of whether text sits at the usercategory page. If the sock-tagging community is lackadasical in removing sock-tags, then that great big enormous huge carbuncle on their user page is the thing that is connecting the IPs with putative sockmasters in breach of hows-your-father. Good grief Charlie Brown! Rich Farmbrough, 23:45, 30 March 2012 (UTC).[reply]

Think of it as a change in routine, and a change of pace...

The block may be a blessing in disguise.

This may give editors who have had a hard time keeping your attention the opportunity to converse with you on a more meaningful level (i.e., not rushed).

Why would we want to?

Because you are an expert on many aspects of Wikipedia.

This vacation gives you valuable time to share your expertise and experience with other Wikipedians.

Personally, I have many questions for you... – The Transhumanist 03:55, 1 April 2012 (UTC)[reply]

Hey

I just took a look at your user page, to see if it provides any info on the types of questions you would be able to answer, and I noticed you're from London. Half my family tree lives around there.

I haven't been to London since 1997. Almost got killed jaywalking 3 times, due to looking the wrong way before crossing. I guess it's not "jaywalking" over there, because it's legal — for you it's just crossing the street. I think it's cool that you have the right to cross the street. Here we are subject to getting ticketed by the police if we cross anywhere other than at an intersection.

By the way, that you drive on the other side of the street over there makes it easy to spot foreigners. I noticed many of them looking the wrong way.

I also learned that clotted cream tea is not tea with clotted cream in it. :) The Transhumanist 04:46, 1 April 2012 (UTC)[reply]

Mm, worth going to Devon and Cornwall just for the cream teas. They are good elsewhere but that is the home of the cream tea. Rich Farmbrough, 16:15, 1 April 2012 (UTC).[reply]
Incidentally the Magna Carta had a provision for access to the highway I believe. Other rights, of course, have been eroded massively over the last 20-30 years. Notably extra-territoriality, retroactive legislation, double jeopardy, right to silence, the rights of the second chamber and just about anything that might be construed as "fundamental" has been thrown to the wolves of political opportunism. The few that have been saved have been as much as a result of the political opportunism of the opposition of the day as principled resistance by backbenchers. Of course historically it was ever thus, but the extremism of recent events, considering that we are not in the straitened circumstances of previous eras, is telling. Rich Farmbrough, 16:49, 1 April 2012 (UTC).[reply]

What is the most advanced operation you've used AWB for?

And how did you do it? The Transhumanist 05:38, 1 April 2012 (UTC)[reply]

Hm, well I did use it for checksum calculations and ISBN hyphenation. Basically I wrote a perl program to write a program to write the rulebase.The hyphenation was just a large number of rules, but the calculations involved implementing a partial arithmetic parser in regular expressions, including full addition and multiplication tables modulo 11 (and possibly 10 as well). Rich Farmbrough, 16:03, 1 April 2012 (UTC).[reply]

What do your bots consist of?

I.e., what are they made of (what languages, programs, etc.)? The Transhumanist 05:01, 1 April 2012 (UTC)[reply]

I use perl and AWB. For example the main bot runs on perl (because I was being blocked for using AWB), but if I have a one-off job it is often quicker to use AWB. Even there though I use perl to write some of the rules. Rich Farmbrough, 15:58, 1 April 2012 (UTC).[reply]

(For example, see: Outline of Mozambique)

How?   The Transhumanist 05:44, 1 April 2012 (UTC)[reply]

Kinda.

Use the list maker to make a list of "Links on page (redlinks only)".

Save the list to a text file.

Replace the carriage returns in the text file with "|". Copy the content.

Create a normal rule that replaces \[\[(<paste the contents here>)\]\] with $1

Run it against the page in question.

Rich Farmbrough, 16:13, 1 April 2012 (UTC).[reply]

Do you have a perl script...

...that opens a file, does something to it, and then saves it under a new filename?

I need to see how that is done. The Transhumanist 05:51, 1 April 2012 (UTC)[reply]

Er... so I think we covered this? Something like.
OPEN FILE, "<:utf-8" , "oldfile";
while (<FILE>){ $text .= $_}
CLOSE FILE

# do some stuff
$text =~ s/e/z/; #  replace e with z to even up letter usage across the universe a little

OPEN FILE, ">:utf-8" , "newfile";
print FILE $text;
CLOSE FILE

Rich Farmbrough, 16:08, 1 April 2012 (UTC).[reply]

Request for Arbitration filed

You are involved in a recently filed request for arbitration. Please review the request at Wikipedia:Arbitration/Requests#User:Rich Farmbrough and, if you wish to do so, enter your statement and any other material you wish to submit to the Arbitration Committee. Additionally, the following resources may be of use—

Thanks, Hersfold (t/a/c) 00:01, 2 April 2012 (UTC)[reply]

I've unblocked you so that you can participate in the aforementioned case. The Helpful One 00:06, 2 April 2012 (UTC)[reply]
Thanks, I think.... Rich Farmbrough, 00:27, 2 April 2012 (UTC).[reply]
Talk about taking things personally. Rich Farmbrough, 03:39, 2 April 2012 (UTC).[reply]
  • Rich, your latest change to the statement contained a change in position (so far as I can gather) as well as a reduction in length. I'm not sure if this was precipitated by my note, but such a pointedly brief statement is unnecessary. My request was that you reduce the length of your statement, not that you give no account at all. If you prefer to retain your longer statement then please do so; I would rather the other arbitrators have a longer but full account than none at all. Regards, AGK [•] 13:06, 2 April 2012 (UTC)[reply]
  • It was precipitated by your note. But it was based on the belief that I had merely stated my position about the substantive matter, rather than on whether there should be a hearing. Of course I like to think that if I were an Arbitrator I would say (as some did last time an attempt at an arb case was attempted) "Don't be absurd", so from that point of view, and from the point of view of the amount of work and time involved (remember we are all volunteers here) I don't want an arb case. However I am thoroughly sick and tired of Fram, and to a lesser extent CBM, and I asked for mutual interaction ban years ago. As Coren remarked, it is quite possible that "the time drain will be higher all told (by bouncing back to the AN boards again and again) until we settle the matter one way or the other". So resolving the issue now (i.e. in a few months... ) is probably preferable. Rich Farmbrough, 13:35, 2 April 2012 (UTC).[reply]

When shit gets crazy...

... it's best to only edit manually, I've found. Strictly manually. When things settle down again, automation can be brought back in. Best of luck in the upcoming case. --MZMcBride (talk) 04:32, 2 April 2012 (UTC)[reply]

Thanks. Rich Farmbrough, 12:05, 2 April 2012 (UTC).[reply]

Ultimate Spider-Woman

Excuse me, does anyone know how to download the image Ultimate Jessica Drew? It would be good on the second picture was visible on her face, in the plot of the Ultimate Spider-Man.--Shawnee Smith (talk) 12:12, 2 April 2012 (UTC)[reply]

Where is the image? You can probably right click on it and select "save image" depending on your browser. But you can't upload it to Wikipedia if it is not a "free" image (with a few exceptions) - this means anything that belongs to Marvel, DC etc. should probably not be used.
An exception is made for fair use images, these are typically limited to one per page, they must meet certain conditions, although comics pages I notice often have two, one to illustrate the comic, and one to illustrate the character the comic is named for.

Rich Farmbrough, 12:30, 2 April 2012 (UTC).[reply]

I hate semicolons!

It took me over an hour to realize my script didn't work because a semicolon was missing from the end of a line. The Transhumanist 19:53, 2 April 2012 (UTC)[reply]

If I had a shilling for every time I'd done that I'd be Rich! Rich Farmbrough, 20:19, 2 April 2012 (UTC).[reply]
And that, you are. – The Transhumanist 20:07, 3 April 2012 (UTC)[reply]

How do I pull a file into a scalar?

I opened a file, and tried to define a variable to be the contents of the filehandle, like this:

open(LIST,      "list.txt") || die("can't open list.txt: $!");

$list = LIST;            #pull LIST into a scalar variable (doesn't work)

print "$list"            # to see if it worked, display contents of $list, which should be the file list.txt

But it just prints out the filehandle!

What am I doing wrong? The Transhumanist 19:53, 2 April 2012 (UTC)[reply]

<LIST>
this will pull the next record in scalar context. If you set the record separator appropriately you should get the whole file. (It's a special variable $/ and $\ are the input and output separators.)

It is not clear from what you've said how to use the record separators. What should the line look like? Like this...?

$list = $/<LIST>;$\            #pull LIST into a scalar variable using record separators (doesn't work)

I'm trying to be able to use the following line of code to search a file for a string. If it's in there, I want the program to run a subroutine. If it's not in there I want the program to run a different subroutine.

$list =~ m/stringcheckingfor/   #look for string in contents of list.txt

I'm kinda stuck. The Transhumanist 21:27, 2 April 2012 (UTC)[reply]


OK, the angle brackets work, but it only prints out one line from the file. If what you meant was to put record separators in the file, then how do you search files without preprocessing every single file with the insertion of record separators? What if I want to search a file that's not a list and still be able to use the file for something else? The Transhumanist 22:22, 2 April 2012 (UTC)[reply]

When perl reads the file, it uses \n or \r\n or \n\r as the file separator (depending on OS) - this is stored in the variable $/ . If you set $/ to the end of file marker (or some sting you will not encounter) I would expect it would read the whole file. Other methods are using binary mode, or reading a line at a time:

while (<FILE>) {$text .= $_}

Rich Farmbrough, 22:54, 2 April 2012 (UTC).[reply]


I found something called "local" that seems to do the trick:

local $/;                # I don't know what this does, but it works.

open(LIST,      "list.txt") || die("can't open list.txt: $!");
$list = <LIST>;            #pull LIST into a scalar variable (doesn't work)
close(LIST);
print "$list"            # to see if it worked, display contents of $list, which should be the file list.txt

Though I'm not exactly sure why this works. The Transhumanist 23:18, 2 April 2012 (UTC)[reply]

It works because it makes the value of "$/" undefined -- a value that can never occur in a file. The "local" keyword does this as a side effect of its main purpose (controlling variable scope); you can get the same effect by assigning "undef" to the global copy of "$/", as in "$/ = undef;". --Carnildo (talk) 01:44, 3 April 2012 (UTC)[reply]
The disadvantage of futzing with global, of course, is that you (may) have to remember to reset it for the next file. And indeed this can be a problem with the local version too, see my example in the next section. Creating a new block purely to limit the scope of local $/ is probably nicer than what I did. Rich Farmbrough, 16:35, 4 April 2012 (UTC).[reply]

Checking each item from one list against another list

I have two lists. list1.txt and list2.txt.

local $/;                                # I don't know what local does
open(LIST1,      'list1.txt') || die("Can't read file 'list1.txt': [$!]\n");
open(LIST2,      "list2.txt") || die("Can't read file 'list2.txt': [$!]\n");

$list2 = <LIST2>;          #pull LIST2 into a scalar variable

while (<LIST1>){       # start while loop on the first list (angle brackets take next line of input)

# Search $list2 using the current line of input from LIST1 as the search string (I don't know how to do this yet without making the script fail to compile).  I plan to write two subroutines, one for true and one for false.
}

close(LIST1);
close(LIST2);


I can't believe I'm still in the file IO. I haven't even gotten to the guts of the program yet. Frustrating!   The Transhumanist 00:28, 3 April 2012 (UTC)[reply]

ok, local is creating a scoped version of $/ that is undefined. I haven't tried this but I suppose it works, and rather nicely in a way, since if you were using this in a block the default value of $/ would come back when you leave the block.

Now the problem you have is that you will slurp file 2 the same way you slurped file 1. So you need something like

local $/;                                # I don't know what local does
open(LIST1,      'list1.txt') || die("Can't read file 'list1.txt': [$!]\n");

$list2 = <LIST2>;          #pull LIST2 into a scalar variable
close(LIST2);#  close LIST 2 as early as we can
$/="\n"; # revert 

open(LIST2,      "list2.txt") || die("Can't read file 'list2.txt': [$!]\n");

while (<LIST1>){       # start while loop on the first list (angle brackets take next line of input)
   chomp; # Maybe?
   if ($list2 =~ /$_/){
       tru_sub();
   }
   else {
       false_sub();
   }
# Search $list2 using the current line of input from LIST1 as the search string (I don't know how to do this yet without making the script fail to compile).  I plan to write two subroutines, one for true and one for false.
}

close(LIST1);

ATB. Rich Farmbrough, 00:55, 3 April 2012 (UTC).[reply]


With bare bones subroutines...

local $/;                                # I don't know what local does
open(LIST1,      'list1.txt') || die("Can't read file 'list1.txt': [$!]\n");

open(LIST2,      "list2.txt") || die("Can't read file 'list2.txt': [$!]\n");
$list2 = <LIST2>;          #pull LIST2 into a scalar variable
close(LIST2);#  close LIST 2 as early as we can
$/="\n"; # revert

while (<LIST1>){       # start while loop on the first list (angle brackets take next line of input)
   chomp; # Maybe? (seems to work OK)
   if ($list2 =~ /$_/){
       tru_sub();
   }
   else {
       false_sub();
   }
}

close(LIST1);
print "\n\n";
print "$list2";    # display contents of list2.txt (as a test)

sub tru_sub {
     print "$_";       # display it on the screen so you can see that it is working
     print "\n\n"
}

sub false_sub {
     print "This subroutine doesn't do anything yet (other than print this message)\n";
}


The print functions show that the program actually works.

Now I have the places to put the guts. Thank you!

By the way, what is this part of the program called, an IO skeleton?   The Transhumanist 06:01, 3 April 2012 (UTC)[reply]

You are welcome. I'm not sure if there's a name, as such, "skeleton" is certainly widely used. Rich Farmbrough, 16:38, 4 April 2012 (UTC).[reply]

BD2412

Can someone tell them that there's a dab problem with Ellis Bent‎. Rich Farmbrough, 20:27, 2 April 2012 (UTC).[reply]

Installing Wikipedia locally

Is Wikipedia downloadable?

Do you have it installed on your computer? The Transhumanist 01:02, 3 April 2012 (UTC)[reply]

You can download the content (see database dumps on my user page) and the software (www.mediawiki.org). I have both, but not the content loaded into the software. Rich Farmbrough, 01:21, 3 April 2012 (UTC).[reply]
Cool. What does loading the content into the software entail?
I'm thinking that testing programs on a local copy of Wikipedia could be useful. Having access off-line would also be nice (my Internet access is sporadic).
I'm curious as to what use the database dump is without having it loaded into MediaWiki. What do you use it for? The Transhumanist 06:14, 3 April 2012 (UTC)[reply]
It's XML so you can write perl to scan it very easily. Also AWB has facilities to scan it. It's useful for identifying problem articles, making reports, doing statistics and extracting data. Rich Farmbrough, 12:50, 3 April 2012 (UTC).[reply]

The Signpost: 02 April 2012

GOCE impressive!

Wow!

  • Should be restored as it's original redirect.
  • The Ricardian Poets need a review, together with the associated works
  • A Key to Uncle tom's Cabin needs italics.

hi

Too bad about the block. If you're not careful, you might slip into 2nd place – Koavf only has a 100,000 edits to go to catch up! (Like I'm anyone to talk – I spend way too much time here.) — kwami (talk) 02:45, 4 April 2012 (UTC)[reply]

Well that would be cool, 100,000 more good edits would be a great contribution. Funnily enough I'm not currently blocked, since Arbfun is occurring - though I am instructed not to edit. The irony of trusting me not to edit when it suits, and yet physically blocking the account at other times is not lost on me. With a little luck it should resolve both the block and the ongoing history of harassment. Rich Farmbrough, 16:25, 4 April 2012 (UTC).[reply]

Halo Burger

An editor has been trying to alter the founding year of Halo Burger which was founded in 1923. Period. Yes, the restaurant has changed over the years and was originally Kewpee, but Halo Burger considers its founding year to be 1923 as it says on its logo. Please monitor the Halo Burger article more closely. Thanks. Steelbeard1 (talk) 14:20, 4 April 2012 (UTC)[reply]

Would love to help on this, currently can't. I do agree, though, that a logo is a perfectly valid source for a fouding year, though it would be better backed up with something else. Rich Farmbrough, 16:28, 4 April 2012 (UTC).[reply]

New Arbcom Case

An arbitration case involving you has been opened, and is located at Wikipedia:Arbitration/Requests/Case/Rich Farmbrough. Evidence that you wish the Arbitrators to consider should be added to the evidence sub-page, at Wikipedia:Arbitration/Requests/Case/Rich Farmbrough/Evidence. Please add your evidence by April 18, 2012, which is when the evidence phase closes. You can contribute to the case workshop sub-page, Wikipedia:Arbitration/Requests/Case/Rich Farmbrough/Workshop. For a guide to the arbitration process, see Wikipedia:Arbitration/Guide to arbitration. For the Arbitration Committee, Guerillero | My Talk 19:02, 4 April 2012 (UTC)[reply]

Thanks I already bagsed top bunk. Rich Farmbrough, 23:19, 4 April 2012 (UTC).[reply]

So that helpful bot...

Rich, you mentioned a couple weeks ago that it might be possible to bot-tag a series of articles, yes? Say, for example, the swimming event pages for Swimming at the 1996 Summer Olympics (i.e. men's 50 free, women's 50 free, men's 100 free... women's 4x100 Medley Relay): all 32 event pages are missing the preliminary results for those that made it back for finals. Each page has a "Non-Qualifiers" section, that could/should have an expand list tag inserted (and maybe even a note about the finalist prelims times are missing?). Is that something a bot could do? -- Hooperswim (talk) 02:52, 5 April 2012 (UTC)[reply]

Yes, once I overcome the "little local difficulty" of an Arbcom case and a month's block.... Rich Farmbrough, 03:37, 5 April 2012 (UTC).[reply]
Cool, cool. Thanks. -- Hooperswim (talk) 15:06, 5 April 2012 (UTC)[reply]

How many categories are there?

(Not including redirects). The Transhumanist 11:34, 5 April 2012 (UTC)[reply]

A Perl script library would be nice

You expressed interest in starting a library of Perl scripts.

You also mentioned Perl's usefulness for scanning the WP data dump.

Do you have any scripts for that? Example code for this would be extremely useful. They would give the rest of us an idea of what's possible. The Transhumanist 11:41, 5 April 2012 (UTC)[reply]

In AWB, how does the External Program Processing work?

(I couldn't find any documentation on this). The Transhumanist 11:47, 5 April 2012 (UTC)[reply]

I don't use this feature, though I played around with it once. Here's my set-up (possibly the default I don't know)

Program or script: perl

Arguments/Parameters: test.pl << test.txt >>test.txt

I/O file: test.txt

Presumably AWB saves the page to "test.txt" then runs "perl test.pl <<test.txt >> test.txt " (which might not work anyway) the reads text.txt into the page variable in AWB and carries on. Rich Farmbrough, 19:46, 5 April 2012 (UTC).[reply]

The traffic to this page

I'm impressed. You typically get just under 2,000 hits per month on your talk page. Last month it was almost 3,000. And this month so far there have been over 550 hits (in just 4 days).

You have an audience. You have readership!

You might consider that your page is a de facto (Wikipedia-related) blog page. Have you considered writing to your students here? Like posts on a blog. It's obvious that many people are interested in what you say and do. You have your very own venue. The Transhumanist 12:07, 5 April 2012 (UTC)[reply]

Well, there have been a lot of talk page stalkers (in the nice sense of the word) and a few in the not-so-nice. I don't think that this is necessarily a prime venue, for my ideas and thoughts, though I have created a few of the thousands of threads, see for example the two at the top of this page, the second sadly prophetic. I am also not really a blogger, although perhaps that is a failing I should work on. Rich Farmbrough, 14:53, 5 April 2012 (UTC).[reply]
Rather than philosophical or political threads, I was thinking more along the lines of the technical and practical, your sharing your expertise and methods. You are the most prolific editor and bot operator on Wikipedia. Power flows through your fingertips. It's wiki-lightning. Other editors are genuinely interested in how you do it, and the tools you use. Wikipedia lacks intelligible documentation in this area of endeavor. But you have wiki-skills that you have honed and fine-tuned for 8 years. There is nobody more qualified than you to mentor the Wikipedia community on how it's done. How to spot a widespread problem. How to fix it on thousands of pages. How to effectively apply power tools. AWB. Regex. Perl. Bots. And only you know what else. Teach us! There are hundreds of us who have reached the limit of what we can do manually. Show us how to automate. Help us transcend as you have. It'll be fun, for everyone. Besides, a little bird told me you have a month of free time on your hands. – The Transhumanist 16:02, 5 April 2012 (UTC)[reply]

Toggling annotations

I'd like to be able to provide (to the entire world) the ability to look at Wikipedia outlines in more than one way.

One thing I'd like the user to be able to do is, with the press of a button, make the annotations disappear (to view a bare uncluttered list). And with another press of the button, reappear.

You mentioned CSS as a possibility. Can that be made to hide/show all of the annotations on the page, and just the annotations, at the same time? The annotations appear at the end of each entry, after an en dash.

I think it would be nicer to have it as a feature of the MediaWiki software or even the browser, so that the (annotations off) mode applies to all outlines being viewed, until reactivated. That way the user wouldn't have to press the toggle for each page.

What are the software development options for creating a toggle, and what would they entail? The Transhumanist 11:27, 5 April 2012 (UTC)[reply]

That's really into more CSS than I am used to dealing with. I should think this would involve reloading a CSS class with something set to hidden or not. Rich Farmbrough, 19:49, 5 April 2012 (UTC).[reply]
I thought classes are defined and set on a css page, which would preclude toggling the state locally? Though worth looking into. Thanks for the tip. The Transhumanist 01:39, 6 April 2012 (UTC)[reply]

Dispute resolution survey

Dispute Resolution – Survey Invite


Hello Rich Farmbrough. I am currently conducting a study on the dispute resolution processes on the English Wikipedia, in the hope that the results will help improve these processes in the future. Whether you have used dispute resolution a little or a lot, now we need to know about your experience. The survey takes around five minutes, and the information you provide will not be shared with third parties other than to assist in analyzing the results of the survey. No personally identifiable information will be released.

Please click HERE to participate.
Many thanks in advance for your comments and thoughts.


You are receiving this invitation because you have had some activity in dispute resolution over the past year. For more information, please see the associated research page. Steven Zhang DR goes to Wikimania! 12:11, 5 April 2012 (UTC)[reply]

It's not clear what "When did you last participate in the following dispute resolution processes as an assistant? * means. Nor is "What dispute resolution forums do you use, and how frequently do you utilise them?" Rich Farmbrough, 19:38, 5 April 2012 (UTC).[reply]
Hey Rick. I've fixed the first one to clarify it's meaning. The second one has a clarifying comment below it. I'm not so sure how I can make it clearer, but would welcome suggestions. Steven Zhang DR goes to Wikimania! 04:16, 6 April 2012 (UTC)[reply]
It's the expression "use/utilise". I am fairly sure that I have commented on or in most types of dispute resolution, and been "subject" of three (AN, AN/I and ARBCom) - although these were not actions designed to resolve disputes, but to get the "plaintiff's" preferred outcome. I have posted new threads to AN or AN/I a couple of times, but they were not dispute related. Rich Farmbrough, 20:13, 11 April 2012 (UTC).[reply]

How do you write a bot?

I don't even know what one looks like.   The Transhumanist 16:20, 5 April 2012 (UTC)[reply]

It's hard to define a bot. The typical bot has three things it does
  1. Read some stuff
  2. Think about it
  3. Write some stuff.

If, for example, you are simply stress testing, then it would only do 1. A daily reminder bot might only do 3. A capture bot might just read a page and save a copy locally.

But if you are talking a typical 1-2-3 bot that reads WP pages, thinks about them and writes back an edited version, you could do worse than use the MediaWiki::API module. In pseudo-perl it would look something like this.

use MediaWiki::API;

# some initialisation and logging in code
my $mw = MediaWiki::API->new(); 
$mw->{config}->{api_url} = 'http://en.wikipedia.org/w/api.php';
$mw->login( {lgname="Sock-puppet", lgpassword => "drosswap" } ) || die  .....

# suppose we have a list of pages we made by some means...
open LIST, "<:utf8","list.txt";

while(<LIST>){ 
    $page=$_;
    my $ref= $mw->get_page ({title=>$page}); # reads the page and sets up the $ref structure
    my $timestamp = $ref->{timestamp};  # needed  to avoid (reduce) edit conflicts
    $text = $ref->{'*'};

    $text =~ s/e/q/gi; #replace e with q  throughout  

    $mw->edit({
         action        => 'edit',
         title         => $page,
         basetimestamp => $timestamp,
         test          => $text,
         summary       => "Q is better than E!"
    })
}
close LIST;

Perl resources

Can you recommend any good online Perl documentation that isn't perldoc? – The Transhumanist 16:38, 5 April 2012 (UTC)[reply]

Er... depends what for. I am constantly looking up syntax on sites like Tizag. But if I actually want to understand something I prefer perlmonks - they can get a little Zen like sometimes. Some of the modules are simply not documented well enough. Rich Farmbrough, 19:08, 5 April 2012 (UTC).[reply]
Following your recommendation, I Looked at Perlmonks in more depth and found their library of 200+ tutorials. This will be very helpful, to me and many others – I added the link to the Outline of Perl. Thank you. The Transhumanist 12:39, 8 April 2012 (UTC)[reply]

The Tea Leaf - Issue Two

Hi! Welcome to the second edition of The Tea Leaf, the official newsletter of the Teahouse!

  • Teahouse celebrates one month of being open! This first month has drawn a lot of community interest to the Teahouse. Hosts & community members have been working with the project team to improve the project in many ways including creating scripts to make inviting easier, exploring mediation processes for troubling guests, and best practices regarding mentoring for new editors who visit the Teahouse.
Springtime means fresh tea leaves...
  • First month metrics report an average of 30 new editors visiting the Teahouse each week. Approximately 30 new editors participate in the Teahouse each week, by way of asking questions and making guest profiles. An average of six new questions and four new profiles are made each day. We'd love to hear your ideas about how we can spread the word about the Teahouse to more new editors.
  • Teahouse has many regulars. Like any great teahouse, our Teahouse has a 61% return rate of guests, who come back to ask additional questions and to also help answer others' questions. Return guests cite the speedy response rate of hosts and the friendly, easy to understand responses by the hosts and other participants as the main reasons for coming back for another cup o' tea!
  • Early metrics on retention. It's still too early to draw conclusions about the Teahouse's impact on new editor retention, but, early data shows that 38% of new editors who participate at the Teahouse are still actively editing Wikipedia 2-4 weeks later, this is compared with 7% from a control group of uninvited new editors who showed similar first day editing activity. Additional metrics can be found on the Teahouse metrics page.
  • Nine new hosts welcomed to the Teahouse. Nine new hosts have been welcomed to the Teahouse during month one: Chicocvenancio, Cullen328, Hallows AG, Jeffwang, Mono, Tony1, Worm That Turned, Writ Keeper, and Nathan2055. Welcome to the Teahouse gang, folks!
  • Say hello to the new guests at the Teahouse. Take the time to welcome and get to know the latest guests at the Teahouse. Drop off some wikilove to these editors today, as being welcomed by experienced editors is a really nice way to make new editors feel welcome.

You are receiving The Tea Leaf after expressing interest or participating in the Teahouse! To remove yourself from receiving future newsletters, please remove your username here. -- Sarah (talk) 21:46, 5 April 2012 (UTC) [reply]

Answer questions that are key. Rich Farmbrough, 21:49, 5 April 2012 (UTC).[reply]

Can AWB be run on a locally installed Wikipedia?

This could be useful for developing a set of pages offline. Can this be done? How fast do you think it would run? The Transhumanist 01:54, 6 April 2012 (UTC)[reply]

It should run pretty fast, but not as fast as direct page access. Rich Farmbrough, 02:16, 6 April 2012 (UTC).[reply]
What do you mean by "direct page access"? The Transhumanist 07:46, 6 April 2012 (UTC)[reply]

Default variable in a nested While loop

In a perl script I'm writing, I have a While loop nested inside another While loop. What's the default variable for the current line in the nested loop? Is the default variable in the outer loop unaffected? The Transhumanist 01:33, 6 April 2012 (UTC)[reply]

It's the <> verb that populates the $_. $_ has global scope as far as I know. that's why one of the first things to do is often to assign it
while (<>) {
 my $title=$_;
 ....

This prevents "accidents" . Similarly it seem to be good practice to write

if (/([xyz])(abc)/){
     my $letter=$1;
     print "Found letter - $letter!\n";
}

instead of the simpler


if (/([xyz])(abc)/){
     print "Found letter - $1!\n";
}

so that if some other regex is used $letter will still have what we expect, while $1 can change in almost unexpected ways. Rich Farmbrough, 02:28, 6 April 2012 (UTC).[reply]

But I still need the global value in $_ for the outer While loop. Will reassigning it in the inner loop interfere with that? The Transhumanist 04:37, 6 April 2012 (UTC)[reply]

Dispute resolution survey

Dispute Resolution – Survey Invite


Hello Rich Farmbrough. I am currently conducting a study on the dispute resolution processes on the English Wikipedia, in the hope that the results will help improve these processes in the future. Whether you have used dispute resolution a little or a lot, now we need to know about your experience. The survey takes around five minutes, and the information you provide will not be shared with third parties other than to assist in analyzing the results of the survey. No personally identifiable information will be released.

Please click HERE to participate.
Many thanks in advance for your comments and thoughts.


You are receiving this invitation because you have had some activity in dispute resolution over the past year. For more information, please see the associated research page. Steven Zhang DR goes to Wikimania! 01:43, 6 April 2012 (UTC)[reply]

Rich, per Headbomb's and Newyorkbrad's responses at Wikipedia:Arbitration/Requests/Case/Rich Farmbrough/Workshop#All bots indefinitely blocked, I'd like to unblock Femto Bot; I agree that it performs useful tasks and shouldn't be blocked for the sake of being blocked. However, would it be possible to suspend its task 0 ("Creating needed monthly clean up categories") for the duration of the case? Per Wikipedia:Administrators' noticeboard/Incidents#User:Femto Bot, it would appear that there are some technical problems with the task and I think it may fall within the scope of the concerns that instigated the case. If you would suspend that task, I'd be more comfortable with unblocking the bot and would do so first thing in the morning if possible. Cheers! — madman 03:27, 6 April 2012 (UTC)[reply]

Also, it looks like no one notified you of the existence of that ANI thread. Sigh... madman 03:39, 6 April 2012 (UTC)[reply]
Yes, I found the thread anyway. There are not technical problems, the issues are around slight problems in migrating from one set of categories to the other, probably due to minor errors by the mover. A parallel move just occurred in the parent categories, and I was able to fix all the problems, I didn't mention them to the mover, because I thought I could simply catch any similar errors in when these were moved. I hadn't reckoned with the current foolishness. There should be no issues now. Rich Farmbrough, 02:32, 8 April 2012 (UTC).[reply]
Please let me know if/when you intend to suspend the task; I believe it would be irresponsible to unblock the bot while it's performing such a task, technical problems or no. Thanks, — madman 01:49, 9 April 2012 (UTC)[reply]

Template:Cite DMPN has been nominated for deletion. You are invited to comment on the discussion at the template's entry on the Templates for discussion page. Crisco 1492 (talk) 07:51, 6 April 2012 (UTC)[reply]

Your Arbitration evidence is too long

Hello, Rich Farmbrough. Thank you for your recent submission of evidence for the Rich Farmbrough Arbitration case. As you may be aware, the Arbitration Committee asks that users submitting evidence in cases adhere to limits regarding the length of their submissions. These limits, of User:HersfoldArbClerkBot/Length header/Words words and User:HersfoldArbClerkBot/Length header/Diffs diffs maximum, are in place to ensure that the Arbitration Committee receives only the most important information relevant to the case, and is able to determine an appropriate course of action in a reasonable amount of time. The evidence you have submitted currently exceeds at least one of these limits, and is presently at 716 words and 6 diffs. Please try to reduce the length of your submission to fit within these limits; this guide may be able to provide some help in doing so. If the length of your evidence is not reduced soon, it may be refactored or removed by a human clerk within a few days. Thank you! If you have any questions or concerns regarding the case, please contact the drafting Arbitrator or case clerk (listed on the case pages); if you have any questions or concerns about this bot, please contact the operator. On behalf of the Arbitration Committee, HersfoldArbClerkBOT(talk) 20:01, 7 April 2012 (UTC)[reply]

Friendly notification regarding this week's Signpost

Hello. This is an automated message to tell you that, as it stands, you are set to be mentioned in this week's Arbitration Report (link). The report aims to inform readers of The Signpost about the proceedings of the Arbitration Committee in a non-partisan manner. Please review the draft article, and, if you have any concerns, feel free to leave them on the talkpage (transcluded in the Comments section directly below the main body of text), where they will be read by a member of the editorial team. Please only edit the article yourself in the case of grievous factual errors (making sure to note such changes in the comments section). Thank you. On behalf of The Signpost's editorial team, LivingBot (talk) 00:00, 9 April 2012 (UTC)[reply]

Perl WikiProject

I've started Wikipedia:WikiProject Perl, to give you something to do after your block is lifted.   :)   By the way, I've started its talk page off with our Perl-related threads. Those might be useful or interesting to someone. The Transhumanist 23:46, 9 April 2012 (UTC)[reply]

The Signpost: 09 April 2012

I see they turned to you

I figured it was only a matter time till they turned their attention to you. The community is losing contributors at the cyclic rate. It seems as though the drama llamas are starting at the top of the list of editors with the most contributions and working down. You, Me(Kumioko), I see drama on Magioladitis's page, etc. Its truly sad to see what the place has devolved into. 71.163.243.232 (talk) 01:31, 10 April 2012 (UTC)[reply]

Everyone involved is generally sensible, so they'll work it out. Rich lost his patience and pissed some people off. He'll get his patience back, and they'll get over it. It's human nature. The Transhumanist 05:23, 10 April 2012 (UTC)[reply]

YGM: WP article 'Edgar Steele' and WP editor "trojancowboy"

Hello, Rich Farmbrough. Please check your email; you've got mail!
It may take a few minutes from the time the email is sent for it to show up in your inbox. You can remove this notice at any time by removing the {{You've got mail}} or {{ygm}} template.

Gandsnut (talk) 20:17, 11 April 2012 (UTC)[reply]

Would it be possible to link the date to a diff showing the edit that tagged an article. Something like This article may require cleanup to meet Wikipedia's quality standards. The specific problem is: See talk page. Please help improve this article if you can. The talk page may contain suggestions. ([link February 2007]) As far as I can tell Helpful Pixie Bot (talk · contribs) adds the dates to these tags, so I was hoping it could link to the diffs at the same time. There was a discussion started at the clean-up tag talk page about doing this for that tag, but it could possible be useful on all all the tags in Wikipedia:Template messages/Cleanup. As you run Pixiebot I was hoping you would have some ideas on how this could be implimented (it would be good if it could be added to old tags as well as new ones, but even just new tags would be a start) and steps needed to achieve it. AIRcorn (talk) 04:28, 13 April 2012 (UTC)[reply]