Template talk:Rightcolumn

From Detective Conan Wiki

Complexification

G'day BOBO (or good afternoon or good evening)! I see that you've been diligently working on simplifying the front end part of this Rightcolumn template. But as for the backend LE template, (and to be honest) it looks complicated. I'm assuming there's a very good reason you're taking it this far, the problem, I don't know what that is exactly.

Thus far, I've had ChatGPT dissect the template setup, and from what it describes, I think this complex setup isn't really needed (don't take this personally). As an example, as of the 18:53 edit on the LE template, most of the wikitext in Template:LE is being used to automatically find the case's image. From what you could see in my sandbox, I was expecting this to be manual, after all it isn't much of a hassle to find the names of the case images.

In general, I think it is best if we balance between what is automatically done by the template and what isn't. This is, most notably, to keep the templates simple enough for future debugging. But, by all means, if you have a more important reason that you would like to share, and that reason backs up the complexity of the templates, then please continue development in that direction. Your thoughts are appreciated. --Avico (talk) 19:05, 23 January 2025 (UTC)

G'day to you as well Avico! Yesterday I separated Template:Latest news into both Template:LE and Template:NE. I did this since the parameters were very confusing initially. The version I left yesterday edit history was rather incomplete; reluctantly, it would work too by passing the parameter named {{{Case number}}} for the fetching of the image file for corresponding anime episode, but the only defect was that it could not establish a link that redirects to "latest episode" when clicked. It was not possible to access the parameter {{{Episode name}}} since it was moved to the LE template under a new name {{{2}}}. I enquired of ChatGPT about it, and he told me that to access "the parameter of the parameter" modules must be required, which would be even more complicated. The reason that the template looks messy is that the wiki seems to not support excessive indentation, and if so the text acts abnormally. That being said, right now I am certain that the LE template will work when the {{{part}}} parameter is numeric. In terms of non-numeric part parameters, only the first part is supported.
Now I am rather baffled... Only if I had known it would become this complicated, then why didn't I leave everything blank and just insert announcement messages manually at the outset? --BOBO (talk) 19:24, 23 January 2025 (UTC)
Excuse me for ruining the celebratory mood of completing such a complex template, but I've found that these two episodes don't get written correctly:


Joke 19 V2.jpg
Correct name: The Desperate Revival - The Cavern of the Detective Boys
(This case also has six parts, which breaks the image)


TV Episode 518-519.jpg
Correct name: Meiji Restoration Mystery Tour: Investigation Chapter
I wouldn't want you to try and somehow incorporate more code into the templates to fix this error since that would complicate the template further. I also don't want to override your work since you've already put so much effort into it already. But if we're going to make this template such that future contributors can go in and easily fix whatever they want to (i.e., future-proof the template), then I'm afraid that, with the current template, most will have to ask you about what part of the template does what (myself included). And if you're willing to write what is probably going to be the most elaborate documentation ever written to avoid that from happening...then why don't we channel that effort into making this template simpler, front-end AND back-end.

But of course, you're going to have to give the green light for that because simplifying this template will mean drastic revisions to the entire setup. I know I just wrote that "I...don't want to override your work since you've already put so much effort into it already," but I'm not going to be overriding the work. We will, if you agree to. --Avico (talk) 21:17, 23 January 2025 (UTC)
Hey I may want to say something: the "Meiji Restoration Mystery Tour" title is inconsistent with the majority of the episodes; most likely we should change that some day. Regarding the "Desperate Revival", it is a special case, just like the Clash of Red and Black. Implementing that onto the current scheme would not be difficult, but adding a few lines or so would. The #ifexist statements are the same once we have written the first one, essentially just copy-pasting and concern about the "if statement" logics. But candidly, currently I can't think of a better way of structuring this template than doing this, as originally the parameters were all over the place. What do you think? Avico? The current scheme is mainly for the sake of simplifying the weekly update, as indeed, when updating the information, the "user interface" is much simplified and eased. --BOBO (talk) 21:29, 23 January 2025 (UTC)
Well if you're that interested in my opinion...might as well write it down. We don't need a third template like LE. Yes, we might need a third template. But not as complicated as LE. Now, do know that I haven't really "dug" into this project very much, but I am starting to, as you can see in my sandbox. I'm not entirely sure how I would advance with this, but one thing's for sure: It's not going to be as complicated as your setup. If you want, check out my sandbox. For now though, if you could explain how your #ifexist statements work, then I might have something to improve on in my sandbox. --Avico (talk) 21:35, 23 January 2025 (UTC)
I have seen your sandbox just now! Please promise me that you won't be upset with me after I say this (laughs). I can find similarities with the first version of the Template:Latest news. The reason I created Template:LE and Template:NE was to avoid the parameters being too much; I do not think having a lot of templates is an issue as I only had the guts to do this after seeing our senior editors creating Template:Appear ed, Template:Appear ep, Template:Appear file, Template:Appear movie, Template:Appear op, Template:Appear special file... (laughs) Your idea is pretty nice, I must admit, but having three slots causes a bit of ambiguity to me? And at the end of the day, we might not be able to acquire the air schedules beyond one week. Even if it is automatic, we would also have to modify regularly as the titles and air dates might need adjustments. Please don't get mad at me lol, I look forward to hearing your opinions --BOBO (talk) 21:45, 23 January 2025 (UTC)
You realize that Template:Appear ed, Template:Appear ep, Template:Appear file, Template:Appear movie, Template:Appear op, Template:Appear special file are all much simpler than your Template:LE, right (laughs)? Anyway, the slots in my version of the Rightcolumn template are there for when we do have information one or two weeks ahead, and that's usually with the canon cases. There's a reason why I called it "semi-automatic", because we still have to manually update the episodes. The bonus is that if I can incorporate Template:timeDiff, then the moment the episode broadcasts, it automatically switches into the latest episode slot. In any case though, I think it's going to be a lot simpler to manage than the monstrosity in Template:LE (which is why I started this discussion, kind of putting the stops in so that we don't complicate things further). --Avico (talk) 21:52, 23 January 2025 (UTC)
I forgot to mention, I was supposed to write a sentence saying that "Slots 1, 2, and 3 must be in chronological order" in the sandbox today, but I completely forgot. I'll update that very soon though. --Avico (talk) 21:54, 23 January 2025 (UTC)
Don't get me wrong (laughs), I am not bragging about how good the current templates are; they still aren't perfect. But what I tried to attain is reducing the number of named parameters (especially having to insert "part 1 or 2 or whatever" requires an extra line with parameter being a little bit wordy such as "Current part") and this downplays the functionality, personally. About the automatic update, I really think we should give up on it, as it still requires editors to change it weekly, it is not worth all that time developing and then realise it is not that effective. Frankly, template is not that complicated as it only looks "overwhelming" because of the number of lines. But if you look closely, they are merely duplicates of the same thing; #ifexist in nature introduces two lines of similar content: {{#ifexist:File:YourFileName.jpg|ContentIfExists|ContentIfDoesNotExist}} it checks if the given file exists - if not, then something else triggers. Speaking of which, I also wanted to simplify the display of the right column, in which for the next episode segment, solely "the [[next chapter]] will be released in XXXX" is rendered. Notwithstanding that, I am really grateful for the fact that you aspire to make a difference; I will definitely give you a hand concerning your grand project. If we succeed, then maybe we should try and see how to alter the right column, but I have a fear that by then other editors would have already removed the right column template from the main page (laughs) --BOBO (talk) 22:07, 23 January 2025 (UTC)
Yup, I definitely saw some duplication (even the AI pointed that out). Maybe it's because you're the creator so you know how it exactly works. I've had some experience with nesting (another form of duplication) Ifs before in my other programming projects, and when it comes to legibility, without comments or description, it's close to zero. I know this because it's only after you finish the project, let it sit there, and come back do you realize how complicated such duplication and nesting can really be. Now for some targeted quote replying:
"we should try and see how to alter the right column"
What did you mean by that?
"I have a fear that by then other editors would have already removed the right column template from the main page"
If we had as many editors as this wiki had about five years ago, this might have happened. But the only current editors that might do this now are Nakamura and Jefflie, and I think they understand what we're doing, so we should worry about this. --Avico (talk) 22:25, 23 January 2025 (UTC)
Trust me, I am not the creator (laughs), And Now Let Us Give Praise To The Knowledgeable Mr. GPT. Without him, I am not able to start, he thought up all the ideas, before this, I did not even know that #ifexist is a thing lol. I agree with you, nesting statements can be "damageable" when executing. Yet I think this is a bit different from recursion, I don't think it is calling itself or anything... It only occupies many bytes which does not look good in the source code. There is nothing to "we should try and see how to alter the right column", I just think that the template itself leaves a lot to be desired and very not mature; I am simultaneously also being afriad of complains as you know, not everyone is satisfied with everything - I recall last time when I changed the Chronology box, some liked, but some complained; same also happened when we decided to re-split the seasons of the anime. But do whatso you want! I honestly don't care now! Much obliged! :) --BOBO (talk) 22:34, 23 January 2025 (UTC)