User talk:Dudemanfellabra

From Wikipedia, the free encyclopedia
  (Redirected from User talk:NationalRegisterBot)
Jump to: navigation, search

Commons linker on List of scheduled monuments in West Somerset[edit]

Thanks for your help with the bug which removed the image and refs on List of scheduled monuments in Mendip. I'm also working on List of scheduled monuments in West Somerset & just created a new article for Barle Bridge and an associated category on commons to which I added both of the numbers from the National Heritage List for England (one for scheduled ancient monument and the other for Listed building). When I run your script on the list page it doesn't pick up that the new category has been created on commons. I was wondering if I need to do anything else to make it work?— Rod talk 21:27, 4 March 2015 (UTC)

This is a known issue with the script (which I need to add to the documentation actually.. I'll do that soon). If a category/image transcludes more than one template on Commons, only the last one on the page is seen by the script, due to its implementation using category sortkeys. Since the last one on the category you're trying to add has the number for the listed building status, it won't match the scheduled ancient monument number. The fix is to simply move the template with the scheduled ancient monument number to be transcluded after the one with the listed building number. Then the script will correctly see the category. In the (far) future, it may be possible for the template to recognize both transcluded templates, but for now, unfortunately, this is the only way to fix the problem. Sorry :\--Dudemanfellabra (talk) 00:47, 5 March 2015 (UTC)
OK I tried reversing the order of the templates on commons and then tried to run the script again on List of scheduled monuments in West Somerset, however it now gives an error message saying "row mismatch" and I can't find the bracket problem likely to cause it - any ideas?— Rod talk 21:36, 6 March 2015 (UTC)
The problem was with your recent addition of a row template, which you called with {{English Heritage listed building row}} rather than the more-often used {{EH listed building row}}, which was the previous location of the template. The code is set up to look for a specific title, and inclusion of any redirects/aliases will throw it off. I will look into adding support for redirects, but because of the way the script is set up, the redirect titles must be manually programmed in. For now, I changed the added row to use "EH" and was able to run the script, but I did not add the tagged category so that you could see it for yourself. Sorry again for the trouble.--Dudemanfellabra (talk) 08:10, 7 March 2015 (UTC)
Thanks again - all of the EH templates were recently renamed "for clarity" and, unfortunately I don't know enough about templates and how they work etc to recognise the difficulties this might cause.— Rod talk 08:15, 7 March 2015 (UTC)

Need help with Slovakia[edit]

Hi Dudemanfellabra, long time gone since we met last time. Your script AddCommonsCatLinks.js does not work with de:Liste der denkmalgeschützten Objekte im Okres Bratislava I/A–F, image File:Bratislava Beblavého 01 01.jpg and ObjektID 101-11/0. I already checked the parameter configuration, looks good to me. Could there be a problem with the slash in the ObjektID? Would be fine if you could provide help. --Herzi Pinki (talk) 12:56, 5 March 2015 (UTC)

You are correct that everything in the list and on the image was set up correctly. The problem was with commons:Template:Cultural Heritage Slovakia. The category sortkey included by the commons template, which this script uses to identify the sites, was padded left to be 15 characters long while the script was looking for only 8. Every other compatible Commons template is padded to be 8 characters long, so I changed the Slovakia template to use 8 as well. Once the job queue catches up and the change is applied to each of the category members, the script should work on this list. If it does not, let me know. Thanks for pointing that out!--Dudemanfellabra (talk) 03:13, 6 March 2015 (UTC)
Thx, but be careful, there are IDs like 706-3869/0, 207-10492/17 around, with a length of > 8. --Herzi Pinki (talk) 05:58, 6 March 2015 (UTC)
Your script does work also for IDs longer than 8 characters. Green tickY. Padding is added to allow sorting of numbers as alphanumerical values. But this will work too as all the IDs I have seen have a structure like nnn-mmmm/k, at least for the first part which is always numeric and three digits. On the other hand left padding will not solve the problem for the second and third part. A concise padding would mean nnn-00mmmm/00k or similar. Just my ideas, no need to change anything for you. --Herzi Pinki (talk) 06:30, 6 March 2015 (UTC)
Correct. If an ID is longer than 8 characters, the entire ID is used.. the ID is only padded if it is smaller than 8 characters. The padding has the effect of making an ID a minimum length. The problem before was that the padding on the sortkey went all the way out to 15 characters, forcing all IDs to be that long, but the script only forced the length to 8, so the only IDs that would have worked were the ones longer than 15 characters so neither padding made a difference anyway. By shrinking the sortkey padding back to 8, everything matched up as expected.
As far as the other padding concerns you raised, none of that type of padding for individual components of a given ID is necessary. As long as the ID in the row template exactly matches the ID in the commons template (the slash and hyphen are manually entered by the user, no padding by the template), everything works. Even if the ID was entered in parts, as in, e.g. de:Vorlage:Denkmalliste2 Schweiz Tabellenzeile, the script can combine it all and pad everything correctly. There hasn't been a case that's come up so far that has broken anything, so long as the entire code is padded to 8 characters.--Dudemanfellabra (talk) 07:31, 6 March 2015 (UTC)

A tooltip for stubs?[edit]

Do you have any plans of putting a tooltip in the NRHPstats script to show which articles are stubs, like there is for NRIS-only articles? It seems like it would be really useful for lists like Kane County, Illinois, which has one stub in 68 articles. TheCatalyst31 ReactionCreation 11:52, 9 March 2015 (UTC)

Good idea. I've added a tooltip for stubs now, but because many counties have a huge amount of stubs, I've limited the output to the first 10 of them. I've done likewise with the NRIS-only, unassessed, and untagged tooltips as well to keep it uniform. If you want more than the first 10, you must fix some of the displayed ones :).--Dudemanfellabra (talk) 20:14, 9 March 2015 (UTC)
Great, thanks! I think that's a good compromise, since I'm mostly worried about long lists with a handful of stubs than the lists that are half stubs (or NRIS-only, etc.) TheCatalyst31 ReactionCreation 01:36, 10 March 2015 (UTC)


I thought it rather simple; that's why I didn't provide any additional sources. From the Weekly List, we get the address of 4432 State Route 305 for the Southington Township School, which when Googled, returns results for Chalker and for Southington. One of the first results in a Google search for "southington township school" is a historical marker in front, which says basically "Chalker High School is NR-listed", although providing a slightly wrong date; the website's a program of the SHPO, so presumably we can trust them unless there's reason not to. Finally, if you go past the place, you see two historic school buildings; I wasn't sure which one was which until finding the RemarkableOhio page and a photo from the SHPO. Sorry that I wasn't clearer before. Nyttend (talk) 00:19, 13 March 2015 (UTC)

@Nyttend: Thanks for pointing me to those sources. I added a little to the article to make clear it was listed. It seems Ohio is about to get a searchable database for NRHP nominations next month, so maybe we will finally be able to get rid of that unnecessary light green color at WP:NRHPHELP#Online!--Dudemanfellabra (talk) 05:38, 13 March 2015 (UTC)
I doubt that we'll change the weird color. Everything has been down for a good long while; it's been months since it was last possible to access the one-page profiles that were formerly provided (example link, compared with what it should look like), and they called those a searchable database. I expect they're just putting back what they had before. No complaints if I'm wrong, however :-) Nyttend (talk) 09:59, 13 March 2015 (UTC)

The commons script is showing up on the WikiProject NRHP talk page[edit]

I'm guessing this is just another exception to running it on all pages with "National Register of Historic Places" in the title, but the button for the Commons script is showing up on Wikipedia talk:WikiProject National Register of Historic Places. It's more funny-looking than anything else, but I figured you might want to know. TheCatalyst31 ReactionCreation 23:09, 23 March 2015 (UTC)

Actually the title of the page had nothing to do with it. The problem was that in the "Can't access NRHP" section, a user had included code for {{NRHP row}} but did not actually transclude the row (it was inside nowiki tags). The way the script works is it loads the wikitext of every page you visit and if it finds a row in the code, it places the button there. If you had clicked the button, you would have gotten an error saying a row was malformed since the script didn't find any rows in the parsed HTML code. I've just updated the script to ignore any rows in nowiki or pre tags, and that required a little more code than I thought originally, but I think I have it working now. The only problem I can tell exists is if a page transcludes NRHP row (or any of the other row templates the script supports) and then includes the exact same text inside nowiki/pre tags somewhere else on the page, the script freaks out. I think that situation will probably be extremely rare if not non-existent, though, so I probably won't have to worry about it. Though the new code shouldn't affect anything in theory, you never know if there might be some weird case out there (which you seem to be pretty good at finding haha), so if you encounter any problems, let me know. Thanks as always for pointing that out!--Dudemanfellabra (talk) 07:00, 24 March 2015 (UTC)

Mississippi plantations[edit]

Hello again, thanks for creating the Georgia article. Since you live in Mississippi, would you be interested in helping me create more pages about historic plantations in Mississippi? I am quite fascinated by the history, even though I live in London! I created a few of them on the NRHP, but there are still many left to create.Zigzig20s (talk) 05:08, 27 March 2015 (UTC)

@Zigzig20s: Well, even though I live in Mississippi, I have spent much of my time with content development only around the Meridian, Mississippi area (that article included) and not much in the rest of the state. The only reason I created the Georgia article is because you requested it and it looked like it wouldn't take that much time/effort to do since it was a fairly small site haha.
I spend more of my time now doing more rote maintenance tasks and creating useful scripts for others to use to assist them with monotonous tasks. I don't usually spend much time on Wikipedia actively creating content, so I probably won't be creating many articles. That said, I'm more than happy to help you in any way you might need, e.g. finding sources, contacting local officials (although being outside of the country, that might be a bit difficult), or sorting out something that may be obvious to me as a local but not to a Londoner/non-Mississippian like yourself. Feel free to post here or at the NRHP project talk page with any questions like that, as you can see others do pretty regularly.--Dudemanfellabra (talk) 19:48, 27 March 2015 (UTC)
That's a shame. Natchez and Port Gibson are very interesting historically. Perhaps you will change your mind and give in! Let me know if you are ever able drive up there and take some pictures. Thank you.Zigzig20s (talk) 10:32, 28 March 2015 (UTC)


Hi Dudemanfellabra, can you please add support for Saxony to the German section of your AddCommonsCatLinks.js:

        "Germany - Saxony":{
            "RowTemplate":"Denkmalliste Sachsen Tabellenzeile",

Don't know what the unverified parameter means. Thx. --Herzi Pinki (talk) 21:04, 4 April 2015 (UTC)

@Herzi Pinki: I've added the designation to the code and also the documentation. Do you know if ErfgoedBot has any automated output for this template like it does for others? If so, I'd like to add the link(s) to the documentation. As for the unverified parameter, you were correct in setting it to false. If you have verified that the template/category/everything else is set up correctly so that the script will recognize it, it is verified.--Dudemanfellabra (talk) 03:50, 5 April 2015 (UTC)
Thx, works like a charm. I'm still in the process of setting it up, ErfgoedBot does not know about Saxony until now. I will tell you as soon as I'm thus far. Concerning verified, it is just a suppression of checks in your script (as someone else does)? Happy Easter. Find your eggs. --Herzi Pinki (talk) 08:35, 5 April 2015 (UTC)
As you might remember from setting up several of the other templates on de-wiki, the script will throw an error if the row template does not add the CSS class='vcard' to each row:

Zeilenfehler! Dies kommt möglicherweise von einer falsch formatierten Zeilenvorlage. Alle Zeilenvorlagen müssen class='vcard' enthalten, damit das Skript sie identifizieren kann. Sollte {{ROWTEMPLATE}} class='vcard' beinhalten, bitte ich um eine Nachricht auf :en:User_talk:Dudemanfellabra, und ich werde versuchen, das Problem zu beheben. Das Skript wird jetzt beendet.

The reason it throws an error is because it finds some number of row templates in the wikitext but that number doesn't match what the script sees in the parsed HTML of the page since it can only find HTML rows with class='vcard'. Sometimes, however, the error is not due to the lack of the CSS class but because of some malformed row in the wikitext (e.g. one that doesn't include closing braces or only a single brace rather than two). The default alert, however, just says be sure to add class='vcard' and isn't helpful for finding malformed rows. If the template has been verified to have class='vcard' and works properly most of the time, the unverified parameter should be set to false, which allows the script to give a more informative error, which actually hasn't been translated into German for that GUI. Think you could help with that? The English version is:

Row mismatch! This is probably due to an incorrectly formatted row template in the wikicode, e.g. a missing }} or a misplaced HTML comment. If you cannot find the error on this page or believe it is due to something else, please let me know at :en:User_talk:Dudemanfellabra, and I will try to resolve the problem. The script will now exit itself. Sorry!

If you're willing, there is also another string that needs to be translated into German for when an image or category that is already placed in a row cannot be found on Commons (probably a typo) and a replacement is found:

The existing image and/or category cannot be found on Commons. Selecting a match here will replace the existing one(s). If you do not want to replace anything, choose Keine Kategorie/Bild hinzufügen.

Thanks for the help!--Dudemanfellabra (talk) 21:39, 5 April 2015 (UTC)

uups, missed that one. sorry:

Fataler Tabellenzeilenfehler! Mögliche Ursache ist eine falsch formatierte Tabellenzeilenvorlage im Wikicode, z.B. eine fehlende schließende Vorlagenklammer }} oder ein schlecht plazierter html-Kommentar. Falls du den Fehler auf der Seite nicht finden kannst, oder eine andere Ursache vermutest, dann bitte ich um eine Nachricht auf :en:User_talk:Dudemanfellabra, und ich werde versuchen, das Problem zu beheben. Das Skript wird jetzt beendet.


Das in der Tabellenzeile angegebene Bild / die angegebene Commons-Kategorie existiert nicht auf Commons (Mögliche Ursache ist z.B. ein Tippfehler hier oder die Umbenennung auf Commons). Durch eine Auswahl kannst du die aktuellen Einträge überschreiben. Willst du nichts überschreiben, dann wähle bitte Keine Kategorie/Bild hinzufügen.

I've added a reason (as a proposal): (Mögliche Ursache ist z.B. ein Tippfehler hier oder die Umbenennung auf Commons), which would translate to possible reasons are typos here or renames on Commons)

--Herzi Pinki (talk) 19:13, 7 May 2015 (UTC)

Historic buildings in Meridian[edit]

Hi, I happened to be looking at some of the articles on NRHP properties in Meridian, and wanted to say again how much I appreciate all your work on all of these and the related articles for the city and county. You did such a terrific job bringing all this history to life and giving perspective on Meridian's place in the state and regional history. While working in the government, I worked in historic preservation so have made minor changes on some building articles related to my understanding of some of the development process. Thanks for all your work - Parkwells (talk) 16:26, 14 April 2015 (UTC)

You have an off-by-one error in NRHPstats[edit]

If one of the NRHP lists has ten or more stubs/NRIS-only articles/etc., NRHPstats will only display the first nine articles in the tooltip instead of the first ten like it says. I'm pretty sure the problem is in this line of code (and the corresponding ones for the other categories):

if (stubs<10) StubStr += str + "\n"

That should be "if (stubs<=10)", I think, since you increment stubs before modifying StubStr. TheCatalyst31 ReactionCreation 04:39, 20 April 2015 (UTC)

You are correct! I didn't think about the fact that I was incrementing before checking; all fixed now! Thanks for pointing that out!--Dudemanfellabra (talk) 05:12, 20 April 2015 (UTC)

Multiple refnum[edit]

What is the proper thing to do in the following case: an NRHP row where the refnum has multiple numbers, properly separated by commas. When a user uploads a image with the upload image link, it looks like the file gets tagged with the commons NRHP template using refnum,refnum which the commons NRHP template doesn't recognize, resulting in the National Register of Historic Places without known IDs category being added. An example is Is the right thing to do 1) hand edit the commons description to remove all but one refnum or use multiple NRHP templates 2) Get the commons NRHP template to recognize the num[,num...] case as valid and add the proper category, 3) get NRHP row to put only one refnum in the url for UploadWizard, 4) or something else?

And, isn't it time to remove the campaign=wsm from the NRHP row template? Generic1139 (talk) 21:39, 23 April 2015 (UTC)

Thanks for pointing this out; I've just fixed the NRHP row code to only include the first refnum in the URL. I don't think modifying the Commons template to accept more than one refnum is the way to go since it uses the refnum as a sortkey in the known IDs category, and having more than one refnum can't translate to having more than one sortkey. I would say putting multiple templates on a single image/category is the way to go for that.
Also about campaign=wsm, that is what allows us to add the NRHP template to the images. Yes it has the unfortunate side effect of putting it in WSM categories; without it, the refnum doesn't show up at all. I don't really know much about campaigns on Commons, but if there is a way to make a new one that isn't tied to WSM but also adds the NRHP template, that's probably the way to go.--Dudemanfellabra (talk) 06:00, 24 April 2015 (UTC)
The change to only include the first refnum will solve the problem, thanks.
About the WSM campaign, I see that Harej won't be able to genericize the campaign for a while, and that building a new campaign requires privs. Building a campaign looks pretty simple, though, using the WSM campaign as a model makes an NRHP campaign easy to do. The header and thanks templates don't require any privs. Any commons admin could upload into campaign space. Know any? Generic1139 (talk) 12:46, 24 April 2015 (UTC)

Wiki loves earth[edit]

Hi Dudemanfellabra, do not remember why your scripts shouldn't work for WLE. Can you please add the following to the German section of your AddCommonsCatLinks.js:

Register Naturdenkmäler in Österreich

            "TopCatName":"Category:Natural monuments in Austria with known ID",
            "RowTemplate":"Naturdenkmal Österreich Tabellenzeile",

In Austria there are 9 federal states, all of them use their own, independent numbering schema. 6 of them use different, non-conflicting numbering schemes (different prefixes), so they will not cause ID clashes. Vienna, Vorarlberg and Styria all use simple numbers and I did not check for id clashes (nor can I make an assumption for the future). In our template we use the Region-ISO parameter to make the ids unique. Any idea on how to solve that in a secure way? --Herzi Pinki (talk) 19:46, 7 May 2015 (UTC)


Just wanted to let you know that I recently ran through Kansas, where I spent a day photographing NRHP sites in Atchison and then hit a few sites in other counties. Think that I've pushed the state up over 50% illustrated.

While you've probably never photographed Kansas, and may never have set foot in the state, you nevertheless deserve considerable credit for these photos. The Progress page is a great incentive for me to get out and shoot NRHP sites, and each time a new set of maps comes out, I spend some time flipping between the new map and the previous one and gloating over the counties whose color I've changed.

Thanks yet again for developing the page and its maps. Through its effect on at least one editor, it's helping to achieve our long-term goal of getting complete photographic coverage. — Ammodramus (talk) 12:49, 11 May 2015 (UTC)