Commons:Village pump/Technical

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Shortcuts: COM:VP/T • COM:VPT

Welcome to the Village pump technical section
Technical discussion
Village pump/Technical
 Bug reports
 Code review
Tools
 Tools/Directory
 Idea Lab



This page is used for technical questions relating to the tools, gadgets, or other technical issues about Commons; it is distinguished from the main Village pump, which handles community-wide discussion of all kinds. The page may also be used to advertise significant discussions taking place elsewhere, such as on the talk page of a Commons policy. Recent sections with no replies for 30 days and sections tagged with {{Section resolved|1=--~~~~}} may be archived; for old discussions, see the archives; recent archives: /Archive/2024/11 /Archive/2024/12.

Please note
 
SpBot archives all sections tagged with {{Section resolved|1=~~~~}} after 1 day and sections whose most recent comment is older than 30 days.

Templates in description field bug

[edit]

Continuing Commons:Village pump/Technical/Archive/2024/10#Templates in description field cause empty caption in Media Viewer: I write to inform that I reported the problem as https://phabricator.wikimedia.org/T380190. You can add more details if you wish, or interact in some other ways – I'm not familiar with Phabricator savoir vivre and politics.

I would also like to add that I feel demotivated and hopeless by the way the now archived thread linked above was handled. I asked for help and no one even bothered to answer "no, I won't help, do it yourself". The thread was left to die, without anyone giving a helping hand to bring the topic closer to some solution. I don't think that ignoring a problem makes it disappear. This was an unpleasant experience for me to collaborate this way. I hope someone reads this feedback and makes some use of it. Derbeth talk 16:15, 18 November 2024 (UTC)[reply]

Maybe User:Sannita (WMF) can help? It's a problem I was wondering how to get around it before.
 ∞∞ Enhancing999 (talk) 14:25, 19 November 2024 (UTC)[reply]
I'll flag it to the devs and see if they can do something about it. I'm sorry that @Derbeth had this unpleasant experience. I'll keep you posted about it, but please be aware that it might take some time. Sannita (WMF) (talk) 14:51, 19 November 2024 (UTC)[reply]

Thank you Sannita. I fully understand fixing bugs takes time. I just wish discussions here were more like "exchanging different opinions -> agreeing what to do -> doing", instead of "dissolving" without any conclusion, as I felt was the case with the topic I started in October. --Derbeth talk 16:51, 19 November 2024 (UTC)[reply]

Yeah, I see. As I said, I'll try this time to get you a solution for it, instead of just disappearing. If you don't hear from me, you're free to ping me on my talk page about this bug. Sannita (WMF) (talk) 17:21, 19 November 2024 (UTC)[reply]
I wish that too. I think people did not engage exchanging different opinions -> because it's clear this needs to be fixed and people share the opinion that it needs to be fixed with it not being useful in regards to getting it fixed to write that. -> agreeing what to do for bugs people generally agree that it should be reported and fixed. Somebody should have asked to create a phab issue. -> doing this part is the key problem. Even major bugs like all interactive charts on Wikipedia being broken or Commons categories not showing on mobile are not getting fixed after timescales of 5 years to decades. I don't think complaining about this is enough anymore so I made concrete suggestions on how to fix this here. They could readily be discussed and implemented which would result in all technical issues being addressed more often and more quickly:
Please increase MediaWiki development capacity further.
Prototyperspective (talk) 17:37, 19 November 2024 (UTC)[reply]
The commons category thing is not a case of insufficient resources. The graph thing is partially a resource problem, but that is hardly the only issue there and it would be a gross oversimplification to boil it down to just that. Some problems are resource problems, i would even say many problems on commons are resource problems, but not all problems are resource problems. Bawolff (talk) 21:09, 19 November 2024 (UTC)[reply]
Those were just examples. Meant to add a note that the hiding of categories on mobile doesn't even really require much resources but dropped it; this just makes it even worse. Add them already, what gives WMF the permission to just hide away this core useful data I wonder. It's not a simplification to say things are technical development capacity problems, it would be solved much faster with more thinking/development capacity or are we waiting for a new Internet protocol for it to be invented before it can be addressed? I was not describing "resource" problems, I was describing a lack of technical development...obviously increasing technical development would result in more technical issues getting fixed and faster. Prototyperspective (talk) 21:15, 19 November 2024 (UTC)[reply]
Sure, but i also think some of these problems are deciding what to do problems. No amount of technical resources will fix a problem if the underlying issue is we simply decided not to do it. Like the category thing in particular is pretty clearly not a case of WMF being too busy - its a trivial change. Its a product failure - there is a mismatch between what commons thinks is important and what that particular team thinks is important. If we want to fix that we need better communication not more people fixing bugs (there are other things where more people would be helpful). Bawolff (talk) 09:11, 20 November 2024 (UTC)[reply]
These were examples so ignore this example if it's a bad example. we simply decided not to do it we did not. its a trivial change which is one reason why I don't donate to WMF and think they're doing a bad job what that particular team thinks is important what team? we need better communication there have been Wishlist proposals and phabricator issues and it's the most-supported request in the technical needs survey. All WMF needs to do is listen a bit and/or engage in any of these venues. not more people fixing bugs I see a tiny fraction of usually quite useful proposals in meta:Category:Community Wishlist Survey results have been implemented so far and on phabricator it's an even more desolate situation. We need far more people fixing bugs. Prototyperspective (talk) 19:28, 20 November 2024 (UTC)[reply]
There are always going to be more tasks than people. Having more people does not mean they will neccesarily work on the things you want them to. Like if there is something everyone agrees needs to be worked, but is pushed for something higher priority - then yes, more people will help with that. If there is something nobody seems to intend to fix, more people won't help, because that is not going to change the intention. Bawolff (talk) 14:48, 25 November 2024 (UTC)[reply]
I wasn't saying anything to the contrary.
Anyway, as a note the likelihood of particularly useful or needed issues/proposals getting implemented is higher with more developers working on issues and more development per dev. Moreover, if lots of issues like pesky bugs are worked on then there is more possibility for other devs to work on interesting features since the major bugs are already being taken care of. e.g. we can't innovate much if everyone is only busy fixing bugs. Prototyperspective (talk) 15:05, 25 November 2024 (UTC)[reply]
It appears the problem was identified earlier (phab:T373979), but the ticket closed without actually being solved in general. I doubt we should do the solution suggested there in dozens if not hundreds of templates. @User:Sannita (WMF)
 ∞∞ Enhancing999 (talk) 08:42, 26 November 2024 (UTC)[reply]
Possibly the solution is to change Template:Lang. Identifying the language shouldn't mark the string as a "description". But then, it's not entirely clear what that class implies.
 ∞∞ Enhancing999 (talk) 09:33, 26 November 2024 (UTC)[reply]
Unless someone comes up with a better solution, I'd suggest we remove the "description" class from Template:Lang.
 ∞∞ Enhancing999 (talk) 10:02, 28 November 2024 (UTC)[reply]
@Enhancing999 Thanks for proposing a solution. Is there anything from WMF side that we can do to help? Asking this to see if I can bring it up at the earliest meeting to discuss. Sannita (WMF) (talk) 13:26, 28 November 2024 (UTC)[reply]

"Use this file" no reaction

[edit]

File:Dunluce Castle. County Antrim, Ireland-LCCN2002717364.jpg clicking the gadget has no response for me. is it the same for you? RoyZuo (talk) 15:12, 20 November 2024 (UTC)[reply]

I can reproduce it. Looking at the browser console, it says “TypeError: s is undefined” at Stockphoto.js, line 451 (where “s” probably means prefill). I currently don’t have the time/energy to debug this; you may want to write on the talk page of the script to avoid the problem getting archived and forgotten without being resolved. —Tacsipacsi (talk) 00:43, 22 November 2024 (UTC)[reply]

Category and disambiguation

[edit]

Hi everybody. I hope it's the right place to my question about categories and disambiguation. I started to move, but now I stopped it, categories of Category:Municipalities in Spain having ambiguos titles to leave space for the disambiguation page. For example I moved Category:Lena to Category:Lena (Asturias), Category:Orbita to Category:Orbita, Ávila, Category:María to Category:María, Almería and so on, around 20 or maybe 30 movings.

N.B. In other situations, when the topic was clearly the main one, I just created a disambiguation page, for example in Category:Ávila I added a link to Category:Ávila (disambiguation), the same in Category:Segovia and Category:Segovia (disambiguation).

Anyway I was asked to revert some edits for some categories, Category:Pego, Category:Llerena, Category:Tormos, Category:Caso,Tibi, Ibi, Navia and some others (but not clear exactly which ones) with the motivation that "are all municipialities and therefore primary topics".

My question is about it: is it always the municipality the primary topic? I do not think so, I can't find a rule about it and I think that every situation is a specific one. I start to check other examples in Category:Disambiguation categories and it seems that the municipality is NOT always the main topic, including when municipality it's olny one. Just some examples in alphabetical order. Category:Aba, Nigeria and Category:Aba, Category:Acushnet and Category:Acushnet, Massachusetts, Category:Adria and Category:Adria (Italy), Category:Adstock and Category:Adstock, Quebec.

I'm ready to revert and/or fix my edits if they are wrong, but I would to know if there are any rules about it or it's better to analize every single situation one by one, and use the talk's page in the category to discuss it. Thank you. MrKeefeJohn (talk) 07:48, 21 November 2024 (UTC)[reply]

I think it's not so much a technical question, than one the needs to be decided for each category separately. There is CfD for this. Obviously, you could try to formulate a more general proposal.
Personally, I think it's understandable that Spanish Wikipedia may use "Lena" for the the municipality and English Wikipedia uses "North Station" for a specific station. Neither should impact our choices for Category:Lena or Category:North Station though.
 ∞∞ Enhancing999 (talk) 11:48, 25 November 2024 (UTC)[reply]
@Enhancing999: thank for you answer. I'm not planning to propose a general proposal, because I agree with you, I mean that "one the needs to be decided for each category separately". By the way in the Spanish wikipedia Lena is a disambiguation. MrKeefeJohn (talk) 08:13, 26 November 2024 (UTC)[reply]

Errors in Template:Licensed-FOP

[edit]

Dear fellow Wikimedians, here is one for the template experts, it regards the {{Licensed-FOP}} template. IMHO this edit has introduced two errors into the template by making it create unmatched/unbalanced {{...}} and <div>...</div>. I have tried to fix this in the two last edits ([1], [2]). Could you please check whether the template is now (more or less) correct again, or if I have overlooked or even introduced yet another error (in the latter case please take my apologies!)? Thank you very much for your help! Best, – Aristeas (talk) 20:34, 22 November 2024 (UTC)[reply]

@Aristeas still broken. See, for example, uses at File:Tower of Taipei 101.jpg and File:Singapore Merlion Park, August 2023.jpg. In fact, Michael Barera removed the template I added on the desc page of his image of T-Mobile arena, citing this broken template as the reason (read this). JWilz12345 (Talk|Contributions) 23:27, 24 November 2024 (UTC)[reply]
Thank you for your input, JWilz12345! It’s the same with my own photos which use the template (example): the FoP is still displayed in a wrong way. The question is: Where is the problem in the code of the {{Licensed-FOP}} template? I think my two edits have fixed the syntax errors introduced by this edit. Maybe the current problems were not related to that, but to some other changes, e.g. to this one?
This is why I left this message, and I can only beg our real template experts to look into this problem. – Aristeas (talk) 09:07, 26 November 2024 (UTC)[reply]
@Labant FYI
 ∞∞ Enhancing999 (talk) 09:09, 26 November 2024 (UTC)[reply]
Reverted it for now. When editing it, please preview it with some of the files mentioned here.
 ∞∞ Enhancing999 (talk) 09:35, 26 November 2024 (UTC)[reply]
Thank you very much, Enhancing999! Now the template works perfectly again. The current (reverted) version is identical to the revision as of 21:16, 8 August 2024 by Jarekt. This confirms that the recent problems were introduced by this edit. In addition to the problems this edit introduced I also doubt whether the layout change made by that edit was really necessary – the additonal left margin may look nice in some contexts, but looks irritating in some other contexts. Therefore I would ask that everybody who wants to change the layout of such widespread templates should discuss this before with other users and then tests the changes first befor deploying them. Thank you – Aristeas (talk) 10:04, 26 November 2024 (UTC)[reply]
Hello everyone, first of all, sorry for the inconvenience. The reason for my contribution was that {{Licensed-FOP}} looks the same as {{Licensed-PD}}. Unfortunately, I could not use the solution there because it would cause problems with {{Self}}. I thought I had found the solution with the <div>-function. But apparently not. I have also reset {{Licensed-TOO}}. I have put the process on my to-do list and will be continue working on it in my user-namespace. --Labant (talk) 14:36, 27 November 2024 (UTC)[reply]
I think I found the error. In any case, the files in question are now displayed correctly. Labant (talk) 13:18, 28 November 2024 (UTC)[reply]
[edit]

Template:Navbox

try Category:Dresden in the 2010s. background is all white on light mode and all dark on dark mode. many gridlines are also missing. RoyZuo (talk) 15:48, 23 November 2024 (UTC)[reply]

"Could not acquire lock" error for larger file uploads

[edit]

Hi!

Especially when it comes to uploading larger files, the error "Could not acquire lock. Somebody else is doing smth. with that file." occurs. It is frustrating when there are many attempts needed to upload a larger file. The error occurs with the Upload Wizard and th chunked upload. It's been already around for several days.

--PantheraLeo1359531 😺 (talk) 13:32, 24 November 2024 (UTC)[reply]

You might want to add it to phab:.
 ∞∞ Enhancing999 (talk) 08:29, 26 November 2024 (UTC)[reply]

✓ Done Thanks, added :) --PantheraLeo1359531 😺 (talk) 16:02, 26 November 2024 (UTC)[reply]

@Sannita (WMF): would you check?
 ∞∞ Enhancing999 (talk) 22:33, 26 November 2024 (UTC)[reply]
Added the tag to put it on the dev's radar. I'll see at the next estimation what can we do about it. Sannita (WMF) (talk) 12:33, 27 November 2024 (UTC)[reply]
@Sannita (WMF) thanks. "Lock" suggests database issues. Together with phab:T379035, this might get upload issues finally resolved.
 ∞∞ Enhancing999 (talk) 09:49, 28 November 2024 (UTC)[reply]

hi, this file seems to crash the file-page itself, also if there is a working file already uploaded - can somebody confirm this? i dont think its a cache-issue - thx

already uploaded new working file: Flag of Ulyanovsk Oblast (2004) 02.svg - other one is not needed anymore, just for debugging --Mrmw (talk) 21:52, 24 November 2024 (UTC)[reply]

file also doesnt appear at user-file-list: c:special:ListFiles/幻光尘 --Mrmw (talk) 22:00, 24 November 2024 (UTC)[reply]
@Mrmw:
The 16 Feb 2019 version fails because it does not have a namespace declaration. Here is Chrome's error message:
https://upload.wikimedia.org/wikipedia/commons/archive/6/6f/20241124212357%21Flag_of_Ulyanovsk_Oblast_%282004%29.svg
This page contains the following errors:
error on line 24 at column 54: Namespace prefix inkscape for connector-curvature on path is not defined
Below is a rendering of the page up to the first error.
The file would have worked on Commons until April 2024 when the renderer was changed. After that, old cache images would give the appearance of working, but the renderer would fail to generate new images.
Glrx (talk) 18:47, 25 November 2024 (UTC)[reply]

Tech News: 2024-48

[edit]

MediaWiki message delivery 22:38, 25 November 2024 (UTC)[reply]

If parser function for media filetype

[edit]

Is there a parser function for checking if the file is of a specific media-type like image or video?

Could not find find a Commons version for Help:Conditional expressions and thus did not find a way for mediatype conditions.

Some templates seem to need this. Prototyperspective (talk) 14:59, 26 November 2024 (UTC)[reply]

@Prototyperspective: This is not a good solution, but I found {{File type en}} that does it by an ugly means. --bjh21 (talk) 14:25, 2 December 2024 (UTC)[reply]
Thank you! This solves it. I think there were also some templates that display image despite that the file is an audio but I can't find them anymore and think some of these change once structured data is added to the file which can take some time (but not all of them). So this may also be useful it various places. Prototyperspective (talk) 15:04, 2 December 2024 (UTC)[reply]
You can get the mime type via Lua reference manual - File metadata. But it doesn't seem that MediaWiki's internal concept of mediatype (image/video/application etc, that the search etc depend for categorising these) is exposed through that endpoint. Then again, this is a very internal definition and concept. —TheDJ (talkcontribs) 14:31, 5 December 2024 (UTC)[reply]

Removal of sodipodi:nodetypes attribute

[edit]

How remove sodipodi:nodetypes attribute on a file ( File:Drapeau de Vaudreuil-Soulanges.svg) ? YanikB (talk) 20:45, 26 November 2024 (UTC)[reply]

You could open the file in Inkscape and "save as optimized SVG", or open the file in a text editor and do it manually/with find and replace. —CalendulaAsteraceae (talkcontribs) 21:04, 26 November 2024 (UTC)[reply]
@YanikB: I took the comment as the file would not display. I added the sodipodi and inkscape namespace declarations, so the file now displays. The file should have had the namespace declarations, it used to display on Commons, but in April 2024 the Commons SVG renderer started rejecting noncompliant SVG files. There are probably thousands of such files on Commons. Glrx (talk) 02:29, 28 November 2024 (UTC)[reply]

Video sound compression

[edit]

Hi there, the original content producer of these videos has noticed a deterioration in the sound quality of the videos there, both old and new. I can hear a drop in the audio quality from the files uploaded.

Has there been a change in the compression levels on sound within the .webm files? JimKillock (talk) 18:22, 2 December 2024 (UTC)[reply]

Tech News: 2024-49

[edit]

MediaWiki message delivery 22:19, 2 December 2024 (UTC)[reply]

Bugged SVG

[edit]

Category:Blue ISO 639 icons with double parentheses looks like this:

Is this a a known issue? Bad old PNG does NOT suffer from this bug. Taylor 49 (talk) 16:34, 3 December 2024 (UTC)[reply]

Looking at File:ISO 639 Icon gwi.svg shows the line
<text x="300" y="141" font-size="150" fill="navy" font-family="Helvetica,Arial,sans-serif" font-weight="bold" transform="scale(0.67 1)" text-anchor="middle">gwi</text>
IIRC, the current renderer has a problem when the scale is not uniform: scale(0.67 1).
Glrx (talk) 20:02, 3 December 2024 (UTC)[reply]
OK ... I can't find it on Phabricator. Should one create a BUG report there? Taylor 49 (talk) 23:19, 3 December 2024 (UTC)[reply]
These images should be fixed rather than the software. Sjoerd de Bruin (talk) 23:23, 3 December 2024 (UTC)[reply]
My SVG spec (admittedly not very good) says:
scale(<sx> [<sy>]), which specifies a scale operation by sx and sy. If <sy> is not provided, it is assumed to be equal to <sx>
Given that, the images are valid. Anyone has an authoritative SVG spec saying that different scaling factors for X and Y are invalid? Taylor 49 (talk) 23:31, 3 December 2024 (UTC)[reply]
The files are legitimate, so they should not need to be fixed. Fixing them is also problematic because the support for font-stretch="condensed" (the practical effect of the nonuniform scaling) is poor. Also, Commons does not support textLength.
There was an involved discussion about this problem a long time ago, but I could not find it. I also did not find something on Phabricator, so a Phabricator issue should be started. Someone can check whether this bug is already fixed in later versions of librsvg.
Glrx (talk) 23:42, 3 December 2024 (UTC)[reply]
Previously reported at https://en.wikipedia.org/wiki/Wikipedia:SVG_help/Archive_10#Text_misaligned_(not_previous_bug) cmɢʟee ⋅τaʟκ 13:13, 4 December 2024 (UTC)[reply]

Attribution Name metadata not rendering correctly

[edit]
aufBuchen banner with the forest behind somewhat visible

When I upload and download a JPG file with the XMP.Attribution Name set to First Last <first.last@provider.tld>, Wikimedia Commons, for some reason, omits the space char between Last and < in the "When re-using this work, please credit" field in the Metadata section. This is the only name/email address combination that renders incorrectly in this section. So a bit odd really.

The given thumbnail provides an example. A small but not insignificant bug. I also searched the Village Pump archives but could not find any reference to this particular problem. Best, RobbieIanMorrison (talk) 21:22, 4 December 2024 (UTC)[reply]

I can confirm that this very minor bug exists. In the file in the field "author" there is ordinary space $20 followed by ordinary less-than-sign $3C. However in the field "please credit" there is ordinary space $20 folowed by a HTML-encoded less-than-sign. Taylor 49 (talk) 21:58, 4 December 2024 (UTC)[reply]
As it happens, my Thunderbird mail client adds back the missing space char when the current value is copy/pasted in. RobbieIanMorrison (talk) 09:15, 5 December 2024 (UTC)[reply]
it's probably because it can be html, and it does some sort of normalisation on it. These parts of the MediaWiki code tend to be rather obscure. —TheDJ (talkcontribs) 14:13, 5 December 2024 (UTC)[reply]
Speaking as a programmer, it is usually worth fixing bugs. An artifact that is brushed aside as trivial may well indicate a more significant problem. And I would also argue that image metadata should be faithfully replicated in all cases. RobbieIanMorrison (talk) 07:33, 7 December 2024 (UTC)[reply]

SVG upload error

[edit]

Hi all

I'm trying to help UN FAO upload some maps to Commons but I'm getting an error I've never seen before, the error happens when I try to upload the SVG files, does anyone know what the issue is and can someone suggest steps to fix them? I'm not very technical so a vague answer isn't really going to help a lot :)

The error message is maybe 20 pages long so I'll just copy the start of it in below.

  Found href to unsafe data: URI target <image http://www.w3.org/1999/xlink:href=@data:;base64,

Thanks so much

. John Cummings (talk) 15:56, 5 December 2024 (UTC)[reply]

@John Cummings:
The ...xlink:href=@data:mimetype;base64,.. is a data URL. https://developer.mozilla.org/en-US/docs/Web/URI/Schemes/data
A data URL allows arbitrary content. MediaWiki wants to limit that content, so it only accepts a limited number of data URL mimetypes. The mimetype is not specified in the data URL, so MediaWiki will reject the upload.
The element is probably trying to include a bitmap image. Inserting the appropriate mimetype between the colon and semicolon should fix the problem. Acceptable mimetypes are image/jpeg or /image/png.
Glrx (talk) 18:47, 5 December 2024 (UTC)[reply]
Hi Glrx thanks very much for the technical explanation, unfortunately I'm far too much of a muggle to work out how to use it. Do you have a suggestion of which program to use and what buttons to press to resolve this? Thanks again, John Cummings (talk) 08:34, 6 December 2024 (UTC)[reply]
@John Cummings:
Use a text editor. Search for href="@data:. then add the appropriate mimetype after the colon and before the semicolon. Save the file. Then open the file in a browser to see that it displays correctly (Windows: locate file in the File explorer; then right click and open with Chrome/Edge/Firefox/whatever). If the file is good, then upload the file to Commons.
Glrx (talk) 16:13, 6 December 2024 (UTC)[reply]

Sorting audio files by duration

[edit]

I'd like to sort audio files not by recency or relevance but by duration (maybe filesize would also work as a proxy for that). Is that possible somehow? I'd like to use it in a category of spoken Wikipedia audios for example to be able to choose between a very long or a shorter audio. It would probably be useful also for many other kinds of applications. Prototyperspective (talk) 16:39, 5 December 2024 (UTC)[reply]

Image duration is not an indexed field in the database I believe. It's only in the db's metadata structure of a file's record, which makes it difficult to query over a collection of files. —TheDJ (talkcontribs) 10:42, 6 December 2024 (UTC)[reply]
I figured maybe it was in the searchindex, but I think it isn't in those indexes either. —TheDJ (talkcontribs) 10:47, 6 December 2024 (UTC)[reply]
But you can sort by filesize from quarry: https://quarry.wmcloud.org/query/88499TheDJ (talkcontribs) 10:49, 6 December 2024 (UTC)[reply]
Thanks, that's helpful. However, that's just the filesize, not the duration and I'm looking for something that can be used in the UI (integrated into MediaSearch or SpecialSearch). Strange if it's not in the database since on the file page there is a field "Dimensions" which shows both the file-size and the duration (except for files with this bug). Prototyperspective (talk) 11:11, 6 December 2024 (UTC)[reply]
The file page is just one page, it can descend into the metadata relatively cheaply. Sorting is a 140+ million row operation and for that we need to pre-extract the information and put it into a separate column of the database and keep an index. We do this for width, height and file size, but not for duration. —TheDJ (talkcontribs) 15:54, 10 December 2024 (UTC)[reply]
An extra column for duration like for media width would be very useful then. It would also enable finding & fixing more of the files that display a duration of 0 (and by now I also found a mp3 and an ogg file with that). Prototyperspective (talk) 16:07, 10 December 2024 (UTC)[reply]

Shifting Mbox to Lua

[edit]

Hello, you are invited to participate in the discussion at Template_talk:Mbox#Shift_to_LuaMatrix(!) ping onewhen replying {user - talk? - uselesscontributions} 20:40, 5 December 2024 (UTC)[reply]

Error with a file

[edit]

Hello, I noticed this file File:Bihar district location map Bhojpur.svg, the image is not loading, and opening the image shows message

error on line 3 at column 43: xmlns:ns: '&#38;#38;#38;ns_sfw;' is not a valid URI

I hope somebody can fix it. Thanks, ExclusiveEditor (talk) 20:50, 5 December 2024 (UTC)[reply]

Fixed namespace declaration. File should display in a couple hours. Glrx (talk) 22:01, 5 December 2024 (UTC)[reply]

Lua error: expandTemplate: template "subst:Custom license marker added by UW" does not exist.

[edit]

Is anyone else getting this message on the file pages when using the custom license option on the Upload Wizard? Example at File:(CHN-Shanghai) Pudong Yanggao W0K-114 沪A31192D 581 2024-12-08.jpg. 沪A 05683DS5A-0043 14:08, 8 December 2024 (UTC)[reply]

Someone should batch-remove all 142 instances of {{self|subst:Custom license marker added by UW}} after phab:T364150 is fixed. See Template:Custom license marker added by UW for historical context. Dexxor (talk) 12:56, 18 December 2024 (UTC)[reply]

Tech News: 2024-50

[edit]

MediaWiki message delivery 22:12, 9 December 2024 (UTC)[reply]

Dezoomify and Imperial War Museum images

[edit]

I've slowly been requesting overwriting of various files from the IWM. They've been so gracious in correcting exposure on some of those (as I write this, I begin to wonder whether the modifications are enough to warrant copyright protection...), but there being multiple versions of a file seems to confuse Dezoomify, who only pulls the second version with lighting issues. With the help of ChatGPT, I could extract the exposure-corrected one, albeit at a reduced-resolution (1000x1300, compared to the 2400x3000 unedited) version of the edited image. Is there something I'm doing wrong in terms of extracting the edited image in all of its glorious pixels?

The IWM file in question is https://www.iwm.org.uk/collections/item/object/205022125

Here's the ChatGPT convo: https://chatgpt.com/share/67577715-c474-8003-a35e-2456499c0a64

Thanks. JayCubby (talk) 23:12, 9 December 2024 (UTC)[reply]

Similarly, there appears to be a better version of File:John Finnis (captain) 2.jpg (source: https://collections.slsa.sa.gov.au/resource/B+343) at https://collections.slsa.sa.gov.au/resource/B+343/tiles.json
but Dezoomify isn't working on the code as I'd expect:
Extended content
{"levels":[{"name":"z0","width":3006,"height":3284,"tiles":[{"y":0,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/93\/ee\/4ea0-8f91-594a-bb45-6e36147b4cac.jpg"},{"y":0,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/1b\/31\/9d2a-035e-58bb-8c1f-38999503f045.jpg"},{"y":0,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/2c\/6c\/168b-2b7c-52bd-9b82-747fead2bbb4.jpg"},{"y":0,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/74\/ac\/d084-db20-5cdc-afe8-a285f5c22335.jpg"},{"y":0,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/d0\/da\/58b4-c901-5e36-abfe-31676e0b4917.jpg"},{"y":0,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/aa\/d9\/0f37-25da-5193-b432-a3899876789b.jpg"},{"y":1,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/9b\/b1\/989e-d032-5c2a-9c1c-99e9ad2f8c3b.jpg"},{"y":1,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/80\/3d\/97c0-6713-5bfc-b6af-5e9dd24fe741.jpg"},{"y":1,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/ce\/ed\/cfd7-7f96-59a5-a91c-60d83751a1e2.jpg"},{"y":1,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/5e\/20\/c4df-e97e-56f7-8584-4bf3b4697f53.jpg"},{"y":1,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/58\/55\/7f12-d001-5439-9f45-1c8f0e122b5f.jpg"},{"y":1,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/18\/7d\/f8ad-7ccb-5c0e-ae3f-cd7901f595f7.jpg"},{"y":2,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/07\/e1\/cf54-0773-5c12-9ca9-bacd44deb945.jpg"},{"y":2,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/0b\/35\/0555-cc62-5107-9673-39e8fb77e77e.jpg"},{"y":2,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/3b\/50\/2e1e-8d87-5503-b37b-3e38229e29ae.jpg"},{"y":2,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/36\/e1\/018c-1d1d-551f-98e3-46e998cb5933.jpg"},{"y":2,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/26\/23\/bf35-51ee-55ce-92dd-7c983fa240e8.jpg"},{"y":2,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/58\/2b\/0786-dd37-5392-b071-772ee8d09072.jpg"},{"y":3,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/08\/bc\/901e-f710-54af-a4f7-f03ae3790229.jpg"},{"y":3,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/d4\/f6\/1416-dbcb-5ce1-b770-b2537d217f04.jpg"},{"y":3,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/00\/92\/3759-befa-5640-8cc6-4ba6df34c1b4.jpg"},{"y":3,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/61\/56\/c6b9-9915-5f1d-b498-5fd2f7f14571.jpg"},{"y":3,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/c1\/7a\/8c83-9837-5bd8-9cd9-d4181cb3883f.jpg"},{"y":3,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/ad\/45\/d831-e582-596d-bfec-58642336f579.jpg"},{"y":4,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/f3\/3b\/d96e-dd16-511a-89f1-86fff5a0d0e1.jpg"},{"y":4,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/92\/be\/9383-9be8-5ce9-8ab0-ac6f207fd09b.jpg"},{"y":4,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/c6\/36\/c01d-4018-5b8a-a87f-cd1cf9338003.jpg"},{"y":4,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/80\/77\/81c0-ea95-5bbb-a9ef-28fec974c7a2.jpg"},{"y":4,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/d8\/1c\/9218-a311-5572-bd1f-e0f9c044fd65.jpg"},{"y":4,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/88\/1c\/c60e-f76c-5d17-9169-387f67aa5cc0.jpg"},{"y":5,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/1f\/b9\/4b6c-7427-502f-84c1-785d75b6b98d.jpg"},{"y":5,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/61\/37\/d011-c75d-5b14-92fe-cbcb39448630.jpg"},{"y":5,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/0a\/97\/0022-9699-55c9-9d46-c027d10d14d2.jpg"},{"y":5,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/e0\/91\/e26e-32a9-512b-97b3-c050b770b978.jpg"},{"y":5,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/b6\/cd\/8149-7875-5711-964b-124dd03def54.jpg"},{"y":5,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/ea\/b6\/f5d8-9a15-5e38-bc4b-54d39724d413.jpg"},{"y":6,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/3f\/6d\/f8ad-b178-5bdb-b342-d51131d24f39.jpg"},{"y":6,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/4d\/14\/15a1-af49-5943-93bc-862741798f4f.jpg"},{"y":6,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/1b\/54\/1587-3fd9-58b5-99e7-2d87ba3fe4da.jpg"},{"y":6,"x":3,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/c1\/0a\/f6c7-82d7-5438-8eee-c502db386eb6.jpg"},{"y":6,"x":4,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/dc\/64\/8a9b-731f-55ee-b0f5-939711f58e35.jpg"},{"y":6,"x":5,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/13\/e0\/be03-1615-5668-bca7-4d43223774e5.jpg"}]},{"name":"z1","width":1503,"height":1642,"tiles":[{"y":0,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/f1\/c4\/8c1e-cdcf-5bb3-96a9-c48a4f860863.jpg"},{"y":0,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/d8\/ca\/45c9-07bf-5f35-a07d-dec980c1020a.jpg"},{"y":0,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/48\/b0\/b576-df0d-5c22-827a-24764fad0bc5.jpg"},{"y":1,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/15\/91\/5c3f-151d-54a1-80ef-5bf552bd5ed1.jpg"},{"y":1,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/28\/19\/9e51-c58c-5474-9006-48c159853eab.jpg"},{"y":1,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/8c\/9c\/3076-c290-5432-9502-0053dd3261a4.jpg"},{"y":2,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/2b\/fd\/6a89-9468-5737-9e08-6b40dfd4a1ab.jpg"},{"y":2,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/3c\/25\/b1f8-2f4e-5354-a9e1-147b772f1572.jpg"},{"y":2,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/74\/ef\/8de9-bf88-5715-8fa4-f1bdc52a9672.jpg"},{"y":3,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/e9\/ca\/9eb7-2447-5aff-8b1a-abd774fa1337.jpg"},{"y":3,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/ad\/eb\/a514-b9ea-5ad2-a86d-ccd3348075e1.jpg"},{"y":3,"x":2,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/1e\/e3\/6d21-254f-5483-bfc1-68cdb761f7f2.jpg"}]},{"name":"z2","width":751,"height":821,"tiles":[{"y":0,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/07\/d8\/d3d2-47fc-557a-8bae-1c429d2f0d29.jpg"},{"y":0,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/ef\/9e\/693e-acd5-5455-a55a-471150fb2faf.jpg"},{"y":1,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/8c\/a3\/5bc9-e28e-5c16-9300-9f6087659565.jpg"},{"y":1,"x":1,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/ec\/5d\/cf8c-46a3-5e07-a8e2-f363ff9ecbb2.jpg"}]},{"name":"z3","width":375,"height":410,"tiles":[{"y":0,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/5c\/97\/6f40-b15f-57d5-964d-d5c9d86d6742.jpg"}]},{"name":"z4","width":187,"height":205,"tiles":[{"y":0,"x":0,"url":"https:\/\/d1red3q7jhuy4m.cloudfront.net\/13\/06\/fffe-74e1-5a68-bf30-3b531ba246f2.jpg"}]}]}

JayCubby (talk) 17:07, 10 December 2024 (UTC)[reply]

Hi. If Dezoomify does not yield the desired result, then we have other methods ... First, look at the code for the page. On the page mentioned in IWM, press Shift + Ctrl + i (works in Firefox) to see the code window. In the code window, you should use the "Network" tab. Then click on the desired picture (the one to the left?). You will see three lines of code, one with the "info.json" file that is used by Dezoomify, and two with jpg files that result in thumbs of the picture. If you click on the bottom jpg codeline, you will see this code: https://media.iwm.org.uk/cantaloupe/iiif/2/171%7C%7C950%7C%7Csuper_000000.jpg/full/251,/0/default.jpg
Now substitute "251" with "2400" and Voila! You get a picture in 2400 x 3111 (at least that is how it worked for me). You might try with larger values than "2400", but the system at IWM would block that option. Hope this helps. Cheers Rsteen (talk) 03:27, 11 December 2024 (UTC)[reply]
Great, I can do that going forward and many thanks! Often images that have been retouched aren't accessible beyond the 2400px, or so I've unreliably figured out after further digging in the source code. JayCubby (talk) 03:53, 11 December 2024 (UTC)[reply]
Interesting. I use the Dezoomify extension on Chrome, and I only get 1536 x 1990 pixels. Please note that this may not be in the public domain. They say "Press agency", not a government picture. Yann (talk) 09:59, 11 December 2024 (UTC)[reply]

Upload shown as "completed" in OpenRefine, but no upload has been made to Wikimedia Commons

[edit]

Background: I am not new to coding and data processing, but to the Wikimedia Commons sphere. I am developing a batch uploading process for the object photographs of a community archive of everyday material culture in Singapore as image sources for their Wikibase Cloud instance (NGO "My Community, Data Partner of Wikimedia Germany, see here). I was sent here by my post on the general Help Desk: https://commons.wikimedia.org/wiki/Commons:Help_desk#OpenRefine_Upload_to_Wikimedia_Commons_failing_without_notice_(abuse_filter_triggered?).

Problem: I have prepared and reconciled all relevant metadata, filenames and filepath in OpenRefine for a test batch of 5 images, including schema preparation with "add media" to Wikimedia Commons. When I did a first technical trial run of the pipeline a month ago, my images successfully uploaded to Wikimedia Commons even though the metadata was far from perfect at the time. Now that I have worked on the data transformation, following the Wikimedia best practices as closely as I could, I have the same thing happening to me as this user here: https://forum.openrefine.org/t/no-errors-reported-and-the-percentage-completed-went-through-but-no-upload-done/899. I get a "100% percent completed" notification from OpenRefine but no uploads have been made (I checked under my user profile as well as searched for the file names).

For reference, see the permalink to my OpenRefine project (hopefully this works!).

What could be the issue? I'd gladly provide more information once I know what is needed here. Thanks! Esxx24 (talk) 22:54, 11 December 2024 (UTC)[reply]

Tech News: 2024-51

[edit]

MediaWiki message delivery 22:21, 16 December 2024 (UTC)[reply]

Icons8 svg MIME-type not SVG

[edit]

If you install m:User:Tol/RealSVG.js and go to Category:Icons8 flat-icons, you'll see that a ton of the SVGs disappear. Why? According to the W3C checker, their content type is text/plain! Is there some way to (perhaps check all and) change SVGs content types in bulk? Aaron Liu (talk) 01:02, 17 December 2024 (UTC)[reply]

Validate offline and re upload. Or if they are valid and can be identified easily (by prefix for instance) it might be worth it to run a server side script, but this requires a Phabricator ticket. The cause might be that there is no XML DOCtype declared for these files. —TheDJ (talkcontribs) 12:21, 17 December 2024 (UTC)[reply]
Being more concrete with two example files.
Glrx (talk) 18:33, 17 December 2024 (UTC)[reply]

Length of videos

[edit]

These videos (1, 2) are a few seconds long, but they show a length of more than 2 hours. How could this be fixed? — Draceane talkcontrib. 15:29, 17 December 2024 (UTC)[reply]

This generally happens when the files have not been properly muxed. Passing them through ffmpeg (in copy mode) will fix them. —TheDJ (talkcontribs) 17:31, 18 December 2024 (UTC)[reply]
done —TheDJ (talkcontribs) 09:19, 19 December 2024 (UTC)[reply]

Need help replacing a photo

[edit]

Rebecca Moore (en:Rebecca Moore (scientist)) is a friend of mine. When I told her what her picture was used in Wikipedia (because she never looked at her own page - haha), she was appreciative of the guy who uploaded it, but wished he had uploaded one she felt better represented her and her work. (Yes, the Rachel Carson Award was a great honor, but she thinks the work in Brazil with helping Chief Almir and the Surui tribe save their rainforest was more meaningful.) She gave me the original photo that they used in Time Magazine article April 15, 2016,(https://time.com/4295351/rebecca-moore-google-earth-outreach/) to replace it. I cropped the original 1600 x 1062 to be square, but then realized I couldn't upload it. Can someone please do that for me if I get you the photo? And how would I do that? My real email is martha.legare@gmail.com. Thanks much for your help, Martha MarleeRobertson (talk) 05:58, 19 December 2024 (UTC)[reply]

@MarleeRobertson: Hi, We need a written permission from the photographer, unless he/she uploads it her/himself. And it would be much better to have the original image first, it can always be cropped later. Please see COM:VRT for the procedure. Yann (talk) 09:41, 19 December 2024 (UTC)[reply]
Thanks. To make sure I'm clear: we (and thank you!) can replace the current photo as long as we get the Brazilian photographer's permission, not the guy who posted the current photo? The photo I have was taken for Google - I'm 99% sure they paid her for it. (I think the photographer was from Brazil - will check with Rebecca.) I appreciate your help. MarleeRobertson (talk) 04:09, 20 December 2024 (UTC)[reply]

Image failing to load

[edit]

This image, File:Papua New Guinea relief map.svg, is failing to load globally, and I don't see any indication as to why. The image hasn't been modified in a few years, and the image loads from the direct URL ([19]) and from the link on the description page, but doesn't load when it's placed inline. Is this some kind of database error? Ivanvector (talk) 13:55, 19 December 2024 (UTC)[reply]

Bad ns: namespace declaration fixed. Image should appear in a couple hours. Glrx (talk) 19:03, 19 December 2024 (UTC)[reply]
Same problem as #Error with a file above. Glrx (talk) 23:05, 20 December 2024 (UTC)[reply]

Template:Q+/doc on Wikispecies

[edit]

I imported {{Q+}} and Template:Q+/doc from this project into Wikispecies, but the latter is behaving very oddly, and the former not working as expected, and I cannot figure out why. Wikispecies is a small project with few technical editors; can someone assist there, please? Andy Mabbett (Pigsonthewing); Talk to Andy; Andy's edits 16:07, 19 December 2024 (UTC)[reply]