Wikifunctions:Status updates/2025-03-07
◀ | ![]() ![]() |
▶ |
Recent Changes in the software
The most visible change this week is that now, as we announced previously, wikitext links to Objects like [[Z12345]]
will no longer have the label shown and instead just show their ZID, except on Special pages (T343483). This old feature led to bugs and cache problems, and was not compatible with the new direction MediaWiki is going. This change makes wikitext links to Objects less magical, but preserves the usefulness on Special:RecentChanges and other important tools, similar to how Wikidata handles this.
In terms of smaller features, we're shipping a few this week, but very sweet ones: We have improved the collapsed view where there are calls using Types compounded of multiple inner values, like Z16683/Integers, to use the display functions (T368324). We have also improved the collapsed view of argument reference inside function calls, using the icon rather than the label for "argument reference" and so being more compact (T383883). We now prompt Implementation writers that they can use Wikifunctions.Debug in their code to work out what's going wrong, and remind them to remove it before publishing (T355848). We landed another keyboard accessibility improvement from User:Abbe98, this time to make the ZID in the page title focusable, and allow its copy-to-clipboard feature to be triggered by pressing <Enter>. Thank you!
As part of our fixing bugs, we tweaked the styles of the short description input so that it doesn't overflow the column in narrower windows (T385993). We fixed a bug that meant pressing the close button on the "in other languages" box didn't work; thanks to User:99of9 for reporting that (T386315). We replaced our custom code for the ModeSelector (move up/move down/delete control) with the newer Codex standard "MenuGroup" component, which will be more accessible and updated more consistently with the rest of the UX (T384520).
We also landed a major part of our code to integrate Wikifunction calls in wikitext with the visual and the 2017 wikitext editors, which we hope to show off soon!
In terms of engineering changes, we have expanded the testing for some of our critical code around setting up the page, as part of splitting this code up between 'client' code for Wikipedias and 'repo' code for Wikifunctions.org. This also allowed us to finally land a great patch from Aditya Kumar from late last year that use more robust tools to manipulate the URLs of pages we create links to, like history or edit pages (T360229). We updated our front-end Pinia store code to replace anonymous getter functions with named functions, to help with profiling (T386188). We fixed a bug in our logging that meant some monitoring didn't pass server-side validation (T385820). We updated the selenium browser tests to adjust for the new Codex table usage we rolled out two weeks ago (T387540), as part of wider work to run these tests in CI again.
Recording of Volunteers' Corner
The recording of Monday’s Volunteers’ Corner is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
Two talks by Denny Vrandečić in London on Wikifunctions
On Monday, 10 March 2025 14:00 UTC, Denny Vrandečić will talk at King’s College London on the topic of Knowledge in the Age of AI. Wikidata and Wikifunctions will be topics in that talk. The event will be hybrid. You can join either remotely or locally in London. Free registration via Eventbrite is requested if you want to attend. The talk will be recorded.
On the same day at 7pm local time, Denny will also speak at Newspeak.House and introduce Wikifunctions. This talk is on-site only and will not be recorded. Registration is requested.
Fresh Functions Weekly: 61 new Functions
It has been a productive week regarding function creation! Thanks to the community. Here is a list of functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
- hex string as Byte (Z22800): take a two character hex string (00-FF) and return a byte
- has substring (optional case-sensitivity) (Z22812): Returns true if a string contains a specified value. Otherwise it returns false. See also: Z10070
- compress list (Z22820): Filter list by a list of booleans. true = leave, false = exclude.
- hex code point to string (Z22829): enter the hex code point of a unicode character and get it back as as string
- first Object or default (Z22839): returns the first object in a list unless the list is empty, when it returns the specified default object
- Gregorian Date to Julian Day Number (Z22844): converts a Gregorian calendar date to the corresponding Julian day number
- Strings for function searches (Z22849): returns a list of Wikifunctions search strings for copying into the Search box or a Special:Search link
- labels of Wikidata item (Z22853): renvoie les libellés d'un élément Wikidata
- read Byte from string (Z22858): lenient default (language-independent) reader to convert user input to a Byte value
- keep elements common with other list (Z22865): returns the first list in the same order but without any elements that are not on the second list
- read Byte (Z22866): converts a string to a Byte according to the conventions most accepted for a language
- list is duplicate-free? (Z22874): returns true if no two elements of the list are the same
- Byte as prefixed hexadecimal string (Z22883): Prefix is "0x". Uses capitals for the hex digits.
- display Byte (Z22887): converts a Byte to a string to display format for users of a particular language
- Box-Muller Transform (Z22903): The Box-Muller transform is a numerical algorithm that generates normally-distributed random numbers, given uniform random numbers, as in most languages implementation of `rand()`
- read Gregorian year (Z22910): reader function to take a string with an associated language, and return a Gregorian year
- Gregorian year to ISO 8601 year string (Z22920): Always returns at least 4 digits, per ISO 8601. Use expanded form to represent negatives or more than 4 digits.
- Z22925
- date as English "Month day" string (Z22933): no description
- date as "--MM-DD" string (Z22937): This format was in the 2000 ISO 8601, but is now superseded. There is no longer a way of showing the month with the year omitted in that ISO.
- display Day of Roman Year (Z22941): uses the language to determine which formatting function to use
- binary string as byte (Z22946): reads an 8 digit binary string consisting of 0s and 1s as a byte
- Italian indefinite article (Z22964): Get italian indefinite article as a string
- String for function signature search (Z22973): returns a String that can be used in a Wikifunctions search for a function, given Type objects for its arguments and return type
- value of claim from Wikidata item (Z22978): no description
- Conjugate italian adjective (Z22997): Conjugate italian adjective based on gender and number
- Italian cardinal (Z23003): Converts natural number to italian cardinal
- natural number to codepoint (Z23022): no description
- digit string to codepoint (Z23028): converts a string of (western Arabic) decimal digits into the codepoint corresponding to the number in the string
- codepoint from string leniently (Z23031): Converts a string to a codepoint with as little ambiguity and as much flexibility as possible. For digits only, map to the numerical codepoint number. Otherwise return first codepoint of character.
- read code point (Z23041): reads a string leniently with an associated language to return a code point
- code point to digit string (Z23053): return the string of western Arabic digits representing the value of the code point
- code point as character and digits (Z23056): verbose display, format: "c (nnn)"
- codepoint to U+HHHH notation (Z23061): a string showing unicode hex
- code point to natural number (Z23063): no description
- function searches from Type (Z23072): given a single Type object, returns a list of strings suitable for finding functions using Wikifunctions searches
- First plural Lexeme form for a Wikidata Item (Z23082): returns the first plural form (if any) for the first identified lexeme for a given language for a given Wikidata item
A complete list of all functions sorted by when they were created is available on wiki.