Template talk:Japanese episode list
From Wikipedia, the free encyclopedia
| Template:Japanese episode list is permanently protected from editing, as it is a heavily used or visible template. Substantial changes should be proposed here, and made by administrators if the proposal is uncontroversial, or has been discussed and is supported by consensus. Use {{editprotected}} to attract the attention of an administrator in such cases. Any contributor may edit the template's documentation to add usage notes, categories or interwiki links. |
| WikiProject Television | (Rated Template-Class) | |||||||
|---|---|---|---|---|---|---|---|---|
|
||||||||
| WikiProject Lists | (Rated Template-Class) | |||||||
|---|---|---|---|---|---|---|---|---|
|
||||||||
Archives |
|---|
- See also: Wikipedia talk:WikiProject Television and Template talk:Episode list.
[edit] New template, Template:Japanese episode list multi-part
I created a new template, Template:Japanese episode list multi-part, following some discussion at Talk:Sayonara Zetsubō Sensei#About the Titles of Each Episodes over how to treat episodes with multiple titles; I hope this wasn't unnecessary. —TangentCube, Dialogues 06:22, 7 January 2008 (UTC)
- Hmm, interesting. I think for myself I would have just made separate entires for each half, but since SZS is not constantly in two parts, I can understand the logic. -- Ned Scott 08:07, 12 January 2008 (UTC)
[edit] TopColor
{{Editprotected}} Please edit the very first line of the template and replace it with:
<tr style="text-align: center; {{#if:{{{TopColor|}}}|background:#{{{TopColor}}}|{{#ifeq:{{{ShortSummary|ʁ}}}|ʁ| |background:#F2F2F2}} }}">{{
This brings back TopColor, which was originally removed to make the template smaller and because no one used it. Since then we've removed the code for images and other tricks, there is more "room", and there are a few new situations where TopColor can now be used. Basically, it will be used to add alternating coloring for lists such as List of Lost episodes, and used to highlight special episodes within the list. I've tested this in my sandbox before hand (at User:Ned Scott/sandbox5 and User:Ned Scott/sandbox8. (userfied template at User:Ned Scott/sandbox4) This will have no effect on any list unless someone defines TopColor= for an entry. -- Ned Scott 08:13, 12 January 2008 (UTC)
[edit] Anchors
Could we add anchors to the template to allow the episodes to be linked directly? This would actually be better when redirecting an episode title to the top of the list. --Farix (Talk) 20:21, 19 January 2008 (UTC)
- We already have that. Use "#ep0#" as the anchor where the second # is the number of the episode for 1-9, and then "#ep##" for episodes 10 and above. Took me by surprise too until I saw someone using it. Examples: List of Clannad episodes#ep05 and List of Clannad episodes#ep15.--十八 23:16, 19 January 2008 (UTC)
-
- Oops, I guess we forgot to document that a while ago. It also works for ProdCode as well, where it becomes "#pccode" -- Ned Scott 04:48, 20 January 2008 (UTC)
[edit] Ratings
Is it possible to add Ratings to this template... --Staka 18:41, 25 January 2008 (UTC)
- Use the Aux fields. —TangentCube, Dialogues 18:44, 25 January 2008 (UTC)
Is Aux 3 the maximum? --Staka 18:45, 25 January 2008 (UTC)
- Yes. Adding too many possible columns only creates clutter. —TangentCube, Dialogues 18:46, 25 January 2008 (UTC)
-
- Not sure where I put it, but I actually proposed a while back giving some dedicated fields for the very common stuff, which I think included ratings. If I have time, I'll check to see what impact such a change might have on the template-limitation problem. Lately I've been thinking we should just use a different template for lists that are very long, so we don't have to worry so much about it. Though it is good to be conservative with these fields, so there isn't a flood of them. -- Ned Scott 01:42, 26 January 2008 (UTC)
[edit] Large revamp/notes discussion
Please see Template talk:Episode list#Revamp. I've noted several proposals to the main Template:Episode list that will effect this template as well. Plus a bunch of other notes and proposals for things such as an LOE/season page method that allows season pages to be transcluded on the main LOE page. I encourage everyone to participate. -- Ned Scott 06:25, 1 February 2008 (UTC)
[edit] Description doesn't stretch correctly when the 'EnglishTitle' parameter is omitted
This problem should be easy to fix.
This is what it looks like without 'EnglishTitle'
| "Japanese Title" | 00 Month, 0000 |
| Description | |
and here's with 'EnglishTitle'
| "Japanese Title" | 00 Month, 0000 |
| Description | |
I think changing the expression for colspan calculation from {{#ifeq:{{{EnglishTitle|ʁ}}}|ʁ|0|1}} to {{#ifeq:{{{EnglishTitle|ʁ}}}|ʁ|{{#ifeq:{{{JapaneseTitle|ʁ}}}|ʁ|0|1}}|1}} should fix it without breaking anything.
--Execvator (talk) 19:42, 11 February 2008 (UTC)
- That is a bug in the main episode list too. When I asked over there they said to just put in the field with no content. Collectonian (talk) 19:46, 11 February 2008 (UTC)
-
-
- I think its something related to the code. I'd personally rather see the template fixed so article length isn't bloated by unnecessary fields, but I'm not experienced enough in template code to even attempt such a fix. :P Collectonian (talk) 22:46, 11 February 2008 (UTC)
-
-
-
-
- What do you mean by bloated? —TangentCube, Dialogues 23:19, 11 February 2008 (UTC)
-
-
-
-
-
-
- Having the blank lines can add quite a bit of length to the page's code unnecessarily, making it seem larger than it is and making it slower to load, particularly for larger lists. Collectonian (talk) 15:49, 12 February 2008 (UTC)
-
-
-
-
-
-
-
-
- I still don't see this. Adding "|EnglishTitle=" is only 18 bytes of text, and the generated HTML doesn't have anything that's not defined in the template call. —TangentCube, Dialogues 21:05, 12 February 2008 (UTC)
-
-
-
-
- {{#ifeq:{{{EnglishTitle|{{{JapaneseTitle|{{{KanjiTitle|ʁ}}}}}}}}}|ʁ|0|1}} would work, I think, but since the workaround is simple, I don't think there's any rush. —TangentCube, Dialogues 23:19, 11 February 2008 (UTC)
Oops. This originally worked in an older version, but I think it was lost when this template was being "synced" with the main one. I didn't think to add the additional calculation to Template:Episode list because it would be unlikely to use AltTitle without Title. I'm about to request an edit to the template for the addition of the DirectedBy and WrittenBy parameters that were discussed at Template talk:Episode list, and will put this fix in with that. -- Ned Scott 00:09, 12 February 2008 (UTC)
[edit] Update
Please replace the entire contents of Template:Japanese episode list with this. See also Template talk:Episode list#Revamp. -- Ned Scott 03:23, 15 February 2008 (UTC)
- I believe the else part of #if:{{{JapaneseTitle}}} needs a check for EnglishTitle, or it will add RTitle twice if EnglishTitle is defined but JapaneseTitle is not. —TangentCube, Dialogues 06:04, 15 February 2008 (UTC)
I just noticed there's more padding at the top and bottom of the ShortSummary cell. Is this intentional? —TangentCube, Dialogues 06:01, 17 February 2008 (UTC)
- It wasn't intentional. At first I couldn't figure out why this was, but I saw that I added two extra line breaks. This would fix it. -- Ned Scott 07:07, 17 February 2008 (UTC)
Please replace the contents of Template:Japanese episode list with this. This is a minor fix for the extra padding, as noted above, and also adds {{Documentation}}. -- Ned Scott 07:07, 17 February 2008 (UTC)
- Also add <noinclude><table></noinclude> to the beginning and </table> to the end so that the {{Documentation}} div wraps around the doc correctly. —TangentCube, Dialogues 08:02, 17 February 2008 (UTC)
{{editprotected}}
-
- Added. Please replace the contents of Template:Japanese episode list with this. -- Ned Scott 08:43, 17 February 2008 (UTC)
[edit] Low-importance edits
There are a copule of low-priority changes that should be made the next time this template is edited. First, the two <noinclude/> sections should be merged with each other, and second, the <table/> tag should be removed from around {{documentation}} as it is unnecessary. —Dinoguy1000 15:22, 10 May 2008 (UTC)
- Actually, the <table> tags should be around the template code itself, but what's currently there works just as well to get the {{documentation}} template to work correctly. Compare these two versions from {{Graphic novel list}} to see what I mean: r188536446, r188968798, diff. —TangentCube, Dialogues 00:40, 11 May 2008 (UTC)
- I suggested having the two noinclude sections merged in the above section with this draft, but the editing admin went with two sections. *shrug* -- Ned Scott 20:49, 12 May 2008 (UTC)
[edit] Correction Needed
{{editprotected}} Can RTitle be fixed so that it shows blank if it equals ʁ, same as the other fields? I think this can be done by changing
{{{RTitle|}}
to
#ifeq:{{{RTitle|ʁ}}}|ʁ| |{{{RTitle}}}}}
-- Collectonian (talk · contribs) 02:57, 25 July 2008 (UTC)
- I'm not 100% sure what you are saying. Can you show me what is happening that should not be? J.delanoygabsadds 21:16, 27 July 2008 (UTC)
-
- See List of Dragon Ball episodes (series). If there is no RTitle to pass, the ʁ appears. This isn't a problem with any of the other variables because they have the code above. It works fine in List of Dragon Ball GT episodes, because it is using the RTtitle. -- Collectonian (talk · contribs) 23:26, 27 July 2008 (UTC)
-
-
-
- Woops...transposed there. That fixed it though, and all looks good so thanks :) -- Collectonian (talk · contribs) 00:49, 28 July 2008 (UTC)
-
-
That's not actually necessary for this to work. The problem lies with Template:Japanese episode list/Dragon Ball, not with the parent template. -- Ned Scott 08:06, 28 July 2008 (UTC)
- Ah, I see what you've done here. Instead of listing just the parameters you were going to use, you used all of them but re-used the ʁ trick for the optional switch. I never thought to try that. It's a pretty good idea. -- Ned Scott 08:17, 28 July 2008 (UTC)
-
- Yep, because some of the DB lists use RTitle, but others don't. I first tried to make one that could be universal, where you could passed the main list page name to it instead of hardcoding, but alas, it would not work.-- Collectonian (talk · contribs) 14:04, 28 July 2008 (UTC)
-
-
- Hmm... making a universal one (something I intended to look into myself) should be as simple as changing the line
{{#ifeq:{{PAGENAME}}|List of Dragon Ball episodes|...into{{#ifeq:{{PAGENAME}}|{{{MainList}}}|...(substituting your parameter name of choice for MainList, of course). Your statement that you previously tried and couldn't get it to work, however, has piqued my interest; is your attempt still laying around anywhere so I can take a peek at it? —Dinoguy1000 19:56, 28 July 2008 (UTC)- I tried that, but it didn't work. I think if you look at one of the earlier versions, you can see the earlier attempts I made at it. -- Collectonian (talk · contribs) 20:21, 28 July 2008 (UTC)
- All right, loking through the history, it looks like your problem was having too many curly braces in several places. I made an addition to the template that should allow you to specify a different article for pagename comparison, if it broke anything, feel free to revert it. In the meantime, I recently sandboxed a copy of this template, I'll play around and see if I can get this functionality implemented in the main template code (shouldn't be too hard). —Dinoguy1000 22:32, 28 July 2008 (UTC)
- Cool...if so, that would rock and we could avoid excessive hacks for every series. I think the TV project will love you much, as right now a new hack has to be made of the main ep list for each TV series :P -- Collectonian (talk · contribs) 23:31, 28 July 2008 (UTC)
- All right, I added the functionality and partially tested it, but the TopColor thing seems to be uncooperative. Could someone else take a look at my code and see if they can get it to work? —Dinoguy1000 18:23, 29 July 2008 (UTC)
- After looking at the code with fresh eyes, I found and fixed the problem. Unless someone wants to suggest a name for the sublist parameter, the new version is ready to replace the current one (though some additional testing wouldn't hurt ;) ). —Dinoguy1000 21:35, 31 July 2008 (UTC)
- Since most lists probably won't need to make additional modifications (I think the Lost episodes excluded one of the cells, in addition to the summary. The Stargate sub-template allows for a "ShortSummary" on the main LOE, but a "LongSummary" on season pages.) it probably would be wise to just use a generic template via additional parameter. -- Ned Scott 07:02, 3 August 2008 (UTC)
- What, something like {{Japanese episode list/sublist}}, consisting of a genericised (is that even a word?) version of {{Japanese episode list/Dragon Ball}}? —Dinoguy1000 20:03, 5 August 2008 (UTC)
- All right, have another look at the template. I copied over and slightly modified the code from the Dragon Ball subtemplate, and I tried to reasonably thoroughly test the auto-show fields, but I may have missed something since I didn't look at the Auxn, ProdCode, DirectedBy etc. fields. Other than that, though, I'd say it's about ready to go. —Dinoguy1000 18:15, 6 August 2008 (UTC)
- Looks good to me. -- Ned Scott 21:10, 6 August 2008 (UTC)
- About ready for a live test? :D If so, how about making a List of Yu-Gi-Oh! GX episodes page, then updating the four season pages to use this, and see if it works? -- Collectonian (talk · contribs) 21:45, 6 August 2008 (UTC)
- Bah, now you're just trying to get me to do some work you don't want to... ;) I'll see what I can do there, after copying the template to {{Japanese episode list/sublist}} (so I don't have to bother updating lots of template calls later when this is fully tested). —Dinoguy1000 16:49, 7 August 2008 (UTC)
Done. Aside from the headers, it looks quite nice. —Dinoguy1000 17:08, 7 August 2008 (UTC)
- Sweet, looks great! I fixed up the headers (though we'll need to note in the instructions that arc/sub divisions need level 4 instead of level 3 headings). -- Collectonian (talk · contribs) 18:51, 7 August 2008 (UTC)
- Also worth mentioning here that I didn't bother writing up documentation for the sublist template, I just transcluded the main documentation. That's something else to work on. —Dinoguy1000 19:16, 7 August 2008 (UTC)
- Sweet, looks great! I fixed up the headers (though we'll need to note in the instructions that arc/sub divisions need level 4 instead of level 3 headings). -- Collectonian (talk · contribs) 18:51, 7 August 2008 (UTC)
- Since most lists probably won't need to make additional modifications (I think the Lost episodes excluded one of the cells, in addition to the summary. The Stargate sub-template allows for a "ShortSummary" on the main LOE, but a "LongSummary" on season pages.) it probably would be wise to just use a generic template via additional parameter. -- Ned Scott 07:02, 3 August 2008 (UTC)
- After looking at the code with fresh eyes, I found and fixed the problem. Unless someone wants to suggest a name for the sublist parameter, the new version is ready to replace the current one (though some additional testing wouldn't hurt ;) ). —Dinoguy1000 21:35, 31 July 2008 (UTC)
- All right, I added the functionality and partially tested it, but the TopColor thing seems to be uncooperative. Could someone else take a look at my code and see if they can get it to work? —Dinoguy1000 18:23, 29 July 2008 (UTC)
- Cool...if so, that would rock and we could avoid excessive hacks for every series. I think the TV project will love you much, as right now a new hack has to be made of the main ep list for each TV series :P -- Collectonian (talk · contribs) 23:31, 28 July 2008 (UTC)
- All right, loking through the history, it looks like your problem was having too many curly braces in several places. I made an addition to the template that should allow you to specify a different article for pagename comparison, if it broke anything, feel free to revert it. In the meantime, I recently sandboxed a copy of this template, I'll play around and see if I can get this functionality implemented in the main template code (shouldn't be too hard). —Dinoguy1000 22:32, 28 July 2008 (UTC)
- I tried that, but it didn't work. I think if you look at one of the earlier versions, you can see the earlier attempts I made at it. -- Collectonian (talk · contribs) 20:21, 28 July 2008 (UTC)
- Hmm... making a universal one (something I intended to look into myself) should be as simple as changing the line
-
-
-
- Taking a closer look at the Dragon Ball fork and giving it some thought, it seems that the template should also be able to work just by passing parameters with an empty pipe if they're not specified (e.g.
{{{EpisodeNumber|}}}), but I haven't done any testing, so I couldn't say for sure. Also, you can eliminate a lot of code redundancy by only placing the #ifeq statement around|ShortSummary={{{ShortSummary|ʁ}}}, since that seems to be the only parameter that gets removed between the two options. And what's with the TopColor/LineColor disparity between the two? —Dinoguy1000 20:02, 28 July 2008 (UTC)- I didn't try the empty pipe trick. When I did it with nothing, it was showing the variable names where it was blank. TopColor will alternate the rows when it is finally transcluded into List of Dragon Ball episodes (see List of Lassie episodes versus List of Lassie episodes (season 1) to see how it changes). I based it on what's been done with the regular ep list hacks. :) -- Collectonian (talk · contribs) 20:21, 28 July 2008 (UTC)
- Taking a closer look at the Dragon Ball fork and giving it some thought, it seems that the template should also be able to work just by passing parameters with an empty pipe if they're not specified (e.g.
-
For some reason I still have this page in my watchlist... Is there anything you want added/changed with the template? I've been trying to follow your discussion, but I'm afraid I am not exactly sure what you are referring to, and I don't want to mess up such a widely used template. J.delanoygabsadds 00:20, 29 July 2008 (UTC)
- No, we're good. We're talking about the subtemplate now :) -- Collectonian (talk · contribs) 02:01, 29 July 2008 (UTC)
Yeah, using multiple main lists, or making it more universal, would be really nice. Then we wouldn't have to make subtemplate, etc. Although, it should be possible to make groupings of main lists using "if switch" something. I've been meaning to try for Template:Episode list/Stargate, so that it would work for both List of Stargate SG-1 episodes and List of Stargate Atlantis episodes. It should be pretty simple. -- Ned Scott 03:46, 29 July 2008 (UTC)
- It would be really easy if it was possible to use a prefix value, instead of the entire page name. Then we could make it behave a certain way for any page that starts with "List of". -- Ned Scott 03:49, 29 July 2008 (UTC)
-
- I don't think that would work, though, as the subpages would also have "List of" in the name. :P -- Collectonian (talk · contribs) 03:59, 29 July 2008 (UTC)
-
-
- It would work for the ones that are using a subpage for season pages, which would be most of the cases for Template:Episode list. We would have to use a different value for a situation like the Dragon Ball one. -- Ned Scott 04:21, 29 July 2008 (UTC)
-
-
-
-
- How so? All of the ones I've seen use List of SERIES episodes for the main page, then List of SERIES episodes (season x) for the subpages? -- Collectonian (talk · contribs) 04:28, 29 July 2008 (UTC)
- Most of the ones I've seen use SERIES (season x). At least the ones using the sub/template trick -- Ned Scott 05:23, 31 July 2008 (UTC)
- How so? All of the ones I've seen use List of SERIES episodes for the main page, then List of SERIES episodes (season x) for the subpages? -- Collectonian (talk · contribs) 04:28, 29 July 2008 (UTC)
-
-
-
-
-
- It's not currently possible anyways, as the necessary parsing to determine if "List of" is part of the pagename requires some variant of mw:Extension:StringFunctions. Aside from that, possible logic to either test for "List of" in the pagename or if the pagename == param would be along the lines of
{{#if:{{#ifeq:{{PAGENAME}}|{{{param|}}}|1|{{#pos:{{PAGENAME}}|List of}}}}|text and code if it's the main list|text and code if it's a season list}}(this is, of course, extremely rough, considering I was working purely from memory here, with no testing whatsoever). —Dinoguy1000 17:28, 29 July 2008 (UTC)- Aye, which is why I said it would be really easy if it were possible :) -- Ned Scott 05:23, 31 July 2008 (UTC)
- It's not currently possible anyways, as the necessary parsing to determine if "List of" is part of the pagename requires some variant of mw:Extension:StringFunctions. Aside from that, possible logic to either test for "List of" in the pagename or if the pagename == param would be along the lines of
-
-
[edit] Non breaking spaces
Is there a reason why there are non breaking spaces ( ) following some of the fields? Because this is causing a problem on List of Shugo Chara! episodes with the title field of Episode 39. --Farix (Talk) 02:29, 31 July 2008 (UTC)
- I'm not seeing any formatting problems there. What browser are you using? There are only two non breaking spaces used in the template, and they're to force the title table cell and the summary table cell open when left blank. This is done to give a better impression to the passing reader/editor that there should be something filled out, rather than just appearing as a weird line. -- Ned Scott 05:19, 31 July 2008 (UTC)
[edit] JapaneseTitle to RomajiTitle
Could someone please add RomajiTitle as an alternate parameter name for JapaneseTitle? We had a similar discussion on Template:Infobox animanga awhile back that explains the reasons for it (for an example, have a look at List of MegaMan NT Warrior episodes). The intention is for JapaneseTitle to be deprecated and gradually phased out, just as is with the ja_name and ja_name_trans parameters from the infobox. —Dinoguy1000 18:08, 4 October 2008 (UTC)
- So they just need aliases? -- Ned Scott 05:30, 8 December 2008 (UTC)
- Yes. An outright removal would require an immediate bot run to update all instances so they don't stay broken, while an alias allows the old usage to be gradually phased out and removed at some later time without breaking anything. —Dinoguy1000 21:27, 8 December 2008 (UTC)
- Sorry about being so slow on this. I'm not really "active" anymore (for no particular reason, just life), but I'll see if I can jog my memory of templates enough to get this done. -- Ned Scott 05:06, 26 January 2009 (UTC)
- Yes. An outright removal would require an immediate bot run to update all instances so they don't stay broken, while an alias allows the old usage to be gradually phased out and removed at some later time without breaking anything. —Dinoguy1000 21:27, 8 December 2008 (UTC)
Just so you know, I went ahead and did this, so now usages of JapaneseTitle can start being phased out. 「ダイノガイ千?!」? · Talk⇒Dinoguy1000 22:07, 5 June 2009 (UTC)
- I believe I got all instances of |JapaneseTitle= converted over to |RomajiTitle=. But you may want to create a check and a cleanup category to make sure. --Farix (Talk) 17:30, 13 June 2009 (UTC)
[edit] Adapting for use with other translated shows
This template is being used on List of GoGoRiki episodes, for the Russian animated series GoGoRiki, and the creative editors at work there thought to use the three fields (English/Romaji/Kanji) to show the English, Transliterated Russian, and Russian. Except that the Kanji field is doing something that makes all the Cyrillic letters show up as wide glyphs, so that there are spaces between each letter. How could I change things to make things show up correctly? Create a new non-Latin, non-ideograph translated episode list template? I'd appreciate any help you can offer. Thanks. Avram (talk) 04:50, 8 December 2008 (UTC)
- I'm sure it could be done. You'd just need to copy the source code to a new template name and probably remove the span that has <span class="t_nihongo_kanji" lang="ja">. I'd wonder how many Russian series really have ep lists here though? This is the first I've heard of, so maybe could just use the regular episode list or even this one using the RTitle options instead of the Romaji/Kanji ones to fill in the other titles. -- Collectonian (talk · contribs) 05:00, 8 December 2008 (UTC)
[edit] Color handling
I don't particularly like how the color is handled by the template, specifically the fact that the # is hard coded into the template. While this was because of a limitation with parameter defaults, with tools such as {{ifempty}}, this can now be worked around.
The problem comes into fixing all 734+ pages with transclusions and adding the # into parameters such as |LineColor= and |TopColor=. Not all of these have either parameter set, but tracking down and fixing the ones that do is the problem. And how can we ensure that either version works, or should we just it break until the articles are fixed?
The advantage of fixing this is that we will no longer be limited to hex triplets, but can use all legal CSS color values. --Farix (Talk) 20:41, 13 June 2009 (UTC)
[edit] Code updates
Some general things that I've discovered while trying to cleanup this template.
First, there does not appear to be any effect on Preprocessor and Post-expand sizes do to whitespace. This is good because they can be added back in to improve the code's readability.
Second, after much tinkering with the code, I've gotten rid of two annoyances with nonbreaking spaces, eliminated a column span bug, and even added a new |Season= for lists such as List of Mobile Suit Gundam 00 episodes which we want to create anchors for. The end result is that the post-expand include size appears to be reduced while other size were marginally increased. For comparison, form this version of the testcase page:
Current:
<!-- NewPP limit report Preprocessor node count: 3111/1000000 Post-expand include size: 11110/2048000 bytes Template argument size: 2466/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox:
<!-- NewPP limit report Preprocessor node count: 3049/1000000 Post-expand include size: 11124/2048000 bytes Template argument size: 2420/2048000 bytes Expensive parser function count: 0/500 -->
Of course, I will need more extensive testing on some actual lists instead of just the limited test cases. --Farix (Talk) 20:22, 16 June 2009 (UTC)
- Seems in the end, there is an overall increase. But the real question is, is it enough to cause problems? --Farix (Talk) 21:30, 16 June 2009 (UTC)
-
-
-
- Looks good, but I have to ask... are there going to be any cases where |EpisodeNumber= and |OriginalAirDate= wouldn't be used? If not, it's pointless to explicitly test for them, and we can save on either 2 or 4 parser functions (2 - inserting the cells, 2 - testing for the colspan) per transclusion. Thoughts? 「ダイノガイ千?!」? · Talk⇒Dinoguy1000 02:06, 18 June 2009 (UTC)
-
-
-
-
-
-
- Given that they are required fields, probably not. But yea, that would cut things down just a bit more. Here is another thing, is it more efficient to incorporate the sublist template directly into the main template? While lists that aren't transcluded into a main list won't get any benefit from this, lists that are are transcluded into a main list may benefit because the template won't be counted twice towards post-expand include size limits. (see Wikipedia:Template limits#Nested transclusions) I'll test with the DBZ list sometime tomorrow to find out. --Farix (Talk) 05:10, 18 June 2009 (UTC)
-
-
-
-
-
-
-
-
- When I was originally working on the sublist feature, I was doing so as a part of the basic template (see this old version of my sandbox), but abandoned that partially because of an error I couldn't work around and partially at the request of another user. But, it's something that has always bugged me, and I'd be fine with merging /sublist back into the main template, depending on the results of your tests. 「ダイノガイ千?!」? · Talk⇒Dinoguy1000 11:12, 18 June 2009 (UTC)
-
-
-
-
-
-
-
-
-
-
- No exploding heads for the other testcases and the DBZ list has a sizable drop. Also, the sublist's test page is still working like normal. --Farix (Talk) 11:43, 18 June 2009 (UTC)
-
-
-
-
-
-
-
-
-
-
-
-
- It looks satisfactory to me, though I would like to see one or two huge examples (Bleach and One Piece would be good ones). Other than that, though, I can update the current template's code with the contents of the sandbox if you'd like. 「ダイノガイ千?!」? · Talk⇒Dinoguy1000 11:48, 18 June 2009 (UTC)
-
-
-
-
-
-
- (←) The problem with testing on lists like Bleach and One Piece is that there are multiple articles involved and some may not take kindly to using test code in article space. The test articles where copied over into the template's testcase page to obtain the number. When changes to the sandbox were made, it was simple to find these testcases in the test page's history. Here is a breakdown of transclusions for the testcases I conducted.
-
- Shugo Chara!: 51 transclusions (average size list)
- Beyblade: 118 transclusions (not exactly sure why this list increased the most)
- Fist of the North Star: 152 transclusions
- Gin Tama: 175 transclusions (most episode summaries are on the short side)
- Dragon Ball Z: 291 transclusions (as big as they come as far as single episode lists go)
- Since the DBZ list uses the sublist and it's post-expand include size shrank considerably, I am confident that the same will hold true for the other articles that use the sublist template. Also remember that the sublist template's code was recently optimized because it originally compounded the problem with nested templates by calling {{Japanese episode list}} twice. ^_^ How much of a savings we received from that was never checked, but I reason it was considerable. --Farix (Talk) 12:38, 18 June 2009 (UTC)
-
- I guess one way to minimize disrupting the main lists is to convert one season list over to the sandbox code and then comparing the limit reports of the main list between the new and old code. This should be enough to show if there will be an increase or decrease in post-expand include size of the main list. --Farix (Talk) 12:48, 18 June 2009 (UTC)
For those of us who aren't really template savvy, it would b helpful to have a more plain English explanation of what's being proposed ebcause I'm really not understanding any of the test numbers and stuff. -- Collectonian (talk · contribs) 00:43, 20 June 2009 (UTC)
- It's probably best to read Wikipedia:Template limits the learn about all of the details. Long story short, there is a limit to how many times templates can be transcluded into a page. However, this is not a fixed number but based is dependent on the size of the template and how much data is entered into the template call. This became a problem roughly three years ago when pages, such as the One Piece episode list, started hitting those limits. The template was greatly simplified and all of the "nonessential" whitespace was removed. (see Template talk:Episode list for history and details)
- Since then, a new preprocessor has been enabled on WikiMedia that makes transclusions far more efficient. The pre-expand include limit, which was giving everyone the trouble, was replaced with a preprocessor node count. However, we still need to be careful of the post-expand include limit. One affect of the post-expand include limit is with nested templates. If an article transcludes Template A and that template then trancludes Template B, then Template B is counted twice towards the post-expand include size of the article. --Farix (Talk) 03:03, 20 June 2009 (UTC)
Tested on Bleach, so here are the numbers
- Original Bleach Season 1 list
<!-- NewPP limit report Preprocessor node count: 11140/1000000 Post-expand include size: 116369/2048000 bytes Template argument size: 74153/2048000 bytes Expensive parser function count: 0/500 -->
- Using sandbox template (-13,537 bytes difference, 11.633% decrease)
<!-- NewPP limit report Preprocessor node count: 9600/1000000 Post-expand include size: 102832/2048000 bytes Template argument size: 62262/2048000 bytes Expensive parser function count: 0/500 -->
- Original main Bleach list
<!-- NewPP limit report Preprocessor node count: 70808/1000000 Post-expand include size: 536105/2048000 bytes Template argument size: 244064/2048000 bytes Expensive parser function count: 0/500 -->
- Using sandbox template (-6,437 bytes difference, 1.201% decrease)
<!-- NewPP limit report Preprocessor node count: 69388/1000000 Post-expand include size: 529668/2048000 bytes Template argument size: 241519/2048000 bytes Expensive parser function count: 0/500 -->
Verdict, both lists benefit from merging the sublist template into the new sandbox code, the main list less so then the season lists. --Farix (Talk) 13:05, 18 June 2009 (UTC) (revised 20:53, 19 June 2009 (UTC))
- A brief rundown of the three new parameters I installed in the standbox version:
- MainList – Name of the main episode list that the season episode list will be transcluded into.
- EvenRowColor – Color of even rows on main list. Just like TopColor and LineColor, there should be no pound sign (#) (Default is E9E9E9).
- OddRowColor – Color of odd rows on main list. Just like TopColor and LineColor, there should be no pound sign (#) (Default is clear/transparent).
- I'm going to request more input from the TV and anime projects. --Farix (Talk) 20:53, 19 June 2009 (UTC)
Full tests on our biggest lists:
- Pokémon original (603 episodes)
<!-- NewPP limit report Preprocessor node count: 122290/1000000 Post-expand include size: 996104/2048000 bytes Template argument size: 430710/2048000 bytes Expensive parser function count: 1/500 -->
- Pokémon sandbox (210,455 bytes difference, 21.128% decrease)
<!-- NewPP limit report Preprocessor node count: 78661/1000000 Post-expand include size: 785649/2048000 bytes Template argument size: 343260/2048000 bytes Expensive parser function count: 1/500 -->
- Case Close original (539 episodes)
<!-- NewPP limit report Preprocessor node count: 125535/1000000 Post-expand include size: 957689/2048000 bytes Template argument size: 489900/2048000 bytes Expensive parser function count: 0/500 -->
- Case Close sandbox (166,233 bytes difference, 17.358% decrease)
<!-- NewPP limit report Preprocessor node count: 89723/1000000 Post-expand include size: 791456/2048000 bytes Template argument size: 407585/2048000 bytes Expensive parser function count: 0/500 -->
- Dragon Ball original (520 episodes)
<!-- NewPP limit report Preprocessor node count: 104736/1000000 Post-expand include size: 901548/2048000 bytes Template argument size: 402883/2048000 bytes Expensive parser function count: 0/500 -->
- Dragon Ball sandbox (199,697 bytes difference, 22.150% decrease)
<!-- NewPP limit report Preprocessor node count: 67468/1000000 Post-expand include size: 701851/2048000 bytes Template argument size: 301687/2048000 bytes Expensive parser function count: 0/500 -->
- One Piece original (408 episodes)
<!-- NewPP limit report Preprocessor node count: 171971/1000000 Post-expand include size: 1552158/2048000 bytes Template argument size: 895432/2048000 bytes Expensive parser function count: 4/500 -->
- Once Piece sandbox (192,800 bytes difference, 12.421% decrease)
<!-- NewPP limit report Preprocessor node count: 140943/1000000 Post-expand include size: 1359358/2048000 bytes Template argument size: 785348/2048000 bytes Expensive parser function count: 4/500 -->
- Ooh, those are some really nice reductions. =D Is there anything (beyond feedback) keeping you from making an editprotected request to have the template synced with the sandbox? 「ダイノガイ千?!」? · Talk⇒Dinoguy1000 21:29, 22 June 2009 (UTC)
-
- Feedback is the only holdup, since this and {{Episode list}} should be updated at the same time. --Farix (Talk) 22:15, 22 June 2009 (UTC)
[edit] Transclusion size tests
[edit] Testcases page
<!-- NewPP limit report Preprocessor node count: 3111/1000000 Post-expand include size: 11110/2048000 bytes Template argument size: 2466/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox without sublist merged (294 bytes difference, 2.646% decrease):
<!-- NewPP limit report Preprocessor node count: 2833/1000000 Post-expand include size: 11404/2048000 bytes Template argument size: 2287/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox with sublist merged (2,392 bytes difference, 21.530% increase):
<!-- NewPP limit report Preprocessor node count: 3061/1000000 Post-expand include size: 13502/2048000 bytes Template argument size: 2287/2048000 bytes Expensive parser function count: 0/500 -->
[edit] List of Shugo Chara! episodes
<!-- NewPP limit report Preprocessor node count: 16966/1000000 Post-expand include size: 194939/2048000 bytes Template argument size: 183915/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox without sublist merged (169 bytes difference, 0.087% decrease):
<!-- NewPP limit report Preprocessor node count: 15844/1000000 Post-expand include size: 195108/2048000 bytes Template argument size: 182430/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox with sublist merged (51,543 bytes difference, 26.441% increase):
<!-- NewPP limit report Preprocessor node count: 16456/1000000 Post-expand include size: 246482/2048000 bytes Template argument size: 182430/2048000 bytes Expensive parser function count: 0/500 -->
[edit] List of Beyblade episodes
<!-- NewPP limit report Preprocessor node count: 25599/1000000 Post-expand include size: 287355/2048000 bytes Template argument size: 289938/2048000 bytes Expensive parser function count: 3/500 -->
Sandbox without sublist merged (512 bytes difference, 0.178% decrease):
<!-- NewPP limit report Preprocessor node count: 23039/1000000 Post-expand include size: 287867/2048000 bytes Template argument size: 286746/2048000 bytes Expensive parser function count: 3/500 -->
Sandbox with sublist merged (100,381 bytes difference, 34.933% increase):
<!-- NewPP limit report Preprocessor node count: 24455/1000000 Post-expand include size: 387747/2048000 bytes Template argument size: 286746/2048000 bytes Expensive parser function count: 3/500 -->
[edit] List of Fist of the North Star episodes
<!-- NewPP limit report Preprocessor node count: 30426/1000000 Post-expand include size: 238826/2048000 bytes Template argument size: 199297/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox without sublist merged (938 bytes difference, 0.393% decrease):
<!-- NewPP limit report Preprocessor node count: 27310/1000000 Post-expand include size: 239764/2048000 bytes Template argument size: 194324/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox with sublist merged (52,958 bytes difference, 22.174% increase):
<!-- NewPP limit report Preprocessor node count: 29134/1000000 Post-expand include size: 291784/2048000 bytes Template argument size: 194324/2048000 bytes Expensive parser function count: 0/500 -->
[edit] List of Gin Tama episodes
<!-- NewPP limit report Preprocessor node count: 32620/1000000 Post-expand include size: 251023/2048000 bytes Template argument size: 205024/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox without sublist merged (274 bytes difference, 0.109% decrease):
<!-- NewPP limit report Preprocessor node count: 28792/1000000 Post-expand include size: 251297/2048000 bytes Template argument size: 198248/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox with sublist merged (64,039 bytes difference, 25.511% increase):
<!-- NewPP limit report Preprocessor node count: 30880/1000000 Post-expand include size: 315062/2048000 bytes Template argument size: 198248/2048000 bytes Expensive parser function count: 0/500 -->
[edit] List of Dragon Ball Z episodes
<!-- NewPP limit report Preprocessor node count: 75025/1000000 Post-expand include size: 1090337/2048000 bytes Template argument size: 845836/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox without sublist merged (7,385 bytes difference, 0.677% decrease):
<!-- NewPP limit report Preprocessor node count: 68913/1000000 Post-expand include size: 1097722/2048000 bytes Template argument size: 832026/2048000 bytes Expensive parser function count: 0/500 -->
Sandbox with sublist merged (260,434 bytes difference, 23.886% decrease):
<!-- NewPP limit report Preprocessor node count: 52617/1000000 Post-expand include size: 829818/2048000 bytes Template argument size: 625706/2048000 bytes Expensive parser function count: 0/500 -->
[edit] Code updates (part 2)
{{editprotected}}
With due notice given to both WP:TV[1] and WP:ANIME[2] and no additional comments or objections per the discussion above, I'm requesting that the code in the sandbox be copied over and redirecting to the main template. --Farix(Talk) 14:25, 26 June 2009 (UTC)
- Can you clarify. Is this related to the Template:Episode list request, which seems to have a small bug, or this independent of that? — Martin (MSGJ · talk) 08:55, 27 June 2009 (UTC)
- The change itself is related, as both editprotected requests introduce similar fixes and improvements. However, these two templates are never used together, so any issues affecting one don't (shouldn't) affect the other (and see my comment on Template talk:Episode list, BTW). 「ダイノガイ千?!」? · Talk⇒Dinoguy1000 11:15, 27 June 2009 (UTC)

