Page MenuHomePhabricator

[Lua task #10] Update code of the "Reign" template on English Wikipedia
Closed, DeclinedPublic

Description

Prerequisite: To work on this task, you MUST have some knowledge of Lua programming already (or another language plus completing the previous basic Lua tasks here in Google Code-in).

On Wikipedia, editors generally use templates to perform complex tasks, not least of which is ensuring that items are displayed in a consistent manner across Wikipedia.

1 Read the documentation for Template:Reign, which is used to provide a consistent display of the reigns of kings, emperors, etc.

2 Read the discussion at [Probably-simple conversion](https://en.wikipedia.org/wiki/Wikipedia_talk:Lua #Probably-simple_conversion), particularly noting the numerous test cases.

3 Create a new sandbox in your user space and collect as many of the test cases as you can find on that page.

If you understand Wikipedia template coding, examine the source of Template:Reign and work out an algorithm to duplicate its functionality. Otherwise, try to work out an algorithm from the task description.

4 Create a new Module sandbox and write a function that takes the same parameters as Template:Reign, and produces the correct output for each of the test cases.

5 In your sandbox, write calls to your module for each of the test cases that demonstrate the output for them.

Event Timeline

RexxS created this task.Dec 18 2017, 12:04 AM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptDec 18 2017, 12:04 AM

I will mentor this in Google-Code-in 2017.

Aklapper renamed this task from [Lua task updating template code] Template Reign to [Lua task #9] Update code of the "Reign" template on English Wikipedia.Dec 18 2017, 11:22 AM
Aklapper updated the task description. (Show Details)
Aklapper moved this task from Proposed tasks to Imported in GCI Site on the Google-Code-in-2017 board.
Aklapper renamed this task from [Lua task #9] Update code of the "Reign" template on English Wikipedia to [Lua task #10] Update code of the "Reign" template on English Wikipedia.Dec 18 2017, 11:34 AM
Aklapper closed this task as Declined.Jan 17 2018, 6:28 PM

Closing this task as it was a placeholder in Phab for Google-Code-in-2017 which is ending these days (no more new tasks can be claimed from now on in GCI 2017).