Template talk:ISO 3166 code/Archive 1

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Nièvre bug[edit]

{{editprotected}} The department of Nièvre in France should have a hyphen (-) before the code (58). --Stepheng3 (talk) 20:02, 23 July 2009 (UTC)[reply]

Done, plus some other stuff. --- RockMFR 22:54, 23 July 2009 (UTC)[reply]
Thank you! --Stepheng3 (talk) 20:25, 24 July 2009 (UTC)[reply]

Excessive transclusion[edit]

This template is called from {{Infobox settlement}}, and the way it's done, it always transcludes over a hundred templates, which slows down edit and preview page loading substantially, and makes the list of transcluded templates under the editbox almost useless. It also means that we have a dozen million useless template links in the database, which slows down editing of all pages. The template should be redone so that the smallest possible number of templates is transcluded on every use. Zocky | picture popups 11:45, 14 October 2009 (UTC)[reply]

I believe this template (and {{CountryAbbr2}} et. al.) should be deleted, after a bot has added coordinates_type = type:city_region:XX-YY to all the transclusions of Infobox settlement. Further comments and discussion at Template talk:Infobox settlement. — Andrwsc (talk · contribs) 17:15, 14 October 2009 (UTC)[reply]
I'm with you in spirit, Andrwsc, but note that this template is also used by other infoboxes including {{Geobox}}. --Stepheng3 (talk) 20:48, 28 February 2010 (UTC)[reply]

Plan to streamline CountryAbbr2 transclusions[edit]

24-March-10: Looks like the massive problem is inside {CountryAbbr2}, with the misuse of templates to decode a nation's title from the 3-letter code, where, perhaps, some people thought the effect would be to just match the current nation code against the caller's country name; but instead, {CountryAbbr} seems to copy all the template links (perhaps 300-500 nation templates) into each and every article using this {CountryAbbr} template. Since the nation names don't change very often, the 340 could be hard-coded into {CountryAbbr2}, rather than decoded within every city/nation article page. If a nation changed it's name, then the associated users would notice the old name and see the need to update the {CountryAbbr2} template. I will begin the "{{CountryAbbr2/sandbox}}" version to improve this {CountryAbbr}. We've been waiting too many months on this problem. -Wikid77 (talk) 17:14, 24 March 2010 (UTC)[reply]

If it makes any difference, User:Xenobot/6.2 seeks to avoid use of CountryAbbr in Infobox settlement by providing region codes directly. –xenotalk 19:18, 24 March 2010 (UTC)[reply]

Issues of CountryAbbr on subpage: overlinking[edit]

28-March-10: In the processing needed to lookup the flag image&wikilink for a nation, {CountryAbbr} invokes {CountryAbbr2} which, in turn, keeps invoking flag templates until one matches. If there is no matching flag, then {CountryAbbr2} will have checked all entries in the #switch, and transcluded every possible flag template (and Country_data_Xxxx template) for all nations. See talk-page subpage "/overlinking" for an example listing 653 templates transcluded into the city article "Fremont, California" and discuss there. -Wikid77 (talk) 10:59, 28 March 2010 (UTC)[reply]

Change to Template:CountryAbbr2 to drop 50 million wikilinks[edit]

24-March-10: The country-flag lookup routine, {{CountryAbbr2}} needs to be replaced from the sandbox version {{CountryAbbr2/sandbox}}, which has been massively streamlined for the name-match logic to bypass 300-560 flag/data templates per use. The new version also matches "Swaziland" not supported earlier.

IMPACT: over 167,000 article pages might get reformatted, and over 68,000 articles directly using {CountryAbbr2} will then omit 300-560 wikilinks to nation/flag subtemplates, resulting in myriads fewer, perhaps 25-73 million fewer total wikilinks. A major infobox affected is: {{Infobox_Settlement}}. See list of heavily-transcluded templates: "WP:Database reports/Templates with the most transclusions" with counts for {CountryAbbr2}.

TEST DATA: The following test cases will show that the sandbox version generates the identical results, for use in article pages, even though {CountryAbbr2/sandbox} generates those results 100x faster using far fewer templates. After update, an edit-preview of this talk-page will show the live results (as "Currently") with the installed template. The test cases are coded in the format: {{CountryAbbr2|United States|Florida}} or {{CountryAbbr2|{{USA}}|Florida}}.

  • (Table moved to /testcases because it was causing template errors on this page. — Martin (MSGJ · talk) 09:16, 27 March 2010 (UTC))[reply]

This is the basis for requesting an admin-edit, but the sandbox version is not ready yet. -Wikid77 (talk) 18:33, 25 March 2010 (UTC)[reply]

The claim of being 100x-500x faster sounds dubious to me. If that's an essential element of your argument for the change, then I would like to see some measurement evidence. --Stepheng3 (talk) 20:32, 25 March 2010 (UTC)[reply]
Well he did say perhaps =) –xenotalk 20:35, 25 March 2010 (UTC)[reply]
  • The speed depends on the number of individual templates being transcluded to "compute" the nation/region codes. Of course, if the table can't be completed, then the speed is infinitely faster with a shorter template that could complete the table. -Wikid77 (talk) 13:58, 26 March 2010 (UTC)[reply]
What matters to users is the total response time, not just the part due to transclusions. If transclusions account for (say) 95% of the delay seen by users, then eliminating them is unlikely to improve responsiveness by more than 20x. My point is that until you measure the speedup, you don't really know what it will be. While I approve of the work you're doing, I hate to see exaggerated claims based on an overly simplistic performance model. Best regards, --Stepheng3 (talk) 19:09, 26 March 2010 (UTC)[reply]
  • Yes, I agree some users might read "100x-500x" and think their articles will display over 100x times faster, expecting an article to appear within 1 second after clicking a link. I have removed that wording so that no one expects articles to display over 100x faster. I know it's difficult even for some computer programmers to understand a template generating "32 million wikilinks" and I've had some WP developers delete my warnings that overlinking would clog WP databases and foul articles. They claimed "WP:Don't worry about performance". The reality seems to be that when a template gets as huge as CountryAbbr2 had become (with 560 internal transclusions), then using it too many times will kill the article-display totally: no partial page, just an internet error page for "HTTP 500 Internal server error". Anyway, the sandbox version is ready to be installed. -Wikid77 (talk) 05:17, 27 March 2010 (UTC)[reply]

{{editprotected}} After the update, after replacing the contents of {CountryAbbr2} from {CountryAbbr2/sandbox}, then all examples in the table should be able to display, and the whole table should appear complete. -Wikid77 (talk) 05:59, 27 March 2010 (UTC)[reply]

I would like someone who is familiar with these templates to double-check your code before committing the change, if possible. — Martin (MSGJ · talk) 09:30, 27 March 2010 (UTC)[reply]
I've looked at the code, looked at the test cases, and while everything appears sound at first blush, I'm somewhat out of my comfort zone on this one. I see nothing wrong, but like Martin, I'd appreciate another opinion before committing. Huntster (t @ c) 09:02, 28 March 2010 (UTC)[reply]
  • Thanks. I guess you're the 2nd person that Martin was seeking, so with my tests of the template, that's 3 of us. To record how {CountryAbbr2} had been working, before this update, I have created a large subpage "/overlinking" to discuss those problems of using 560 templates to check a nation's flag, plus a full example of how poorly the template had worked, during the past year. This template has been a challenge for everyone:
  • so big that no one had time to fix it during 2009;
  • so big that a full example (653 templates) needs a talk-subpage for all details;
  • so big it cannot be fully tested due to Wikipedia template limits;
  • so big no one has time to write all 600 test cases;
  • so big that writers have lived the horror of "560" transclusions for a year.
This template is living proof, that for massive templates, they are almost impossible to improve, in a volunteer effort, even after a whole year. Massive templates are a major problem for Wikipedia, generating severely poor performance for many months. -Wikid77 10:59, 28 March 2010 (UTC)
I'll take a 3rd look and will deploy when everything looks ok. —TheDJ (talkcontribs) 11:30, 28 March 2010 (UTC)[reply]
Changes looked valid, so done. And good work, this was a huge transclusion problem it seems !!! —TheDJ (talkcontribs) 11:48, 28 March 2010 (UTC)[reply]
  • Great, I see that millions of wikilinks have already been dropped. Formerly, where a flag template {FSM}, or {BEL}, had 16,000 transclusions, it now has only about 100 or 400, allowing editors to easily confirm each flag-template's usage in the remaining articles. Thanks to everyone for checking & installing this massive fix. You have done your good deed for the decade, and you have all earned 9 years wiki-vacation! -Wikid77 (talk) 19:31, 28 March 2010 (UTC)[reply]
    Nice job. This might cut out a lot of work for me. –xenotalk 00:40, 29 March 2010 (UTC)[reply]
Yes, see below: #Invalid parameters passed to CountryAbbr. -Wikid77 14:03, 29 March 2010 (UTC)

With due respect, this is the wrong way to solve the problem. "Unfolding" the flag template usage inside CountryAbbr still results in maintenance difficulties. The wikicode of CountryAbbr et. al. must anticipate all the possible markup variations for the infobox parameter. It is a fundamentally bad design to try to parse one infobox parameter in order to define a second infobox parameter, versus simply specifying the second infobox parameter directly. The right way to fix the problem is what Xeno was going to do with his bot, by adding the coordinates_region field to all those infoboxes so we can delete CountryAbbr entirely, not just patch it. — Andrwsc (talk · contribs) 23:11, 30 March 2010 (UTC)[reply]

I'm still willing to run the task but you'll need to defend the BRFA. I am not familiar enough with the subject area and the changes that were made. –xenotalk 23:21, 30 March 2010 (UTC)[reply]
I wouldn't be quite so negative about it.
In the mean time, we have a more efficient kludge. And if/when the bot run happens, it will be more efficient because it will be subst-ing a more efficient version of {{CountryAbbr}}. And all the other templates that use CountryAbbr will enjoy some speedup (until someone fixes them to not use it).
Personally, I don't have a problem with parsing one parameter to obtain another. In this particular case, the problem is that the format of the input parameter (subdivision_name) was never adequately defined, which explains why CountryAbbr has had such a hard time parsing it. --Stepheng3 (talk) 23:22, 30 March 2010 (UTC)[reply]
The "more efficient kludge" completely depends on the internals of the flag template system, and that is not an unchanging thing. Changes made there should not cause breakage here, which is entirely possible now. — Andrwsc (talk · contribs) 23:32, 30 March 2010 (UTC)[reply]
Your point about the fragility of the system is well taken, Andrwsc.--Stepheng3 (talk) 02:20, 31 March 2010 (UTC)[reply]

Invalid parameters passed to CountryAbbr[edit]

29-March-10: When trying to edit the "top 300" city articles to avoid using CountryAbbr2, I noticed many articles used invalid parameters as the nation name, instead putting unusual values, such as "subdivision_name = XXX<br>YYY". People might wonder, "If CountryAbbr2 only transcluded all 560 templates in reaching the end of the list, such as for Zimbabwe, then why did so many articles transclude the full 560 templates?" ...because any invalid, non-nation/flag parameter would require comparisons with all 560 before leaving the #switch branches with no match at the end. If the flag was "image+France" (near the top of the list), then only a few flag-templates were transcluded to reach the matching French flag. However, one article had used "subdivision_name=City" where "City" was not a nation, and hence it used 560 templates to find no match. I added "City" (or "city") as an early choice in CountryAbbr2. Also, I moved "flag+USA" to the top of the list because template {USA} was the most-used flag-template on Wikipedia, and likewise, I moved the top 40 nation flags to the top of the #switch list in {CountryAbbr2}. The numerous articles checking those flags will match within 40 template comparisons, and not check all 500 cases. As a result, the problem becomes to avoid using {CountryAbbr2} with invalid parameters being sent from {{Infobox_settlement}}, so that is an efficiency issue for long-term re-design of that template. There is no call to {CountryAbbr2} for sub-sub-sub-divisions: "subdivision_name2=zzz" does not invoke {CountryAbbr2}. -Wikid77 (talk) 14:03, 29 March 2010 (UTC)[reply]

I've been working to normalize subdivision names so that {{CountryAbbr}}, {{CanAbbr2}}, and {{StateAbbr}} don't fail so often. Since my usual tool (geosearch.py) is (temporarily I hope) out of commission, perhaps a maintenance category could be established to accelerate this process. --Stepheng3 (talk) 17:02, 29 March 2010 (UTC)[reply]
The geosearch.py tool is back in business, and one of the first things I noticed was that the number of {{Coord}}s with incomplete region codes is way up. A major source of these failures appears to be related to {{CountryAbbr}}. Specifically, {{CountryAbbr}} is failing on about 22,000 Poland articles that use {{flag icon}} in the subdivision_name= parameter of {{Infobox settlement}}. I added a testcase that demonstrates the bug, and I'd appreciate some help in fixing it. --Stepheng3 (talk) 19:05, 17 April 2010 (UTC)[reply]
If the are all the same, we can add another entry to the #switch. Is it that simple? Plastikspork ―Œ(talk) 19:28, 17 April 2010 (UTC)[reply]
I haven't looked at all 22,000 articles, just a sample. The testcase does seem to be a very common one. Once the testcase is fixed, I'll be better able to see if there are any other bugs. See Ćwiersk or this search result for examples.--Stepheng3 (talk) 19:57, 17 April 2010 (UTC)[reply]
Right. It looks like I just fixed the case you provided. Let me know if there are more. Of course, it would be even better to bypass this directly, as we have been discussing. Plastikspork ―Œ(talk) 22:04, 17 April 2010 (UTC)[reply]
Your edit helped a lot, as in roughly 21,600 infoboxes. Thank you. I look forward to the day when the effort that goes into keeping this hulk afloat can be directed elsewhere.
Here are some (less common) cases that may also be worth handling:
{{flag|Côte d'Ivoire}} -> "CI"
{{flag|Equatorial Guinea}} -> "GQ"
{{GEO}} -> "GE"
{{flag|Gambia}} -> "GM"
{{flag|Mauritius}} -> "MU"
{{MKD}} -> "MK"
{{flag|Nepal}} -> "NP"
{{ROC-TW}} -> "TW"
{{UKR}} -> "UA"
[[United States of America|USA]] -> "US"
--Stepheng3 (talk) 03:53, 20 April 2010 (UTC)[reply]
Those have been added. Of course, if one has fewer than say 100 transclusions, it's probably faster to just fix the transclusion, rather than the template. I know Svick was optimizing these templates by sorting the switch statements based on frequency of use (see Template talk:Portal), but this one is even more daunting. It would be so much easier if we just had people specify the ISO code for the country, then automatically displayed the full name with or without flag, which would cut down on the ridiculous number of variations. Plastikspork ―Œ(talk) 13:29, 20 April 2010 (UTC)[reply]

{od}I would put the threshold closer to 10 transclusions than 100, but other than that I agree with everything you said. Thank you, --Stepheng3 (talk) 20:27, 20 April 2010 (UTC)[reply]

Yes, it depends on how you define "faster". I was adding in the overhead in the template as well :) Given the shear number of possible permutations, the current design is not sustainable. In the long term, it's better to fix the transclusions, rather than have a template catch all variations. Plastikspork ―Œ(talk) 01:25, 21 April 2010 (UTC)[reply]
The latest round of ten additions took care of about 370 transclusions, so we are seeing diminishing returns. --Stepheng3 (talk) 01:45, 22 April 2010 (UTC)[reply]
Spork, I just noticed that you added all these cases to {{CountryAbbr}}. For performance reasons, all cases that involve transcluded templates (including all the added cases except for [[United States of America|USA]]) should go in {{CountryAbbr2}} instead. Since there's a single talk-page for both templates, I made my request here. I should've specified where the changes were targeted. My bad! Would you please move the template cases over to {{CountryAbbr2}}?--Stepheng3 (talk) 02:19, 22 April 2010 (UTC)[reply]
Yes, I was just thinking about that yesterday. I went ahead and moved them. Thanks! Plastikspork ―Œ(talk) 14:22, 22 April 2010 (UTC)[reply]

Six more for {{CountryAbbr2}}:

  • {{flag|Comoros}} -> KM
  • {{flag|The Gambia}} -> GM
  • {{flag|Malaysia}} -> MY
  • {{flag|Philippines}} -> PH
  • {{flag icon|Poland}} [[Poland]] -> PO
  • {{TLS}} -> TL

I'm not enthusiastic about coding combinations using {{flag icon}}, but the Poland case is common and consistent, and I've grown tired of fixing them by hand. --Stepheng3 (talk) 15:55, 23 April 2010 (UTC)[reply]

User:Xenobot/6.2 is approved for trial so I will probably run the trial over the weekend. We shouldn't have to do all this work to make a bad hack work, it's better to put a solid solution in place. –xenotalk 16:00, 23 April 2010 (UTC)[reply]
That's great. In the mean time, I added all but the new Poland one, which appeared to already be in there. Plastikspork ―Œ(talk) 16:26, 23 April 2010 (UTC)[reply]
Thanks, Plastikspork! I'm not sure why the Poland case isn't working. If I figure it out I'll let you know.
Great news about the bot run, Xeno. Since the bot is relying on {{CountryAbbr}} for determining the region code, the more cases {{CountryAbbr}} can handle, the better the results of the bot-run will be, correct? --Stepheng3 (talk) 17:20, 23 April 2010 (UTC)[reply]
Yes... Definitely. Also see Template_talk:CountryAbbr2#Confused, CountryAbbr2 is going to need to be forked into the old version because it's not substing properly with Wikid's new changes. –xenotalk 17:25, 23 April 2010 (UTC)[reply]

Confused[edit]

Why does {{CountryAbbr2|{{flag|Afghanistan}}|[[Kunduz Province]]}} yield "" yet {{subst:CountryAbbr2|{{flag|Afghanistan}}|[[Kunduz Province]]|subst=subst:}} yields "" (nothing)? –xenotalk 03:55, 16 April 2010 (UTC)[reply]

Strange. I will see if I can unravel the problem. Plastikspork ―Œ(talk) 19:29, 17 April 2010 (UTC)[reply]
I suspect is has to do with the inputs to the switch. I didn't realize that a switch could "look further" into a passed parameter that is a template the way it is doing. Ingenious, but probably preventing subst'ing. –xenotalk 19:32, 17 April 2010 (UTC)[reply]
Yes, here is a simple example to show what could be going wrong, if you want to check at VPT:
{{#ifeq:{{flag icon|Poland}}|<span class="flagicon">[[File:Flag of Poland.svg|22x20px|border |alt=Poland|link=Poland]]</span>|true|false}}

vs.

{{subst:#ifeq:{{flag icon|Poland}}|<span class="flagicon">[[File:Flag of Poland.svg|22x20px|border |alt=Poland|link=Poland]]</span>|true|false}}

Here, I am checking to see if the complete transclusion of the template is equal to itself. When I paste these into a page, one shows true, and the other shows false. Plastikspork ―Œ(talk) 22:07, 17 April 2010 (UTC)[reply]

Good grief, the things we do …. Basically it's just like Spork said, which is just a more elaborate example of the problem I noted on my talk page yesterday. It comes down to differing template behavior during PST phase and rendering. The PST phase (pre-save transform phase) happens during committal of a revision to the database and expands all substed templates, among other things.
During rendering of the page, all transcluded templates are expanded before parser functions process them. During PST however, substed parser functions like #ifeq or #switch work on the internal representation of the page they see at the time, meaning that transcluded templates are not expanded (after all we want the raw {{foo}} be written into the database), and they work on just that text.
Long story short, and as indicated by Plastikspork, if you subst CountryAbbr2 into a page, the switch inside {{CountryAbbr2}} will make a text comparison of the unexpanded "{{flag|Afghanistan}}" that you passed in with the unexpanded "{{country flag2 | alias=Afghanistan | name=Afghanistan | flag alias=Flag of Afghanistan.svg}}" that is hardcoded into {{CountryAbbr2}}, and finds no match.
Based on that, I don't see that the subst parameter built into {{CountryAbbr2}} can ever by useful. This template only works because during rendering, the passed-in flag template and the reference in {{CountryAbbr2}} evaluate to the same HTML.
This is a pure meta template that was built to cope with the variety of legacy country input in infboxes, if I'm not mistaken Are there many situations when you want to subst it?
Amalthea 13:00, 19 April 2010 (UTC)[reply]
Yes, to get rid of the monstrosity =) See BRFA. So I guess the bot will have to either use a forked version of the older template, which evaluates the dozens of different subdivision_name formats, or we will have to roll back the template. –xenotalk 13:02, 19 April 2010 (UTC)[reply]
Ah, I actually heard of that already. Very good, having the ISO code as input is of course the way forward.
If the old version of this template substed cleanly and has no regressions besides performance, then I say fork it. Easier on the job queue and on delays during manual editing. Amalthea 13:11, 19 April 2010 (UTC)[reply]
Perhaps I could twist your arm to opine as such as the BRFA: it's been fairly lightly trafficked thus far =) –xenotalk 13:21, 19 April 2010 (UTC)[reply]
  • Why does, and should (?), {{CountryAbbr|France}} equal FR-75? –xenotalk 18:31, 3 May 2010 (UTC)[reply]
    If you check the switch statement, the line for Paris has an extra pipe before the "=-75". If I remove it, it should then just display "FR". Sound like a good idea? Plastikspork ―Œ(talk) 18:48, 3 May 2010 (UTC)[reply]
    Unless the default by design is -75 (I don't know?), then yes... –xenotalk 21:14, 3 May 2010 (UTC)[reply]
    I believe this is a typo. Otherwise the {{FraAbbr}} template would have the same functionality. I will remove it. Plastikspork ―Œ(talk) 21:41, 3 May 2010 (UTC)[reply]
    Thanks for your keen eye! –xenotalk 22:31, 3 May 2010 (UTC)[reply]
Thanks for fixing it. -- 签名 sig at 11:58, 6 July 2010 (UTC)[reply]

ISO 3166 code - family of templates[edit]

  • {{ISO 3166 code}} returns the ISO code given country name and, optionally, subdivision name, e.g. {{ISO 3166 code|France|Paris}} FR-75. Covers all ISO 3166-1 and ISO 3166-2 codes.
  • All subdivision aliases mentioned in ISO3166 are supported.
  • All aliases for countries that are represented by redirects on en.wp are supported - a few may need tweaking.
  • Adding additional aliases is simple.
  • The family is fully scalable and fast.
  • This solution is incapable of supporting the template and wikilink values CountryAbbr does (It may be possible with string tweaking to reduce the parameters to the content of the first set of {} or [] but I doubt it.)

Please use this anywhere it is useful. Rich Farmbrough, 11:14, 4 May 2010 (UTC).[reply]

Thanks. We may someday need a template for the inverse operation. In other words, taking an ISO 3166 code and returning the country name and/or region name. Does the inverse template exist yet? --Stepheng3 (talk) 00:50, 5 May 2010 (UTC)[reply]
(By the scheme I have been using it would be called "ISO 3166 name".) I did find something like it somewhere while I was doing this. I will have a quick look - it is of course somewhat easier because the code will be more well-formed. Rich Farmbrough, 13:09, 5 May 2010 (UTC):[reply]

The inverse now exits at a country level: {{ISO 3166 name|FR}} (or {{ISO 3166 name|FRA}}) France. See there for full details of other conversions available (for example between alpha 2 and alpha 3) Rich Farmbrough, 03:19, 25 June 2010 (UTC).[reply]

FYI DK vs. GL[edit]

Pointed out at my talk page [1], CountryAbbr seems to return an erroneous result for Greenland (in the Kingdom of Denmark) - {{CountryAbbr|Kingdom of Denmark| Greenland}}, result is (result as at post is "DK" - expected "GL"). –xenotalk 15:58, 9 June 2010 (UTC)[reply]

Template discussion about a replacement system[edit]

There is a discussion at WP:Templates for discussion/Log/2011 February 6#Template:ISO 3166 name DE-HB that is relevant here. In a nutshell, the (mostly currently unused) template system (e.g. {{ISO 3166 code}}) could replace some (not all) of the functionality of this template. Additional feedback is welcome; the original TfD discussion attracted only three editors. — Andrwsc (talk · contribs) 18:27, 6 February 2011 (UTC)[reply]

Edit request on 15 March 2012[edit]

Please add '=' before the MY for the Malaysia entry in {{CountryAbbr2}}. This bug is causing {{CountryAbbr2|{{flag|Malaysia}}}} to return MZ instead of MY. Frietjes (talk) 21:33, 15 March 2012 (UTC)[reply]

Fixed, thanks! Amalthea 21:52, 15 March 2012 (UTC)[reply]

Template-protected edit request on 27 August 2018[edit]

Replace with <includeonly>{{safesubst:#invoke:ISO 3166|code|{{{1|}}}|{{{2|}}}}}</includeonly><noinclude>{{Documentation}}</noinclude> As Module:ISO 3166 works without problems and is more efficient. – BrandonXLF (t@lk) 00:48, 27 August 2018 (UTC)[reply]

 Not done: This is already using a module, so need more discussion that changing the module used as the backend would be an improvement. Galobtter (pingó mió) 16:58, 2 September 2018 (UTC)[reply]

Template-protected edit request on 9 September 2018[edit]

Replace with #REDIRECT [[Template:ISO 3166 code]] as the module this template currently uses uses Template:ISO 3166 code place name and since a lot of those templates were deleted both that module and this template are broken in many cases, this seams like the most logical way of fixing the issue and preventing any future issues from occurring. – BrandonXLF (t@lk) 04:34, 9 September 2018 (UTC)[reply]

 Done — Martin (MSGJ · talk) 13:37, 11 September 2018 (UTC)[reply]
BrandonXLF, I am concerned that after the switch to the new module, we no longer have functional tracking categories for invalid input. in particular, it looks like Category:Wikipedia page with obscure country or subdivision, and the subcategory, Category:Wikipedia page with obscure country, are no longer functional. what are the replacement tracking categories? Frietjes (talk) 15:55, 11 September 2018 (UTC)[reply]
Frietjes I'll look into it, I think all you need to do is add some code to the template, I'll let you know when its done. – BrandonXLF (t@lk) 19:59, 11 September 2018 (UTC)[reply]
It looks like Category:Wikipedia page with obscure country or subdivision is populated again. – BrandonXLF (t@lk) 20:15, 11 September 2018 (UTC)[reply]
BrandonXLF, please do. this will help identify places where the recent changes broke the functionality of this template. for example, compare the output of {{#invoke:Country extract|main|{{flag|Netherlands}}|{{Flag|North Holland}}}} = NL-NH with {{#invoke:ISO 3166|code|{{flag|Netherlands}}|{{Flag|North Holland}}}} = . so, the this template is now functionally broken for many cases that were working before. where are the testcases? Frietjes (talk) 20:29, 11 September 2018 (UTC)[reply]
I had that working, I'll look into it– BrandonXLF (t@lk) 20:31, 11 September 2018 (UTC)[reply]
@Frietjes: Fixed. Let me know If you see any other issues. – BrandonXLF (t@lk) 00:06, 12 September 2018 (UTC)[reply]