Wikipedia talk:Lua
| WP:Lua Project | WT:Lua Project talk | Help | To do | Resources en: m: mw: external |
| To help centralise discussions and keep related topics together, all Wikipedia:Lua subpages' talk pages and Help talk:Lua redirect here. |
| The contents of the Wikipedia:Lua/Requests page were merged into Wikipedia talk:Lua on 5 February 2016. For the contribution history and old versions of the redirected page, please see its history. |
Wikipedia:Lua/To do was nominated for deletion on 21 May 2015. The result of the discussion was keep. |
Archives |
|---|
| This page is archived by ClueBot III. |
Contents
- 1 Issue with test case / TemplateStyles
- 2 Request Lua module for removing/striping leading zeros
- 3 Improving Template:Code
- 4 need help to localize parameter
- 5 Wikidata queries
- 6 Template:Demo demo_kill_categories alias nocat
- 7 Calculating moveable dates
- 8 Do you have small Lua related tasks suitable for new contributors?
- 9 Can Lua be used to parse a section of one page, change the contents and be transcluded on another page?
- 10 WikiProject College football needs assistance with Lua-based template
- 11 Lua error
- 12 Help with calling String.replace
- 13 Timeout on specific settings
- 14 Accessing a page's short description (inside infobox) from another page
- 15 Overhead from a generally unused code path
- 16 Overload Template:Bicolor (Commons)
- 17 Pages where template include size is exceeded
- 18 Module:Infobox
- 19 Navbox with collapsible groups
- 20 teach Module:Graph some new tricks
- 21 Module error on Syrian Civil War map
- 22 How do you look up which pages are directly calling given module?
- 23 Knowing if being called from a disambiguation page
- 24 How can one track module dependencies
- 25 Validating date parameter is in a Template:Start date
- 26 Lua "Beta" template
- 27 Mystery script errors on Wikidata
Issue with test case / TemplateStyles[edit]
Does anyone know how modules treat TemplateStyles? {{Test case}} thought {{Adjacent stations/sandbox}} and {{Adjacent stations/sandbox2}}, with identical wikitext, were different, but when I removed the TemplateStyles tag on each of them the template said they were the same. Jc86035 (talk) 12:38, 24 July 2018 (UTC)
It's a strip marker issue, but Module:Template test case is supposed to handle strip markers with the TestCase:templateOutputIsEqual() function. Both of the transcluded pages below contain the same content. Jc86035 (talk) 10:12, 27 July 2018 (UTC)
| {{User:Jc86035/sandbox3}} | |
|---|---|
{{User:Jc86035/sandbox3}}
table#1 {
table#2 {
["id"] = "Q55975144$de1affe4-4671-ccd3-e899-3b8a0b17b85e",
["mainsnak"] = table#3 {
["datatype"] = "wikibase-item",
["datavalue"] = table#4 {
["type"] = "wikibase-entityid",
["value"] = table#5 {
["entity-type"] = "item",
["id"] = "Q180072",
["numeric-id"] = 180072,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#6 {
["P1352"] = table#7 {
table#8 {
["datatype"] = "quantity",
["datavalue"] = table#9 {
["type"] = "quantity",
["value"] = table#10 {
["amount"] = "+56",
["unit"] = "1",
},
},
["hash"] = "795afdaa702d841ca0e47e7be33d821114f690d9",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#11 {
table#12 {
["datatype"] = "time",
["datavalue"] = table#13 {
["type"] = "time",
["value"] = table#14 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-07-28T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "4cb3c7d7f041790c979cfe2550fef7e46a361e58",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#15 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#16 {
table#17 {
["hash"] = "f311fc807affdae5c2c1d0258732efac0ec736b0",
["snaks"] = table#18 {
["P813"] = table#19 {
table#20 {
["datatype"] = "time",
["datavalue"] = table#21 {
["type"] = "time",
["value"] = table#22 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#23 {
table#24 {
["datatype"] = "url",
["datavalue"] = table#25 {
["type"] = "string",
["value"] = "https://www.billboard.com/articles/columns/chart-beat/8467371/benny-blanco-scores-first-entry-as-an-artist-hot-100",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#26 {
"P854",
"P813",
},
},
table#27 {
["hash"] = "ac76eef33a172bff044bccdebdda0122e853ece1",
["snaks"] = table#28 {
["P813"] = table#29 {
table#30 {
["datatype"] = "time",
["datavalue"] = table#31 {
["type"] = "time",
["value"] = table#32 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#33 {
table#34 {
["datatype"] = "url",
["datavalue"] = table#35 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/hot-100/2018-07-28",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#36 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#37 {
["id"] = "Q55975144$09b6dc13-4603-8a0c-d782-41185aed53d6",
["mainsnak"] = table#38 {
["datatype"] = "wikibase-item",
["datavalue"] = table#39 {
["type"] = "wikibase-entityid",
["value"] = table#40 {
["entity-type"] = "item",
["id"] = "Q180072",
["numeric-id"] = 180072,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#41 {
["P1352"] = table#42 {
table#43 {
["datatype"] = "quantity",
["datavalue"] = table#44 {
["type"] = "quantity",
["value"] = table#45 {
["amount"] = "+52",
["unit"] = "1",
},
},
["hash"] = "94ddf419299338a4a000a7c130caa4e330b8e071",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#46 {
table#47 {
["datatype"] = "time",
["datavalue"] = table#48 {
["type"] = "time",
["value"] = table#49 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-04T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6bf3727bcaa8925c21c2b32a32b5ce471e641243",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#50 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#51 {
table#52 {
["hash"] = "574dc7fb82b6ae8aef454f9dd85175019573199c",
["snaks"] = table#53 {
["P813"] = table#54 {
table#55 {
["datatype"] = "time",
["datavalue"] = table#56 {
["type"] = "time",
["value"] = table#57 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#58 {
table#59 {
["datatype"] = "url",
["datavalue"] = table#60 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/hot-100/2018-08-04",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#61 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#62 {
["id"] = "Q55975144$5e909fb5-4ec1-3ddd-b3e9-1d8f2e1ed149",
["mainsnak"] = table#63 {
["datatype"] = "wikibase-item",
["datavalue"] = table#64 {
["type"] = "wikibase-entityid",
["value"] = table#65 {
["entity-type"] = "item",
["id"] = "Q472737",
["numeric-id"] = 472737,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#66 {
["P1352"] = table#67 {
table#68 {
["datatype"] = "quantity",
["datavalue"] = table#69 {
["type"] = "quantity",
["value"] = table#70 {
["amount"] = "+31",
["unit"] = "1",
},
},
["hash"] = "6618ac919f7f356a6b55c9572d75a68380741b6b",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#71 {
table#72 {
["datatype"] = "time",
["datavalue"] = table#73 {
["type"] = "time",
["value"] = table#74 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-04T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6bf3727bcaa8925c21c2b32a32b5ce471e641243",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#75 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#76 {
table#77 {
["hash"] = "08343cf1592a8ab58e16e115208d1fa5c4153e32",
["snaks"] = table#78 {
["P813"] = table#79 {
table#80 {
["datatype"] = "time",
["datavalue"] = table#81 {
["type"] = "time",
["value"] = table#82 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#83 {
table#84 {
["datatype"] = "url",
["datavalue"] = table#85 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/canadian-hot-100/2018-08-04",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#86 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#87 {
["id"] = "Q55975144$8e24c179-426a-68e1-ea96-83196e130f18",
["mainsnak"] = table#88 {
["datatype"] = "wikibase-item",
["datavalue"] = table#89 {
["type"] = "wikibase-entityid",
["value"] = table#90 {
["entity-type"] = "item",
["id"] = "Q193259",
["numeric-id"] = 193259,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#91 {
["P1352"] = table#92 {
table#93 {
["datatype"] = "quantity",
["datavalue"] = table#94 {
["type"] = "quantity",
["value"] = table#95 {
["amount"] = "+23",
["unit"] = "1",
},
},
["hash"] = "b9638b3f6764ba46fd03a70fa15e73aae62b4efd",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#96 {
table#97 {
["datatype"] = "time",
["datavalue"] = table#98 {
["type"] = "time",
["value"] = table#99 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-03T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "66f09d32a0f51e52cb9bd4b20fed131e00ffee46",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#100 {
table#101 {
["datatype"] = "time",
["datavalue"] = table#102 {
["type"] = "time",
["value"] = table#103 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-09T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6114c53800049b6da7fc16fad084a5870e7c539b",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#104 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#105 {
table#106 {
["hash"] = "05624006c6c4cb447f73c7841b9f96338d5a9136",
["snaks"] = table#107 {
["P813"] = table#108 {
table#109 {
["datatype"] = "time",
["datavalue"] = table#110 {
["type"] = "time",
["value"] = table#111 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#112 {
table#113 {
["datatype"] = "url",
["datavalue"] = table#114 {
["type"] = "string",
["value"] = "http://www.officialcharts.com/charts/singles-chart/20180803/7501/",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#115 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#116 {
["id"] = "Q55975144$a3a88f0b-430a-1ab6-1636-48b9dce984ad",
["mainsnak"] = table#117 {
["datatype"] = "wikibase-item",
["datavalue"] = table#118 {
["type"] = "wikibase-entityid",
["value"] = table#119 {
["entity-type"] = "item",
["id"] = "Q1056800",
["numeric-id"] = 1056800,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#120 {
["P1352"] = table#121 {
table#122 {
["datatype"] = "quantity",
["datavalue"] = table#123 {
["type"] = "quantity",
["value"] = table#124 {
["amount"] = "+11",
["unit"] = "1",
},
},
["hash"] = "8caafa6ef94abf71b9210d7a524a4278a5ea205a",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#125 {
table#126 {
["datatype"] = "time",
["datavalue"] = table#127 {
["type"] = "time",
["value"] = table#128 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-07-28T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "0097679fbed6bd57e201a2fa60e1e0d52725384b",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#129 {
table#130 {
["datatype"] = "time",
["datavalue"] = table#131 {
["type"] = "time",
["value"] = table#132 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-03T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "66a251d079434df20e8e9f7350f3064b5965fe8b",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#133 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#134 {
table#135 {
["hash"] = "fbfbba71df0a22ad9f718c426abe31817cc724c0",
["snaks"] = table#136 {
["P813"] = table#137 {
table#138 {
["datatype"] = "time",
["datavalue"] = table#139 {
["type"] = "time",
["value"] = table#140 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#141 {
table#142 {
["datatype"] = "url",
["datavalue"] = table#143 {
["type"] = "string",
["value"] = "http://irma.ie/index.cfm?page=irish-charts&chart=Singles",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#144 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#145 {
["id"] = "Q55975144$a4c4ce7b-48c8-6580-f1b9-1558e6723ed5",
["mainsnak"] = table#146 {
["datatype"] = "wikibase-item",
["datavalue"] = table#147 {
["type"] = "wikibase-entityid",
["value"] = table#148 {
["entity-type"] = "item",
["id"] = "Q30916704",
["numeric-id"] = 30916704,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#149 {
["P1352"] = table#150 {
table#151 {
["datatype"] = "quantity",
["datavalue"] = table#152 {
["type"] = "quantity",
["value"] = table#153 {
["amount"] = "+5",
["unit"] = "1",
},
},
["hash"] = "e55ddd08ce050b5a1f3ba07f119cdf406d6266d2",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#154 {
table#155 {
["datatype"] = "time",
["datavalue"] = table#156 {
["type"] = "time",
["value"] = table#157 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-06T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "b0a9cdf37ce46a988d6408750daa285f0debc0dc",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#158 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#159 {
table#160 {
["hash"] = "f1b8b6136d58af1220d558801cfa91a20881c002",
["snaks"] = table#161 {
["P813"] = table#162 {
table#163 {
["datatype"] = "time",
["datavalue"] = table#164 {
["type"] = "time",
["value"] = table#165 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#166 {
table#167 {
["datatype"] = "url",
["datavalue"] = table#168 {
["type"] = "string",
["value"] = "https://www.ariacharts.com.au/charts/singles-chart",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#169 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#170 {
["id"] = "Q55975144$cd482794-4935-fa2e-aa9b-0406896a9196",
["mainsnak"] = table#171 {
["datatype"] = "wikibase-item",
["datavalue"] = table#172 {
["type"] = "wikibase-entityid",
["value"] = table#173 {
["entity-type"] = "item",
["id"] = "Q1407678",
["numeric-id"] = 1407678,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#174 {
["P1352"] = table#175 {
table#176 {
["datatype"] = "quantity",
["datavalue"] = table#177 {
["type"] = "quantity",
["value"] = table#178 {
["amount"] = "+40",
["unit"] = "1",
},
},
["hash"] = "d321b6916ab1365ea57dde8a8e6b984aa60d9fe7",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#179 {
table#180 {
["datatype"] = "time",
["datavalue"] = table#181 {
["type"] = "time",
["value"] = table#182 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-06T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "b0a9cdf37ce46a988d6408750daa285f0debc0dc",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#183 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#184 {
table#185 {
["hash"] = "9306ace33b4c5c9fb333afbf8b780418d297e66c",
["snaks"] = table#186 {
["P813"] = table#187 {
table#188 {
["datatype"] = "time",
["datavalue"] = table#189 {
["type"] = "time",
["value"] = table#190 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#191 {
table#192 {
["datatype"] = "url",
["datavalue"] = table#193 {
["type"] = "string",
["value"] = "https://nztop40.co.nz/index.php/chart/singles?chart=4508",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#194 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#195 {
["id"] = "Q55975144$749958e7-4405-02cb-8ac4-5627a0e34674",
["mainsnak"] = table#196 {
["datatype"] = "wikibase-item",
["datavalue"] = table#197 {
["type"] = "wikibase-entityid",
["value"] = table#198 {
["entity-type"] = "item",
["id"] = "Q180072",
["numeric-id"] = 180072,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#199 {
["P1352"] = table#200 {
table#201 {
["datatype"] = "quantity",
["datavalue"] = table#202 {
["type"] = "quantity",
["value"] = table#203 {
["amount"] = "+44",
["unit"] = "1",
},
},
["hash"] = "1bc0331715060e899cf0a9077776456c2c37ba3b",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#204 {
table#205 {
["datatype"] = "time",
["datavalue"] = table#206 {
["type"] = "time",
["value"] = table#207 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6b3b67bdd5d4a42af87d120c03c043df07817d12",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#208 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#209 {
table#210 {
["hash"] = "169737185dec3a5efbeed79a86769a6bd688d34a",
["snaks"] = table#211 {
["P813"] = table#212 {
table#213 {
["datatype"] = "time",
["datavalue"] = table#214 {
["type"] = "time",
["value"] = table#215 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#216 {
table#217 {
["datatype"] = "url",
["datavalue"] = table#218 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/hot-100/2018-08-11",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#219 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#220 {
["id"] = "Q55975144$5815cb30-4f3a-3f82-9ac6-0303f6d45316",
["mainsnak"] = table#221 {
["datatype"] = "wikibase-item",
["datavalue"] = table#222 {
["type"] = "wikibase-entityid",
["value"] = table#223 {
["entity-type"] = "item",
["id"] = "Q472737",
["numeric-id"] = 472737,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#224 {
["P1352"] = table#225 {
table#226 {
["datatype"] = "quantity",
["datavalue"] = table#227 {
["type"] = "quantity",
["value"] = table#228 {
["amount"] = "+27",
["unit"] = "1",
},
},
["hash"] = "d4c96c87f0e969e34a17324e067fe292b8465f29",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#229 {
table#230 {
["datatype"] = "time",
["datavalue"] = table#231 {
["type"] = "time",
["value"] = table#232 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6b3b67bdd5d4a42af87d120c03c043df07817d12",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#233 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#234 {
table#235 {
["hash"] = "fce7d0ab0ed06f79c6738f8335b54da87502b687",
["snaks"] = table#236 {
["P813"] = table#237 {
table#238 {
["datatype"] = "time",
["datavalue"] = table#239 {
["type"] = "time",
["value"] = table#240 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#241 {
table#242 {
["datatype"] = "url",
["datavalue"] = table#243 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/canadian-hot-100/2018-08-11",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#244 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#245 {
["id"] = "Q55975144$89d3836f-42f0-81ac-94a0-6e299fbb7c17",
["mainsnak"] = table#246 {
["datatype"] = "wikibase-item",
["datavalue"] = table#247 {
["type"] = "wikibase-entityid",
["value"] = table#248 {
["entity-type"] = "item",
["id"] = "Q193259",
["numeric-id"] = 193259,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#249 {
["P1352"] = table#250 {
table#251 {
["datatype"] = "quantity",
["datavalue"] = table#252 {
["type"] = "quantity",
["value"] = table#253 {
["amount"] = "+12",
["unit"] = "1",
},
},
["hash"] = "1677b669a22f2e92d6211557b0093fe5e605feaf",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#254 {
table#255 {
["datatype"] = "time",
["datavalue"] = table#256 {
["type"] = "time",
["value"] = table#257 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-10T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "47e634ce009d3ea4b95a12c8d98cfd19ae03ba7c",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#258 {
table#259 {
["datatype"] = "time",
["datavalue"] = table#260 {
["type"] = "time",
["value"] = table#261 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-16T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "c9d60358efd18e7c1bf540711008757d0bf96056",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#262 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#263 {
table#264 {
["hash"] = "9a99ef51891b4e145ea71786e65fd2754da22eb9",
["snaks"] = table#265 {
["P813"] = table#266 {
table#267 {
["datatype"] = "time",
["datavalue"] = table#268 {
["type"] = "time",
["value"] = table#269 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#270 {
table#271 {
["datatype"] = "url",
["datavalue"] = table#272 {
["type"] = "string",
["value"] = "http://www.officialcharts.com/charts/singles-chart/20180810/7501/",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#273 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#274 {
["id"] = "Q55975144$f239713c-42ad-8ce9-2e58-47a9f7d4f090",
["mainsnak"] = table#275 {
["datatype"] = "wikibase-item",
["datavalue"] = table#276 {
["type"] = "wikibase-entityid",
["value"] = table#277 {
["entity-type"] = "item",
["id"] = "Q1056800",
["numeric-id"] = 1056800,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#278 {
["P1352"] = table#279 {
table#280 {
["datatype"] = "quantity",
["datavalue"] = table#281 {
["type"] = "quantity",
["value"] = table#282 {
["amount"] = "+6",
["unit"] = "1",
},
},
["hash"] = "cbaadcd36f0b877dbbda357045e54cd9b6faf67c",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#283 {
table#284 {
["datatype"] = "time",
["datavalue"] = table#285 {
["type"] = "time",
["value"] = table#286 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-04T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "df16ff450852dc2b0dbc46e7c8bd8193c43769a1",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#287 {
table#288 {
["datatype"] = "time",
["datavalue"] = table#289 {
["type"] = "time",
["value"] = table#290 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-10T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "458127f419a30a6dfc6c521d1f65dee65f1c797b",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#291 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#292 {
table#293 {
["hash"] = "5c1c37b18083a99bbe7c063cc8b8e4f13e10cd3f",
["snaks"] = table#294 {
["P813"] = table#295 {
table#296 {
["datatype"] = "time",
["datavalue"] = table#297 {
["type"] = "time",
["value"] = table#298 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#299 {
table#300 {
["datatype"] = "url",
["datavalue"] = table#301 {
["type"] = "string",
["value"] = "http://irma.ie/index.cfm?page=irish-charts&chart=Singles",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#302 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#303 {
["id"] = "Q55975144$9f5be1b1-4431-1348-4685-1aee40f16136",
["mainsnak"] = table#304 {
["datatype"] = "wikibase-item",
["datavalue"] = table#305 {
["type"] = "wikibase-entityid",
["value"] = table#306 {
["entity-type"] = "item",
["id"] = "Q30916704",
["numeric-id"] = 30916704,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#307 {
["P1352"] = table#308 {
table#309 {
["datatype"] = "quantity",
["datavalue"] = table#310 {
["type"] = "quantity",
["value"] = table#311 {
["amount"] = "+5",
["unit"] = "1",
},
},
["hash"] = "e55ddd08ce050b5a1f3ba07f119cdf406d6266d2",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#312 {
table#313 {
["datatype"] = "time",
["datavalue"] = table#314 {
["type"] = "time",
["value"] = table#315 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-13T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "52c3d0b073fd9c0a1659abf80eb1faf0b57502de",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#316 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#317 {
table#318 {
["hash"] = "5ed0543affc0348ab72af4c33bb16ec1111af9fa",
["snaks"] = table#319 {
["P813"] = table#320 {
table#321 {
["datatype"] = "time",
["datavalue"] = table#322 {
["type"] = "time",
["value"] = table#323 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#324 {
table#325 {
["datatype"] = "url",
["datavalue"] = table#326 {
["type"] = "string",
["value"] = "https://www.ariacharts.com.au/charts/singles-chart",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#327 {
"P854",
"P813",
},
},
table#328 {
["hash"] = "f17d25e688bd5726a4932ddbf7cacabb506d6609",
["snaks"] = table#329 {
["P813"] = table#330 {
table#331 {
["datatype"] = "time",
["datavalue"] = table#332 {
["type"] = "time",
["value"] = table#333 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#334 {
table#335 {
["datatype"] = "url",
["datavalue"] = table#336 {
["type"] = "string",
["value"] = "http://cdn.aria.com.au/pdfs/C59F0A334271181ED9323B30BE6A23D715104417DCEF1B637E14A57985F202B8/ARIA%20Singles%20Chart.pdf?seq=13",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#337 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#338 {
["id"] = "Q55975144$70d2045b-4f0a-e53b-44be-95f13fadc230",
["mainsnak"] = table#339 {
["datatype"] = "wikibase-item",
["datavalue"] = table#340 {
["type"] = "wikibase-entityid",
["value"] = table#341 {
["entity-type"] = "item",
["id"] = "Q1407678",
["numeric-id"] = 1407678,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#342 {
["P1352"] = table#343 {
table#344 {
["datatype"] = "quantity",
["datavalue"] = table#345 {
["type"] = "quantity",
["value"] = table#346 {
["amount"] = "+3",
["unit"] = "1",
},
},
["hash"] = "ba2a02dbc6c7be6ccb48d427264a770b105256ed",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#347 {
table#348 {
["datatype"] = "time",
["datavalue"] = table#349 {
["type"] = "time",
["value"] = table#350 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-13T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "52c3d0b073fd9c0a1659abf80eb1faf0b57502de",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#351 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#352 {
table#353 {
["hash"] = "8c9cccaab6f08157d988d9a0884edf31a543c6f5",
["snaks"] = table#354 {
["P813"] = table#355 {
table#356 {
["datatype"] = "time",
["datavalue"] = table#357 {
["type"] = "time",
["value"] = table#358 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#359 {
table#360 {
["datatype"] = "url",
["datavalue"] = table#361 {
["type"] = "string",
["value"] = "https://nztop40.co.nz/index.php/chart/singles?chart=4510",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#362 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
}
The below table contains links to PDFs released by ARIA from 15 February 2016. Due to ARIA's website structure, only the most recent week's charts are directly accessible from the main part of the website. These may be useful for sourcing if the Pandora archive does not yet have the data. If the table is out of date, you can update it by copying the URLs of the "Detailed" links from archives of the ARIA website. Note that the PDFs, and thus the below table, use Mondays and not Sundays for the chart dates.
|
| {{User:Jc86035/sandbox3}} | |
|---|---|
{{User:Jc86035/sandbox3|this displays a nowiki tag instead of the templatestyles tag}}
table#1 {
table#2 {
["id"] = "Q55975144$de1affe4-4671-ccd3-e899-3b8a0b17b85e",
["mainsnak"] = table#3 {
["datatype"] = "wikibase-item",
["datavalue"] = table#4 {
["type"] = "wikibase-entityid",
["value"] = table#5 {
["entity-type"] = "item",
["id"] = "Q180072",
["numeric-id"] = 180072,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#6 {
["P1352"] = table#7 {
table#8 {
["datatype"] = "quantity",
["datavalue"] = table#9 {
["type"] = "quantity",
["value"] = table#10 {
["amount"] = "+56",
["unit"] = "1",
},
},
["hash"] = "795afdaa702d841ca0e47e7be33d821114f690d9",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#11 {
table#12 {
["datatype"] = "time",
["datavalue"] = table#13 {
["type"] = "time",
["value"] = table#14 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-07-28T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "4cb3c7d7f041790c979cfe2550fef7e46a361e58",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#15 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#16 {
table#17 {
["hash"] = "f311fc807affdae5c2c1d0258732efac0ec736b0",
["snaks"] = table#18 {
["P813"] = table#19 {
table#20 {
["datatype"] = "time",
["datavalue"] = table#21 {
["type"] = "time",
["value"] = table#22 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#23 {
table#24 {
["datatype"] = "url",
["datavalue"] = table#25 {
["type"] = "string",
["value"] = "https://www.billboard.com/articles/columns/chart-beat/8467371/benny-blanco-scores-first-entry-as-an-artist-hot-100",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#26 {
"P854",
"P813",
},
},
table#27 {
["hash"] = "ac76eef33a172bff044bccdebdda0122e853ece1",
["snaks"] = table#28 {
["P813"] = table#29 {
table#30 {
["datatype"] = "time",
["datavalue"] = table#31 {
["type"] = "time",
["value"] = table#32 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#33 {
table#34 {
["datatype"] = "url",
["datavalue"] = table#35 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/hot-100/2018-07-28",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#36 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#37 {
["id"] = "Q55975144$09b6dc13-4603-8a0c-d782-41185aed53d6",
["mainsnak"] = table#38 {
["datatype"] = "wikibase-item",
["datavalue"] = table#39 {
["type"] = "wikibase-entityid",
["value"] = table#40 {
["entity-type"] = "item",
["id"] = "Q180072",
["numeric-id"] = 180072,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#41 {
["P1352"] = table#42 {
table#43 {
["datatype"] = "quantity",
["datavalue"] = table#44 {
["type"] = "quantity",
["value"] = table#45 {
["amount"] = "+52",
["unit"] = "1",
},
},
["hash"] = "94ddf419299338a4a000a7c130caa4e330b8e071",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#46 {
table#47 {
["datatype"] = "time",
["datavalue"] = table#48 {
["type"] = "time",
["value"] = table#49 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-04T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6bf3727bcaa8925c21c2b32a32b5ce471e641243",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#50 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#51 {
table#52 {
["hash"] = "574dc7fb82b6ae8aef454f9dd85175019573199c",
["snaks"] = table#53 {
["P813"] = table#54 {
table#55 {
["datatype"] = "time",
["datavalue"] = table#56 {
["type"] = "time",
["value"] = table#57 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#58 {
table#59 {
["datatype"] = "url",
["datavalue"] = table#60 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/hot-100/2018-08-04",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#61 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#62 {
["id"] = "Q55975144$5e909fb5-4ec1-3ddd-b3e9-1d8f2e1ed149",
["mainsnak"] = table#63 {
["datatype"] = "wikibase-item",
["datavalue"] = table#64 {
["type"] = "wikibase-entityid",
["value"] = table#65 {
["entity-type"] = "item",
["id"] = "Q472737",
["numeric-id"] = 472737,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#66 {
["P1352"] = table#67 {
table#68 {
["datatype"] = "quantity",
["datavalue"] = table#69 {
["type"] = "quantity",
["value"] = table#70 {
["amount"] = "+31",
["unit"] = "1",
},
},
["hash"] = "6618ac919f7f356a6b55c9572d75a68380741b6b",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#71 {
table#72 {
["datatype"] = "time",
["datavalue"] = table#73 {
["type"] = "time",
["value"] = table#74 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-04T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6bf3727bcaa8925c21c2b32a32b5ce471e641243",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#75 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#76 {
table#77 {
["hash"] = "08343cf1592a8ab58e16e115208d1fa5c4153e32",
["snaks"] = table#78 {
["P813"] = table#79 {
table#80 {
["datatype"] = "time",
["datavalue"] = table#81 {
["type"] = "time",
["value"] = table#82 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#83 {
table#84 {
["datatype"] = "url",
["datavalue"] = table#85 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/canadian-hot-100/2018-08-04",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#86 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#87 {
["id"] = "Q55975144$8e24c179-426a-68e1-ea96-83196e130f18",
["mainsnak"] = table#88 {
["datatype"] = "wikibase-item",
["datavalue"] = table#89 {
["type"] = "wikibase-entityid",
["value"] = table#90 {
["entity-type"] = "item",
["id"] = "Q193259",
["numeric-id"] = 193259,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#91 {
["P1352"] = table#92 {
table#93 {
["datatype"] = "quantity",
["datavalue"] = table#94 {
["type"] = "quantity",
["value"] = table#95 {
["amount"] = "+23",
["unit"] = "1",
},
},
["hash"] = "b9638b3f6764ba46fd03a70fa15e73aae62b4efd",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#96 {
table#97 {
["datatype"] = "time",
["datavalue"] = table#98 {
["type"] = "time",
["value"] = table#99 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-03T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "66f09d32a0f51e52cb9bd4b20fed131e00ffee46",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#100 {
table#101 {
["datatype"] = "time",
["datavalue"] = table#102 {
["type"] = "time",
["value"] = table#103 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-09T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6114c53800049b6da7fc16fad084a5870e7c539b",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#104 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#105 {
table#106 {
["hash"] = "05624006c6c4cb447f73c7841b9f96338d5a9136",
["snaks"] = table#107 {
["P813"] = table#108 {
table#109 {
["datatype"] = "time",
["datavalue"] = table#110 {
["type"] = "time",
["value"] = table#111 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#112 {
table#113 {
["datatype"] = "url",
["datavalue"] = table#114 {
["type"] = "string",
["value"] = "http://www.officialcharts.com/charts/singles-chart/20180803/7501/",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#115 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#116 {
["id"] = "Q55975144$a3a88f0b-430a-1ab6-1636-48b9dce984ad",
["mainsnak"] = table#117 {
["datatype"] = "wikibase-item",
["datavalue"] = table#118 {
["type"] = "wikibase-entityid",
["value"] = table#119 {
["entity-type"] = "item",
["id"] = "Q1056800",
["numeric-id"] = 1056800,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#120 {
["P1352"] = table#121 {
table#122 {
["datatype"] = "quantity",
["datavalue"] = table#123 {
["type"] = "quantity",
["value"] = table#124 {
["amount"] = "+11",
["unit"] = "1",
},
},
["hash"] = "8caafa6ef94abf71b9210d7a524a4278a5ea205a",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#125 {
table#126 {
["datatype"] = "time",
["datavalue"] = table#127 {
["type"] = "time",
["value"] = table#128 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-07-28T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "0097679fbed6bd57e201a2fa60e1e0d52725384b",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#129 {
table#130 {
["datatype"] = "time",
["datavalue"] = table#131 {
["type"] = "time",
["value"] = table#132 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-03T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "66a251d079434df20e8e9f7350f3064b5965fe8b",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#133 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#134 {
table#135 {
["hash"] = "fbfbba71df0a22ad9f718c426abe31817cc724c0",
["snaks"] = table#136 {
["P813"] = table#137 {
table#138 {
["datatype"] = "time",
["datavalue"] = table#139 {
["type"] = "time",
["value"] = table#140 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#141 {
table#142 {
["datatype"] = "url",
["datavalue"] = table#143 {
["type"] = "string",
["value"] = "http://irma.ie/index.cfm?page=irish-charts&chart=Singles",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#144 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#145 {
["id"] = "Q55975144$a4c4ce7b-48c8-6580-f1b9-1558e6723ed5",
["mainsnak"] = table#146 {
["datatype"] = "wikibase-item",
["datavalue"] = table#147 {
["type"] = "wikibase-entityid",
["value"] = table#148 {
["entity-type"] = "item",
["id"] = "Q30916704",
["numeric-id"] = 30916704,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#149 {
["P1352"] = table#150 {
table#151 {
["datatype"] = "quantity",
["datavalue"] = table#152 {
["type"] = "quantity",
["value"] = table#153 {
["amount"] = "+5",
["unit"] = "1",
},
},
["hash"] = "e55ddd08ce050b5a1f3ba07f119cdf406d6266d2",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#154 {
table#155 {
["datatype"] = "time",
["datavalue"] = table#156 {
["type"] = "time",
["value"] = table#157 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-06T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "b0a9cdf37ce46a988d6408750daa285f0debc0dc",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#158 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#159 {
table#160 {
["hash"] = "f1b8b6136d58af1220d558801cfa91a20881c002",
["snaks"] = table#161 {
["P813"] = table#162 {
table#163 {
["datatype"] = "time",
["datavalue"] = table#164 {
["type"] = "time",
["value"] = table#165 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#166 {
table#167 {
["datatype"] = "url",
["datavalue"] = table#168 {
["type"] = "string",
["value"] = "https://www.ariacharts.com.au/charts/singles-chart",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#169 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#170 {
["id"] = "Q55975144$cd482794-4935-fa2e-aa9b-0406896a9196",
["mainsnak"] = table#171 {
["datatype"] = "wikibase-item",
["datavalue"] = table#172 {
["type"] = "wikibase-entityid",
["value"] = table#173 {
["entity-type"] = "item",
["id"] = "Q1407678",
["numeric-id"] = 1407678,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#174 {
["P1352"] = table#175 {
table#176 {
["datatype"] = "quantity",
["datavalue"] = table#177 {
["type"] = "quantity",
["value"] = table#178 {
["amount"] = "+40",
["unit"] = "1",
},
},
["hash"] = "d321b6916ab1365ea57dde8a8e6b984aa60d9fe7",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#179 {
table#180 {
["datatype"] = "time",
["datavalue"] = table#181 {
["type"] = "time",
["value"] = table#182 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-06T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "b0a9cdf37ce46a988d6408750daa285f0debc0dc",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#183 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#184 {
table#185 {
["hash"] = "9306ace33b4c5c9fb333afbf8b780418d297e66c",
["snaks"] = table#186 {
["P813"] = table#187 {
table#188 {
["datatype"] = "time",
["datavalue"] = table#189 {
["type"] = "time",
["value"] = table#190 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-05T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#191 {
table#192 {
["datatype"] = "url",
["datavalue"] = table#193 {
["type"] = "string",
["value"] = "https://nztop40.co.nz/index.php/chart/singles?chart=4508",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#194 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#195 {
["id"] = "Q55975144$749958e7-4405-02cb-8ac4-5627a0e34674",
["mainsnak"] = table#196 {
["datatype"] = "wikibase-item",
["datavalue"] = table#197 {
["type"] = "wikibase-entityid",
["value"] = table#198 {
["entity-type"] = "item",
["id"] = "Q180072",
["numeric-id"] = 180072,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#199 {
["P1352"] = table#200 {
table#201 {
["datatype"] = "quantity",
["datavalue"] = table#202 {
["type"] = "quantity",
["value"] = table#203 {
["amount"] = "+44",
["unit"] = "1",
},
},
["hash"] = "1bc0331715060e899cf0a9077776456c2c37ba3b",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#204 {
table#205 {
["datatype"] = "time",
["datavalue"] = table#206 {
["type"] = "time",
["value"] = table#207 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6b3b67bdd5d4a42af87d120c03c043df07817d12",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#208 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#209 {
table#210 {
["hash"] = "169737185dec3a5efbeed79a86769a6bd688d34a",
["snaks"] = table#211 {
["P813"] = table#212 {
table#213 {
["datatype"] = "time",
["datavalue"] = table#214 {
["type"] = "time",
["value"] = table#215 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#216 {
table#217 {
["datatype"] = "url",
["datavalue"] = table#218 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/hot-100/2018-08-11",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#219 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#220 {
["id"] = "Q55975144$5815cb30-4f3a-3f82-9ac6-0303f6d45316",
["mainsnak"] = table#221 {
["datatype"] = "wikibase-item",
["datavalue"] = table#222 {
["type"] = "wikibase-entityid",
["value"] = table#223 {
["entity-type"] = "item",
["id"] = "Q472737",
["numeric-id"] = 472737,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#224 {
["P1352"] = table#225 {
table#226 {
["datatype"] = "quantity",
["datavalue"] = table#227 {
["type"] = "quantity",
["value"] = table#228 {
["amount"] = "+27",
["unit"] = "1",
},
},
["hash"] = "d4c96c87f0e969e34a17324e067fe292b8465f29",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#229 {
table#230 {
["datatype"] = "time",
["datavalue"] = table#231 {
["type"] = "time",
["value"] = table#232 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "6b3b67bdd5d4a42af87d120c03c043df07817d12",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#233 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#234 {
table#235 {
["hash"] = "fce7d0ab0ed06f79c6738f8335b54da87502b687",
["snaks"] = table#236 {
["P813"] = table#237 {
table#238 {
["datatype"] = "time",
["datavalue"] = table#239 {
["type"] = "time",
["value"] = table#240 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#241 {
table#242 {
["datatype"] = "url",
["datavalue"] = table#243 {
["type"] = "string",
["value"] = "https://www.billboard.com/charts/canadian-hot-100/2018-08-11",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#244 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#245 {
["id"] = "Q55975144$89d3836f-42f0-81ac-94a0-6e299fbb7c17",
["mainsnak"] = table#246 {
["datatype"] = "wikibase-item",
["datavalue"] = table#247 {
["type"] = "wikibase-entityid",
["value"] = table#248 {
["entity-type"] = "item",
["id"] = "Q193259",
["numeric-id"] = 193259,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#249 {
["P1352"] = table#250 {
table#251 {
["datatype"] = "quantity",
["datavalue"] = table#252 {
["type"] = "quantity",
["value"] = table#253 {
["amount"] = "+12",
["unit"] = "1",
},
},
["hash"] = "1677b669a22f2e92d6211557b0093fe5e605feaf",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#254 {
table#255 {
["datatype"] = "time",
["datavalue"] = table#256 {
["type"] = "time",
["value"] = table#257 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-10T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "47e634ce009d3ea4b95a12c8d98cfd19ae03ba7c",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#258 {
table#259 {
["datatype"] = "time",
["datavalue"] = table#260 {
["type"] = "time",
["value"] = table#261 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-16T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "c9d60358efd18e7c1bf540711008757d0bf96056",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#262 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#263 {
table#264 {
["hash"] = "9a99ef51891b4e145ea71786e65fd2754da22eb9",
["snaks"] = table#265 {
["P813"] = table#266 {
table#267 {
["datatype"] = "time",
["datavalue"] = table#268 {
["type"] = "time",
["value"] = table#269 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#270 {
table#271 {
["datatype"] = "url",
["datavalue"] = table#272 {
["type"] = "string",
["value"] = "http://www.officialcharts.com/charts/singles-chart/20180810/7501/",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#273 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#274 {
["id"] = "Q55975144$f239713c-42ad-8ce9-2e58-47a9f7d4f090",
["mainsnak"] = table#275 {
["datatype"] = "wikibase-item",
["datavalue"] = table#276 {
["type"] = "wikibase-entityid",
["value"] = table#277 {
["entity-type"] = "item",
["id"] = "Q1056800",
["numeric-id"] = 1056800,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#278 {
["P1352"] = table#279 {
table#280 {
["datatype"] = "quantity",
["datavalue"] = table#281 {
["type"] = "quantity",
["value"] = table#282 {
["amount"] = "+6",
["unit"] = "1",
},
},
["hash"] = "cbaadcd36f0b877dbbda357045e54cd9b6faf67c",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P580"] = table#283 {
table#284 {
["datatype"] = "time",
["datavalue"] = table#285 {
["type"] = "time",
["value"] = table#286 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-04T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "df16ff450852dc2b0dbc46e7c8bd8193c43769a1",
["property"] = "P580",
["snaktype"] = "value",
},
},
["P582"] = table#287 {
table#288 {
["datatype"] = "time",
["datavalue"] = table#289 {
["type"] = "time",
["value"] = table#290 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-10T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "458127f419a30a6dfc6c521d1f65dee65f1c797b",
["property"] = "P582",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#291 {
"P580",
"P582",
"P1352",
},
["rank"] = "normal",
["references"] = table#292 {
table#293 {
["hash"] = "5c1c37b18083a99bbe7c063cc8b8e4f13e10cd3f",
["snaks"] = table#294 {
["P813"] = table#295 {
table#296 {
["datatype"] = "time",
["datavalue"] = table#297 {
["type"] = "time",
["value"] = table#298 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#299 {
table#300 {
["datatype"] = "url",
["datavalue"] = table#301 {
["type"] = "string",
["value"] = "http://irma.ie/index.cfm?page=irish-charts&chart=Singles",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#302 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#303 {
["id"] = "Q55975144$9f5be1b1-4431-1348-4685-1aee40f16136",
["mainsnak"] = table#304 {
["datatype"] = "wikibase-item",
["datavalue"] = table#305 {
["type"] = "wikibase-entityid",
["value"] = table#306 {
["entity-type"] = "item",
["id"] = "Q30916704",
["numeric-id"] = 30916704,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#307 {
["P1352"] = table#308 {
table#309 {
["datatype"] = "quantity",
["datavalue"] = table#310 {
["type"] = "quantity",
["value"] = table#311 {
["amount"] = "+5",
["unit"] = "1",
},
},
["hash"] = "e55ddd08ce050b5a1f3ba07f119cdf406d6266d2",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#312 {
table#313 {
["datatype"] = "time",
["datavalue"] = table#314 {
["type"] = "time",
["value"] = table#315 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-13T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "52c3d0b073fd9c0a1659abf80eb1faf0b57502de",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#316 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#317 {
table#318 {
["hash"] = "5ed0543affc0348ab72af4c33bb16ec1111af9fa",
["snaks"] = table#319 {
["P813"] = table#320 {
table#321 {
["datatype"] = "time",
["datavalue"] = table#322 {
["type"] = "time",
["value"] = table#323 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#324 {
table#325 {
["datatype"] = "url",
["datavalue"] = table#326 {
["type"] = "string",
["value"] = "https://www.ariacharts.com.au/charts/singles-chart",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#327 {
"P854",
"P813",
},
},
table#328 {
["hash"] = "f17d25e688bd5726a4932ddbf7cacabb506d6609",
["snaks"] = table#329 {
["P813"] = table#330 {
table#331 {
["datatype"] = "time",
["datavalue"] = table#332 {
["type"] = "time",
["value"] = table#333 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#334 {
table#335 {
["datatype"] = "url",
["datavalue"] = table#336 {
["type"] = "string",
["value"] = "http://cdn.aria.com.au/pdfs/C59F0A334271181ED9323B30BE6A23D715104417DCEF1B637E14A57985F202B8/ARIA%20Singles%20Chart.pdf?seq=13",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#337 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
table#338 {
["id"] = "Q55975144$70d2045b-4f0a-e53b-44be-95f13fadc230",
["mainsnak"] = table#339 {
["datatype"] = "wikibase-item",
["datavalue"] = table#340 {
["type"] = "wikibase-entityid",
["value"] = table#341 {
["entity-type"] = "item",
["id"] = "Q1407678",
["numeric-id"] = 1407678,
},
},
["property"] = "P2291",
["snaktype"] = "value",
},
["qualifiers"] = table#342 {
["P1352"] = table#343 {
table#344 {
["datatype"] = "quantity",
["datavalue"] = table#345 {
["type"] = "quantity",
["value"] = table#346 {
["amount"] = "+3",
["unit"] = "1",
},
},
["hash"] = "ba2a02dbc6c7be6ccb48d427264a770b105256ed",
["property"] = "P1352",
["snaktype"] = "value",
},
},
["P585"] = table#347 {
table#348 {
["datatype"] = "time",
["datavalue"] = table#349 {
["type"] = "time",
["value"] = table#350 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-13T00:00:00Z",
["timezone"] = 0,
},
},
["hash"] = "52c3d0b073fd9c0a1659abf80eb1faf0b57502de",
["property"] = "P585",
["snaktype"] = "value",
},
},
},
["qualifiers-order"] = table#351 {
"P585",
"P1352",
},
["rank"] = "normal",
["references"] = table#352 {
table#353 {
["hash"] = "8c9cccaab6f08157d988d9a0884edf31a543c6f5",
["snaks"] = table#354 {
["P813"] = table#355 {
table#356 {
["datatype"] = "time",
["datavalue"] = table#357 {
["type"] = "time",
["value"] = table#358 {
["after"] = 0,
["before"] = 0,
["calendarmodel"] = "http://www.wikidata.org/entity/Q1985727",
["precision"] = 11,
["time"] = "+2018-08-11T00:00:00Z",
["timezone"] = 0,
},
},
["property"] = "P813",
["snaktype"] = "value",
},
},
["P854"] = table#359 {
table#360 {
["datatype"] = "url",
["datavalue"] = table#361 {
["type"] = "string",
["value"] = "https://nztop40.co.nz/index.php/chart/singles?chart=4510",
},
["property"] = "P854",
["snaktype"] = "value",
},
},
},
["snaks-order"] = table#362 {
"P854",
"P813",
},
},
},
["type"] = "statement",
},
}
The below table contains links to PDFs released by ARIA from 15 February 2016. Due to ARIA's website structure, only the most recent week's charts are directly accessible from the main part of the website. These may be useful for sourcing if the Pandora archive does not yet have the data. If the table is out of date, you can update it by copying the URLs of the "Detailed" links from archives of the ARIA website. Note that the PDFs, and thus the below table, use Mondays and not Sundays for the chart dates.
|
}}
Notifying Mr. Stradivarius, who wrote the function. Jc86035 (talk) 10:16, 27 July 2018 (UTC)
Never mind; this was because the strip marker format was changed in 2015. I've updated the module. Jc86035 (talk) 10:26, 27 July 2018 (UTC)
Request Lua module for removing/striping leading zeros[edit]
Hello there! I am not familiar with Lua, but I would like to invoke a module for Template:SEHK to remove all leading zeros. This is needed as the template uses the numerical stock code inputted and replaces the value inside the stock exchange URL. The problem is that SEHK tickers are often reported in the English media with leading zeros (making it up to 4 digits, such as "0001" rather than just "1") The current stock website does not support leading zeros, hence redirecting to an error site. I was wondering if anyone here experienced with Lua can help with this issue? It has been affecting a wide range of Hong Kong stock exchange-listed articles. Cheers –Wefk423 (talk) 18:49, 26 July 2018 (UTC)
- It's easy enough to write a module to use the Lua function
tonumber(), but it's probably simpler to use the magic word{{#expr: }}. For example,{{#expr:0001}}gives 1. HTH --RexxS (talk) 19:09, 26 July 2018 (UTC)- Expr seems really reasonable considering the other alternative of Module:String#Replace (finding regex 00+ and replacing with nothing). Template:Trim exists. Expr emits an NAN if the input is bad, no? --Izno (talk) 19:26, 26 July 2018 (UTC)
- Thanks for the suggestion. I have added the magic word
{{#expr: }}to the template to resolve the error webpage issue for now. But I do think that such module (with usage tutorial) can be created as other templates might also need to strip leading zeros. It seems like a fast and easy way, especially for users who don't know how to use magic words. –Wefk423 (talk) 19:35, 26 July 2018 (UTC)- (edit conflict) It throws an error for me:
{{#expr:ABCD}}→ Expression error: Unrecognized word "abcd". - If you want to control the errors, then a Lua module starts to become attractive:
p = {} p.stripzeros = function(frame) x = tonumber(frame.args[1]) if x then return x else return "whatever you want to indicate NaN" end end return p
- Usage:
{{#invoke:Modulename |stripzeros |number-goes-here}}HTH. --RexxS (talk) 19:40, 26 July 2018 (UTC)- Thank you so much for the great suggestion on customizing the error message by using this Lua module. It is currently live at Module:Leading zeros and has also been implemented in Template:SEHK. Way much better than the red bold message which will look terrible in a infobox. When inputting a non-numeric value, it will now appear as "SEHK: Incorrect". How do you think? Cheers! –Wefk423 (talk) 00:21, 27 July 2018 (UTC)
- @Wefk423: That seems to do the job for you. If you re-use the module in other applications, you can trap the error word "Incorrect" with an {{#ifeq: }} test in the template, which will allow you to take different actions when the input is not a number.
- One other thing (in your documentation): I would encourage everyone not to use
<br>to separate items in a list (see MOS:NOBR. Using {{ubl}}, especially in an infobox, is much better because it creates a real list that is much more useful for screen readers. Cheers --RexxS (talk) 09:33, 27 July 2018 (UTC)
- Thank you so much for the great suggestion on customizing the error message by using this Lua module. It is currently live at Module:Leading zeros and has also been implemented in Template:SEHK. Way much better than the red bold message which will look terrible in a infobox. When inputting a non-numeric value, it will now appear as "SEHK: Incorrect". How do you think? Cheers! –Wefk423 (talk) 00:21, 27 July 2018 (UTC)
- (edit conflict) It throws an error for me:
- Another way to strip leading 0's in a string:
{{#invoke:String|match|000123450|^0+(.*)}}-- Matroc (talk) 08:31, 12 September 2018 (UTC)
- and of course, the original suggestion by RexxS, using #expr is still valid, and prolly the simplest... handling errors is no biggy - just enclose in #iferror, like so (presuming the thing you want to strip is in param 1):
{{#iferror:{{#expr:{{{1}}} }}| <your "non-numeric" error message here> | {{#expr:{{{1}}} }} }}- peace - קיפודנחש (aka kipod) (talk) 15:26, 12 September 2018 (UTC)
- and of course, the original suggestion by RexxS, using #expr is still valid, and prolly the simplest... handling errors is no biggy - just enclose in #iferror, like so (presuming the thing you want to strip is in param 1):
Module:Leading zeros has been nominated for deletion. {{3x|p}}ery (talk) 14:09, 8 October 2018 (UTC)
Improving Template:Code[edit]
I'm wondering if it's feasible to re-do {{code}}, a wrapper for <syntaxhighlight>, in such a way that some parameter, perhaps |filter=y, could pre-filter and convert some of the input before it reaches the underlying <syntaxhighlight> process. [Inserting a code snippet for example purposes below: <span>.]
- The issue: Sometimes it is not desirable to feed this template something literal. E.g., if you do
{{code|lang=html|1=<span style="color: purple;">}}(without the closing tag for the span), then anyone using the edit-mode wikimarkup syntax highlighter by Remember_the_dot, available at Special:Preferences#mw-prefsection-gadgets and thus our most frequently used highlighter, will have their syntax highlighting in the editing window boogered by what Remember_the_dot's syntax highlighter sees as a real open and not-yet-closed<span>rather than as template content. [If you use that highlighter, and are reading this in edit mode, you should see this effect now, caused by the snippet I inserted before this bullet list. Most of my entire post should have a pink background as unclosed code content when it really is not.]- And one cannot escape this with
<to encode the exmaple span's leading < symbol; all input received by<syntaxhighlight>is treated as a literal. - This also makes it impossible to do something like
{{code|lang=html|1=<span '''style'''="color: purple;">}}to emphasize something in the markup.
- And one cannot escape this with
- The idea: Use Lua and a table of entities and of select wikimarkup to pre-filter (and possibly post-filter) the content before (and maybe after) it hits
<syntaxhighlight>:- Pre-filter so that things like < can be escaped in the visible wikitext with
<, converted to <, then passed to the parser function. - Possibly also tokenize a few things like
''...''and'''...'''markup so they can be operated on after the fact: - Post-filter to de-tokenize those bits and actually perform their intent. Ideally this would also include
<var>...</var>so that variables within code can be marked up as such (lack of ability to do that is a serious flaw in<syntaxhighlight>).
- Pre-filter so that things like < can be escaped in the visible wikitext with
— SMcCandlish ☏ ¢ 😼 22:12, 1 August 2018 (UTC)
- @SMcCandlish: Unfortunately, post-filtering is impossible as the output from
<syntaxhighlight>is not exposed to lua other than as an opaque strip marker. Pre-filtering could be done trivially using Module:String and/or Module:MultiReplace without creating a new lua module. {{3x|p}}ery (talk) 11:31, 18 September 2018 (UTC)- Correction: Post-filtering is not technically impossible, only impossible to do without relying heavily on undocumented implementation details of the SyntaxHighlight extension, which seems like it's not a good idea to do for such a heavily used template. {{3x|p}}ery (talk) 22:22, 18 September 2018 (UTC)
- I should have known better than to call something impossible. {{3x|p}}ery (talk) 22:25, 18 September 2018 (UTC)
- @Pppery: Well, what I suggested was that "some parameter, perhaps
|filter=y, could pre-filter", so it sounds like you're telling me that the problem I'm reporting is in fact easily fixable. — SMcCandlish ☏ ¢ 😼 11:10, 8 November 2018 (UTC)
- @Pppery: Well, what I suggested was that "some parameter, perhaps
need help to localize parameter[edit]
Hello, i need to localize Module:Webarchive for bnwiki. I tried this, It works but not always. I listed some problems here. Please take a look, feel free to edit here (no need to explain anything to me). --আফতাবুজ্জামান (talk) 18:16, 26 August 2018 (UTC)
- I'm guessing that your problem for
|শিরোনাম২=and|ইউআরএল২=might be becauseparseExtraArgs()doesn't know about the bn equivalent names. - One of the things that I did for bn:Module:Citation/CS1 was to create a table that replaced bn digits with western digits in enumerated parameter names because Lua only understands western digits (the table for that is at bn:Module:Citation/CS1/Configuration and is named
local_digits). You might need to do something similar if you will be supporting bn digits in your parameter names. - —Trappist the monk (talk) 18:53, 26 August 2018 (UTC)
- @Trappist the monk: Thank you for answer. Problem is i don't where to put it, which line. Even though i did this edit but i even don't know it was right or wrong. Could please do it there? --আফতাবুজ্জামান (talk) 20:10, 26 August 2018 (UTC)
date localization[edit]
Above problem is solved. But this module still have date related problem, you can see here (first two section). Can someone help. --আফতাবুজ্জামান (talk) 16:12, 27 August 2018 (UTC)
- To make it work for dates, it would need to translate from Bengali to English early in the program, then back to Bengali late in the program .. this way the program remains mostly unmodified. It looks like there is মডিউল:ConvertDigit from English to Bengali - need a way to convert Bengali date to English. -- GreenC 20:50, 27 August 2018 (UTC)
Wikidata queries[edit]
Is it possible to do complex queries like this in Lua to Wikidata? -- GreenC 20:21, 27 August 2018 (UTC)
- No, SPARQL queries are not supported directly on wiki. Queries have a future, but it was put off after the structured Commons work came in (and associated multi-content revisions). Outside of the mainspace, you can set up ListeriaBot for complex queries. --Izno (talk) 22:35, 27 August 2018 (UTC)
- Oh well, as I thought. It's for a template used in infoboxes, which might be a bad idea anyway due to performance. Glad to hear it might/could happen though. -- GreenC 23:31, 27 August 2018 (UTC)
- You can usually get infoboxes to work by traversing the edges between nodes if you're starting from a particular item, with the use of one or another of the Wikidata modules. --Izno (talk) 01:17, 28 August 2018 (UTC)
- I don't know what traversing the edges between nodes means. Could the above query can be replicated with reasonable performance and without a major amount of Lua code? -- GreenC 01:58, 28 August 2018 (UTC)
- No, it's not really feasible to search entries using the functionality exposed at present to Lua via the Wikibase client. There are 15,000,000 entities and 50,000,000 pieces of data, so without access to any form of indexing to query the database, any attempt to look through every item to find everything that matches particular criteria is going to be slow and resource-hungry. What Izno is suggesting is to start with an known item (usually the item connected to the page where the infobox is) and use links from there to read other items, then repeat until you arrive at the result you want. As an example look at the location function in Module:WikidataIB.
- Starting from Royal Air Force Museum Cosford (Q7373617) and iteratively following located in the administrative territorial entity (P131):
{{#invoke: WikidataIB |location |qid=Q7373617}}→ RAF Cosford, Cosford, Shropshire, West Midlands, England, UK
- Lua's good for that sort of data manipulation, but you'll still need query-language based software, or similar, to efficiently do searches on the Wikidata database. --RexxS (talk) 15:26, 28 August 2018 (UTC)
- No, it's not really feasible to search entries using the functionality exposed at present to Lua via the Wikibase client. There are 15,000,000 entities and 50,000,000 pieces of data, so without access to any form of indexing to query the database, any attempt to look through every item to find everything that matches particular criteria is going to be slow and resource-hungry. What Izno is suggesting is to start with an known item (usually the item connected to the page where the infobox is) and use links from there to read other items, then repeat until you arrive at the result you want. As an example look at the location function in Module:WikidataIB.
- I don't know what traversing the edges between nodes means. Could the above query can be replicated with reasonable performance and without a major amount of Lua code? -- GreenC 01:58, 28 August 2018 (UTC)
- You can usually get infoboxes to work by traversing the edges between nodes if you're starting from a particular item, with the use of one or another of the Wikidata modules. --Izno (talk) 01:17, 28 August 2018 (UTC)
- Oh well, as I thought. It's for a template used in infoboxes, which might be a bad idea anyway due to performance. Glad to hear it might/could happen though. -- GreenC 23:31, 27 August 2018 (UTC)
Template:Demo demo_kill_categories alias nocat[edit]
I've did this change, but it doesn't seem to work. Can somebody with more Lua knowledge take a look?
See example here: User:Andrybak/sandbox/demonocat -- note, that page is added to Category:Wikipedians in Russia, but shouldn't be. demo_kill_categories still works: User:Andrybak/sandbox/demonocat2. —andrybak (talk) 11:27, 29 August 2018 (UTC)
- you modified the function
module(), but in this case it is not called, but ratherget(), which you did not touch. קיפודנחש (aka kipod) (talk) 21:45, 31 August 2018 (UTC)- Thanks, קיפודנחש (aka kipod)! I've added it also to function
get()—andrybak (talk) 17:14, 1 September 2018 (UTC)
- Thanks, קיפודנחש (aka kipod)! I've added it also to function
Calculating moveable dates[edit]
The moveable date problem on Wikipedia is extensive. Infoboxes that display dates for a holiday with moveable dates largely need to be updated manually and there are thousands (many don't even bother trying). Currently there are two calculators Module:Easter and {{Hebrew year}} both of which I'm integrating into {{Moveable date}} (see Module:Calendar date/Events). These are good, but there are surprisingly no other calculators available on Wikipedia.
To get a sense how big this problem is, a list of holidays in the United States from a JavaScript program that determine moveable dates. For other countries. Dates can be complex like:
- Tax Day: On April 15. If a Friday then postpone to next Monday. If Saturday or Sunday then next Tuesday.
- Administrative Professionals Day: The Wednesday before April 28.
Notably, many of these dates are not calculated by the sun or moon, but by human decree which means they can change arbitrarily and thus need to be easily configured. But even dates that go by celestial guidance have trouble, for example {{Hebrew year}} can not accurately calculate dates for 3 of the Hebrew months as they are not fixed to the Gregorian calendar.
So this is a big messy problem with endless edge cases. My sense is we should try to translate a package like date-holidays or Nager.Date into Lua but I have no skills for those source languages. Then there is the argument by Mark Seeman to just store the dates and not do calculations. I'm doing this for certain holidays that can't be calculated eg. Module:Calendar_date/localfiles/Leil_Selichot
If we had a Lua program that could solve for some things, like "2nd sunday in May" or "3rd monday in January" it might go a long way to calculating holidays, and provide a system for building more complex queries like Tax Day. Any thoughts? -- GreenC 14:20, 3 September 2018 (UTC)
- Module:Time has a function
decode_dst_event()used to determine daylight saving time begin/end dates. The function takes"2nd sunday in May" or "3rd monday in January"
and returns (for these examples) the ordinal (2 or 3), the day-in-the-week number (0 or 1) and the month number (5 or 1) ornilif the string can't be decoded or is malformed. - —Trappist the monk (talk) 14:30, 3 September 2018 (UTC)
- @GreenC: I guess you could use Wikidata items like date of Easter (Q51224536). Jc86035 (talk) 15:30, 3 September 2018 (UTC)
- See two threads above - Wikidata would only have separate items pages for moveable holidays that are hard to calculate on Wikidata. For things like "2nd sunday in May" Wikidata can calculate it through a query, so it wouldn't have an item page. And without an item page Lua can't effectively retrieve a query (I think?). Also if a calculator is available locally that is probably going to be preferable to Wikidata. Such as Module:Easter. -- GreenC 16:02, 3 September 2018 (UTC)
- @GreenC: Is this the sort of functionality you want?
{{#invoke:Sandbox/RexxS/CalcDate |getYearMonthDay |date=second Friday in June |year=2018}}→ 2018-06-08{{#invoke:Sandbox/RexxS/CalcDate |getYearMonthDay |last Friday in June |2018}}→ 2018-06-29{{#invoke:Sandbox/RexxS/CalcDate |getYearMonthDay |date=last Monday in February |year=2016}}→ 2016-02-29
- It needs some error handling and can be spruced up to return other formats, but it seems to do the job as I understand it. It's adapted from Module:Time per Trappist the monk's pointer. --RexxS (talk) 18:05, 3 September 2018 (UTC)
- @RexxS: that is awesome. It will solve a bunch of them. The next question how to take it to the next level and solve for Native American Heritage Day: friday after 4th thursday in November. There are quite a few taking this form. Would this be an addition to the module, or could it be calculated by invoking multiple modules, such as with Module:Date suggested by Johnuniq (in this case adding +1 day to the output of getYearMonthDay). Or maybe RexxS/CalcDate could accept an offset option (-/+) to move the target day around relative eg. calculate for 4th thursday in November and add 1 day. -- GreenC 13:37, 4 September 2018 (UTC)
- Sheesh I apologize for being so uninformed, apparently holiday infobox can already do some data calculations internally, see Patriots' Day. And for Thanksgiving, there is
{{weekday in month}}that basically does the same thing. -- GreenC 15:01, 4 September 2018 (UTC) - Probably should focus next on calculators for non-Gregorian -> Gregorian, and otherwise difficult calculators like Easter. Various calendar systems are not currently available. Hindi being the most prevalent but also Japanese and Persian. -- GreenC 15:18, 4 September 2018 (UTC)
- Sheesh I apologize for being so uninformed, apparently holiday infobox can already do some data calculations internally, see Patriots' Day. And for Thanksgiving, there is
- @RexxS: that is awesome. It will solve a bunch of them. The next question how to take it to the next level and solve for Native American Heritage Day: friday after 4th thursday in November. There are quite a few taking this form. Would this be an addition to the module, or could it be calculated by invoking multiple modules, such as with Module:Date suggested by Johnuniq (in this case adding +1 day to the output of getYearMonthDay). Or maybe RexxS/CalcDate could accept an offset option (-/+) to move the target day around relative eg. calculate for 4th thursday in November and add 1 day. -- GreenC 13:37, 4 September 2018 (UTC)
- @GreenC: Is this the sort of functionality you want?
- See two threads above - Wikidata would only have separate items pages for moveable holidays that are hard to calculate on Wikidata. For things like "2nd sunday in May" Wikidata can calculate it through a query, so it wouldn't have an item page. And without an item page Lua can't effectively retrieve a query (I think?). Also if a calculator is available locally that is probably going to be preferable to Wikidata. Such as Module:Easter. -- GreenC 16:02, 3 September 2018 (UTC)
The request has been well satisfied but bear in mind that Module:Date can be used by other modules and includes stuff like this. Search Module:Date/example and its talk page for "Friday" to see examples. I never got around to finishing the documentation but Module:Age has more examples of what Module:Date can do. Time zones are not supported. If something is wanted from Module:Date, ask here or at its talk. Johnuniq (talk) 23:18, 3 September 2018 (UTC)
Most of it can be done in wikicode... Public holidays in the United Kingdom#England, Northern Ireland and Wales. Cabayi (talk) 16:11, 4 September 2018 (UTC)
[edit]
Hi everybody! Google Code-in (GCI) will soon take place again - a seven week long contest for 13-17 year old students to contribute to free software projects. Tasks should take an experienced contributed about two or three hours and can be of the categories Code, Documentation/Training, Outreach/Research, Quality Assurance, and User Interface/Design. Do you have any Lua / template related idea for a task (needs documentation, or some code / code changes) and can imagine enjoying mentoring such a task to help a new contributor? If yes, please check out mw:Google Code-in/2018 and become a mentor! Thanks in advance! --AKlapper (WMF) (talk) 13:49, 9 September 2018 (UTC)
Can Lua be used to parse a section of one page, change the contents and be transcluded on another page?[edit]
Hi there. I'm not familiar with Lua at all, so please forgive me if this sounds obvious. I recently noticed that {{WPVG announcements}} is manually updated by a number of dedicated editors to reflect changes from WP:GAN#VG, which basically means translating the values from the {{GANentry}} templates at WP:GAN#VG to the {{ganl}} templates used in {{WPVG announcements}}. Would it be possible for a Lua script to parse the content of the former section, reassign the values to a different template and display those for inclusion in the announcements-template? That way, editors wouldn't have to manually update the template anymore and it'd be always up-to-date. Regards SoWhy 07:44, 10 September 2018 (UTC)
- Although Lua can read the content of a page using the getContent() method from the title library and can write text to a page, Lua scripts are run when a page is rendered, so somebody would have to trigger the script by previewing an edit or something similar to do the update. The kind of job you're envisaging is most commonly done by a bot, often running a Python script. I recommend putting in a request at Wikipedia:Bot requests where you can get feedback and suggestions on how best to get the results you want. --RexxS (talk) 18:21, 10 September 2018 (UTC)
- You could probably also do something like this by managing a JSON file or a Lua table, but that's not very wiki-textish. --Izno (talk) 19:04, 10 September 2018 (UTC)
- wiki syntax now allows segment transclusing, (explained in Help:Labeled section transclusion and probably in other places also). you could use this to create labeled section in the "source" page, and pass the transclusions are parameters to a template that would then do the conversions. this would make the source page a bit more cumbersome to edit, introducing all the "section begin/section end" tags, but i think it can do what you want. the "conversion template" can use scribunto, or not - it may not be necessary if the conversion code is simple enough. i believe that doing so will solve the issue RexxS mentioned: changes to the "source" page should be reflected automagically in the target page. peace - קיפודנחש (aka kipod) (talk) 21:29, 10 September 2018 (UTC)
- @קיפודנחש: Unfortunately, since WP:GAN is managed by a bot, making changes to it is not possible because it will likely break the bot. Since the bot already updates that page, I thought these updates could be translated to {{WPVG announcements}} as described. The latter template is used on tens of thousands of talk pages (any talk that uses {{WPVG}} in fact), so I assumed the template will be updated often anyway. I'll ask whether a bot could do it instead. Thanks for the replies! Regards SoWhy 09:00, 11 September 2018 (UTC)
- wiki syntax now allows segment transclusing, (explained in Help:Labeled section transclusion and probably in other places also). you could use this to create labeled section in the "source" page, and pass the transclusions are parameters to a template that would then do the conversions. this would make the source page a bit more cumbersome to edit, introducing all the "section begin/section end" tags, but i think it can do what you want. the "conversion template" can use scribunto, or not - it may not be necessary if the conversion code is simple enough. i believe that doing so will solve the issue RexxS mentioned: changes to the "source" page should be reflected automagically in the target page. peace - קיפודנחש (aka kipod) (talk) 21:29, 10 September 2018 (UTC)
- You could probably also do something like this by managing a JSON file or a Lua table, but that's not very wiki-textish. --Izno (talk) 19:04, 10 September 2018 (UTC)
@SoWhy: Incorrect. What is requested here is possible, and in fact relatively easy to implement: I implemented it in Template:WPVG announcements/sandbox. In exactly the same way as pages update when the pages they transclude update, the list will automatically update whenever new good articles are nominated. {{3x|p}}ery (talk) 23:02, 17 September 2018 (UTC)
- @Pppery: Wow, nice work. Thanks! I'll ask if someone has objections to implementing this at WT:VG. Regards SoWhy 06:58, 18 September 2018 (UTC)
WikiProject College football needs assistance with Lua-based template[edit]
WikiProject College football needs assistance with Lua-based templates: Template:CFB schedule and Template:CFB schedule entry based on Module:CFB schedule. We're going to need to make some changes to these templates and also need to make some tweaks to a conversation process for replacing older templates with these newer ones. These templates and the module were developed by User:Frietjes, but she doesn't appear to be able to assist with this any longer. Is there anyone else here well-versed with Lua who can get involved? Thanks, Jweiss11 (talk) 06:39, 12 September 2018 (UTC)
- the most recent thread is here and the subsequent changes made in response the thread are here and here. Frietjes (talk) 12:19, 12 September 2018 (UTC)
- Frietjes, thanks for those recent edits to the module. I follow the first one regarding the conversion process. That looks good. I'm not sure I follow the second edit, which appears to have something to go with the gamename field for the unnamed parameter scheme? Also, we have another problem, with the named parameter scheme. Take the table at 1950 Texas A&M Aggies football team as an example. If you clear out the two entries in the rank column, the poll info in the footer disappears. But there are still opponent rankings in the opponent column to owhich the poll footer applies. The poll footer needs to be present in any cases where there are either any rankings or any opponent rankings. We can also remove the "#" from the heading of the rank column and the footer. Jweiss11 (talk) 00:52, 13 September 2018 (UTC)
Lua error[edit]
Hello everyone, Who can tell me how can i fix this error at ckbwiki? Tap the red text, you will see something. Thank you.ئارام بکر (talk) 21:07, 19 September 2018 (UTC)
- One of
lang:formatDate( 'U', nil, true )orinputTimein:local timeDiff = lang:formatDate( 'U', nil, true ) - inputTime
- is a string and needs to be a number. You might try, as a first fix:
local timeDiff = tonumber(lang:formatDate( 'U', nil, true )) - tonumber(inputTime)
- But, were I you, I would translate your local wiki language date/time inputs to their English equivalents before doing any operation on those date/time values and then at the end translate the English result back to your local language. My experience is that Lua and
formatDate()don't handle non-English language date names and non-western digits well. Internationalization isn't as easy as one might wish it were. - —Trappist the monk (talk) 21:49, 19 September 2018 (UTC)
Help with calling String.replace[edit]
Hello, I'm new to Lua and trying to create a module (Module:Sandbox/Gonnym/Episode disambiguation description) that takes an article title and returns a formatted style depending on how the article title is written. However, I'm not able to get one String function to work - String.replace - it's not even getting colored green like the other functions I'm using. What I'm trying to do with it, is what Template:PAGENAMEBASE does. I would really appreciate any help (and any other comments) on this. Thank you. --Gonnym (talk) 13:18, 20 September 2018 (UTC)
- review the documentation on string.match()
- —Trappist the monk (talk) 14:16, 20 September 2018 (UTC)
Timeout on specific settings[edit]
I'm in the process of creating a module that can take either 3 or 4 params and produces a short description with those params. When I give it the first 3 params (episode, season and tv series) it works. I've checked it with around 20 calls running on the same page and they all worked fine. When I give it all 4 params (which includes the 4th "yes" param) it times out. I tried debugging it and sent the 3 params again, but made the system act as if the 4th one was sent (just set it manually to true) and it worked for the first 2 calls and timed-out for the others. So code-wise there isn't an error crashing it and the code isn't really long or complex, so I pretty much ran out of ideas what is causing this. Would appreciate if anyone could have a look at it - Module:Sandbox/Gonnym/Episode short discription (ignore the typo in title). --Gonnym (talk) 13:59, 22 September 2018 (UTC)
- line 37; function calls itself.
- —Trappist the monk (talk) 14:42, 22 September 2018 (UTC)
- Thanks Trappist! --Gonnym (talk) 16:50, 22 September 2018 (UTC)
- Ok, I fixed it and it worked for a while but I'm getting this timeout again. If I enter the 3 value option of "23|1|somename" I it works, but if I add the 4th param it fails. So {{User:Gonnym/sandbox/Test|23|1|Lost}} works, while {{User:Gonnym/sandbox/Test|23|1|Lost|y}} doesn't. --Gonnym (talk) 17:34, 22 September 2018 (UTC)
- the solution is at lines 33 & 35.
- —Trappist the monk (talk) 18:01, 22 September 2018 (UTC)
- Thanks again! No idea why that would cause a timeout though. Redundant? probably, but it didn't seem breaking. --Gonnym (talk) 18:12, 22 September 2018 (UTC)
- when first episode is 23 and second episode is 24 the number of interest is 4. you were testing
number < 4andnumber > 4but not testingnumber == 4. theif-then-elsetests, not knowing what to do with 4, just kept thewhilelooping round and round and round ... - —Trappist the monk (talk) 18:49, 22 September 2018 (UTC)
- when first episode is 23 and second episode is 24 the number of interest is 4. you were testing
- Thanks again! No idea why that would cause a timeout though. Redundant? probably, but it didn't seem breaking. --Gonnym (talk) 18:12, 22 September 2018 (UTC)
- Ok, I fixed it and it worked for a while but I'm getting this timeout again. If I enter the 3 value option of "23|1|somename" I it works, but if I add the 4th param it fails. So {{User:Gonnym/sandbox/Test|23|1|Lost}} works, while {{User:Gonnym/sandbox/Test|23|1|Lost|y}} doesn't. --Gonnym (talk) 17:34, 22 September 2018 (UTC)
- Thanks Trappist! --Gonnym (talk) 16:50, 22 September 2018 (UTC)
Accessing a page's short description (inside infobox) from another page[edit]
Hello again.
I was trying to access the short description information from an article that uses an auto-generated short description created inside the infobox template used on that page, and use that on a different page. So, "Page A" uses "Template:Infobox x" that has code that generates a short description with Template:Short description. In "Page B", I want to access that data. I tried using Template:Extract short description to access that data, which does indeed work, however, that has a side-effect that since it transcludes the page, it also adds things that should not be there, such as FA/GA ratings and warnings such as Warning: Display title <article name> was ignored since it is not equivalent to the page's actual title
. There might be other issues that also come from this. Since this method does not work, I was wondering if anyone can think of another way to access it. --Gonnym (talk) 21:29, 26 September 2018 (UTC)
- If you know the name of the article you might use a variant of this:
=string.match (mw.title.new ('Abraham Lincoln'):getContent(), '{{ *short +description *| *([^}]+) *}}')
- For the article Abraham Lincoln, the above, executed from the debug console returns:
- 16th President of the United States
- But, caveat here, too many uses of this kind of trick in a single article will cause Lua timeouts.
- —Trappist the monk (talk) 21:51, 26 September 2018 (UTC)
- That would still be regarded as a transclusion. Using getContent for a couple of small uses might be ok but it's not viable for routine use. Using it on Abraham Lincoln worked easily because that article has {{short description}} in the wikitext. Using it at Athens which auto-generates the description would be a lot more challenging. Johnuniq (talk) 01:34, 27 September 2018 (UTC)
- I'm thinking maybe there is way to make it work with a workaround with Template:Template parameter value, by adding a silent field to an infobox template and calling it, but so far I couldn't get it to work. Not sure how to pass the short description data to that field. --Gonnym (talk) 06:42, 27 September 2018 (UTC)
- That would still be regarded as a transclusion. Using getContent for a couple of small uses might be ok but it's not viable for routine use. Using it on Abraham Lincoln worked easily because that article has {{short description}} in the wikitext. Using it at Athens which auto-generates the description would be a lot more challenging. Johnuniq (talk) 01:34, 27 September 2018 (UTC)
At Athens the infobox generates "City in Central Greece, Greece" as the short description. Previewing the following extract from the infobox is enough to reproduce that.
{{Infobox settlement
| settlement_type = [[Cities of Greece|City]]
| subdivision_type = Country
| subdivision_name = [[Greece]]
| subdivision_type1 = [[Geographic regions of Greece|Geographic region]]
| subdivision_name1 = [[Central Greece]]
| subdivision_type2 = [[Administrative regions of Greece|Administrative region]]
| subdivision_name2 = [[Attica (region)|Attica]]
| subdivision_type3 = [[Regional units of Greece|Regional unit]]
| subdivision_name3 = [[Central Athens (regional unit)|Central Athens]]
}}
There is no parameter with the description so {{Template parameter value}} cannot help. You would need to reproduce the calculations performed by {{Infobox settlement}}—calculations that might be changed at any time and which would not apply for other infoboxes. Alternatively, you would need to expand the infobox then somehow extract the description from the resulting mess. In principle that would be easy because the wanted text appears in:
<div class="shortdescription nomobile noexcerpt noprint searchaux" style="display:none">City in Central Greece, Greece</div>
What is the purpose? There is no viable way to do the required complex operations in a manner that would be reasonable for generating text in another article. Johnuniq (talk) 07:34, 27 September 2018 (UTC)
- I know that there currently is no parameter with the description. What I'm asking is if after the the description was generated on the first line at {{Infobox settlement}}, can it then be added to a new
|description =param (which won't visually show up in the infobox), and then be accessed with {{Template parameter value}}? (currently testing this it seems it's not possible as I'm getting the errorLua error in Module:Template_parameter_value at line 43: bad argument #1 to 'gsub' (string expected, got nil).
) --Gonnym (talk) 10:02, 27 September 2018 (UTC)- Clearly a bug exists in Module:Template parameter value. Pinging the module's author.
-
|short_description={{Short description/test}}is inside{{infobox}}which is inside{{Infobox television episode/sandbox}}. Module:Template parameter value uses the same trick that I suggested with my Abraham Lincoln example: it read's the article's wiki source. If you can't see|short_description={{Short description/test}}in the article wiki source, then Module:Template parameter value won't be able to see it either.
-
- So how about this. Extract the infobox template from the article source (not necessarily an easy task because of nested templates – left as an exercise for the reader). Then call the syntaxhighlight parser function with the infobox wikitext as the argument:
{{#invoke:Sandbox/trappist the monk/tag|tag|{{Infobox television episode/sandbox
| title = test
| series =
| season = 5
| series_no =
| multi_episodes = y
| episode =
}}}}
- which returns:
<div class="shortdescription nomobile noexcerpt noprint searchaux" style="display:none">A television episode</div>[[Category:project pages with short description]]<table class="infobox vevent" style="width:22em"><tr><th colspan="2" class="summary" style="text-align:center;font-size:125%;font-weight:bold;font-weight: normal; background: #CCCCFF; padding: 0.25em 1em; line-height: normal;">"'''test'''"</th></tr><tr><th scope="row" style="white-space: nowrap">Episode <abbr title="numbers">nos.</abbr></th><td>Season 5<br /></td></tr></table>
- from which you can get your short description.
- —Trappist the monk (talk) 12:45, 27 September 2018 (UTC)
- To be honest, I'd suggest using JavaScript rather than Lua at present for this sort of job because it can access the API to read the generated descriptions directly. That avoids all of the messing about.
- Looking forward, I know there are obvious security concerns for Scribunto, but I think it might be worth making a case for asking for the API (or part of it, maybe 'read-only') to be exposed to Scribunto, so we could read something like https://en.wikipedia.org/w/api.php?action=query&prop=description&titles=Alan_Turing as a Lua object. That would make a lot of jobs much more feasible if we could make a proper case for it. --RexxS (talk) 13:53, 27 September 2018 (UTC)
- That does indeed make it much more easier. Is it possible for JavaScript and a Lua module to pass data to one another? Is there some sort of documentation I can read that someone can point me to? I don't know JS but maybe I'll be able to understand how to make it work. --Gonnym (talk) 14:16, 27 September 2018 (UTC)
- Javascript runs on the reader's browser, does it not? So whatever js script you might write has to somehow be made available to every reader who reads any page that would need that js script which means, I think, that the js script must be made part of whatever js MediaWiki includes with every page rendering.
-
- I do not know of any connection between Lua and js – they operate at different times; Lua modules are processed (by the MediaWiki servers) when you save or refresh a page, js is processed (by your browser) when you view the rendered (cached) page.
- —Trappist the monk (talk) 14:54, 27 September 2018 (UTC)
- If a user needs to install something then that isn't a viable idea, so its back to try and find the pattern to find the infobox in the article text. --Gonnym (talk) 15:29, 27 September 2018 (UTC)
- I believe the idea is to put it in MediaWiki:Common.js which is loaded for all pages. Frietjes (talk) 16:01, 27 September 2018 (UTC)
- If a user needs to install something then that isn't a viable idea, so its back to try and find the pattern to find the infobox in the article text. --Gonnym (talk) 15:29, 27 September 2018 (UTC)
- That does indeed make it much more easier. Is it possible for JavaScript and a Lua module to pass data to one another? Is there some sort of documentation I can read that someone can point me to? I don't know JS but maybe I'll be able to understand how to make it work. --Gonnym (talk) 14:16, 27 September 2018 (UTC)
- If you know the name of the infobox (
ibox_name) then once you have the Wikisource (content):
- which returns:
local ibox_start = string.find (content, '{{%s*' .. ibox_name)</code> -- find the start of {{Infobox ...; ibox_name is a pattern that accepts various legit spacing and capitalization ...
local ibox_text = string.match (content, '%b{}', ibox_start) -- ibox_start points to first { of the infobox template
- —Trappist the monk (talk) 16:37, 27 September 2018 (UTC)
- Did we solve the transcluding issue with "mw.title.new ('Abraham Lincoln'):getContent()" or was there another way to get the wikisource that I missed? --Gonnym (talk) 17:12, 27 September 2018 (UTC)
- Perhaps. You will notice that I added a
{{DISPLAYTITLE}}directive to your User:Gonnym/sandbox/tests2. Here, we fetch the{{Infobox television episode/sandbox}}template from your test page's wiki source, stir, and pour out this:{{#invoke:Sandbox/trappist the monk/tag2|tag|User:Gonnym/sandbox/tests2}}- Script error: No such module "Sandbox/trappist the monk/tag2".
- From that you can get the short description. I do not get any display title warning messages when I preview this page.
- —Trappist the monk (talk) 18:25, 27 September 2018 (UTC)
- I tried it with an article from my previous tests which I got an error with before and I still get it with this code - The End (Lost). It currently does not have a short description (but not sure that has any impact on the error). Might have to do with articles that are disambiguated. --Gonnym (talk) 08:16, 28 September 2018 (UTC)
- What did you try? What were the steps? What error did you get? Where can I see this error without my having to do the sleuthing work to noodle it out?
- —Trappist the monk (talk) 08:45, 28 September 2018 (UTC)
Sorry for being unclear. I just changed the article name to the title I mentioned {{#invoke:Sandbox/trappist the monk/tag2|tag|The End (Lost)}} and the error being the one previously statedSeems I had unused code that caused that. Bug not part of your code. --Gonnym (talk) 09:58, 28 September 2018 (UTC)Warning: Display title "User:Gonnym/sandbox/tests2" was ignored since it is not equivalent to the page's actual title.
--Gonnym (talk) 09:56, 28 September 2018 (UTC)- I've ran into an issue. The output from your code encloses the tag in <pre></pre> which causes the pattern to fail to match. If I remove the tag it works. I'm assuming this somehow causes the code to stop treating it as plain text. I tried using string.replace to replace the "pre" tag, but that didn't work. Any ideas? (pattern template can be found {User:Gonnym/sandbox/tests1) --Gonnym (talk) 11:31, 28 September 2018 (UTC)
- I've tweaked tag2 so that it returns the shortdescription text:
{{#invoke:Sandbox/trappist the monk/tag2|tag|User:Gonnym/sandbox/tests2}}- Script error: No such module "Sandbox/trappist the monk/tag2".
- —Trappist the monk (talk) 13:22, 28 September 2018 (UTC)
- I've tweaked tag2 so that it returns the shortdescription text:
- I tried it with an article from my previous tests which I got an error with before and I still get it with this code - The End (Lost). It currently does not have a short description (but not sure that has any impact on the error). Might have to do with articles that are disambiguated. --Gonnym (talk) 08:16, 28 September 2018 (UTC)
- Perhaps. You will notice that I added a
- Did we solve the transcluding issue with "mw.title.new ('Abraham Lincoln'):getContent()" or was there another way to get the wikisource that I missed? --Gonnym (talk) 17:12, 27 September 2018 (UTC)
- —Trappist the monk (talk) 16:37, 27 September 2018 (UTC)
I've now noticed that the output of {{#invoke:Sandbox/trappist the monk/tag2|tag|User:Gonnym/sandbox/tests2}} is incorrect (it shows on that page "4th episode of the fifth season of lost", while the result from the invoke shows "A television episode"). It's showing the default description in case there is no data filled in the infobox. Maybe using | short_description = {{Short description/test}} in the infobox didn't work? --Gonnym (talk) 23:00, 28 September 2018 (UTC)
- These parameters are getting to tag2:
| title = test | series = lost | season = 5 | series_no = | multi_episodes = | episode = 4
- but aren't coming out of
frame:expandTemplate(). Probably just need to massage the parameters a bit before passing them toframe:expandTemplate(). I'll do some experimenting tomorrow. - —Trappist the monk (talk) 00:52, 29 September 2018 (UTC)
{{#invoke:Sandbox/trappist the monk/tag2|extract_short_description|User:Gonnym/sandbox/tests2|infobox television episode/sandbox}}→ Script error: No such module "Sandbox/trappist the monk/tag2".- —Trappist the monk (talk) 11:28, 29 September 2018 (UTC)
- Amazing! Thanks again! --Gonnym (talk) 11:31, 29 September 2018 (UTC)
- On my sandbox page I have an
{{infobox television episode/sandbox}}that has|series={{lang|de|lost}}. I did that because editors will assign templated values to infobox parameters:{{#invoke:Sandbox/trappist the monk/tag2|extract_short_description|User:trappist the monk/sandbox|infobox television episode/sandbox}}→ Script error: No such module "Sandbox/trappist the monk/tag2".
- Float your mouse-pointer over lost in the rendering above and you should get a 'German language text' tooltip. Editors will also wikilink infobox parameters. If I write
|episode=[[44]]in the infobox, I get 'An episode of the forty-fifth season of lost'. I don't know what the rules are (if there are any) for short description text, but if wiki markup and templated data are acceptable then perhaps your module should accept wikilinked values for|episode=,|season=, and|series_no=? Or, perhaps, the infobox and its documentation should be modified to prohibit wikilinking of these parameters.
- On my sandbox page I have an
-
|short_description={{Short description/test}}in{{infobox television episode/sandbox}}is not required, right?- —Trappist the monk (talk) 12:15, 29 September 2018 (UTC)
- Per Wikipedia:Short description#Content, nothing in the description should be linked. Per the specific MoS guidelines in my case, those entries should also not be wikilinked. I'm ok with them failing as that means someone will fix a much larger issue first, but good find. I want to see how exactly it fails so nothing breaks. And yes, that isn't needed if your code doesn't use it. That was me trying to find a way to access the data. --Gonnym (talk) 12:25, 29 September 2018 (UTC)
- Amazing! Thanks again! --Gonnym (talk) 11:31, 29 September 2018 (UTC)
Overhead from a generally unused code path[edit]
Wikisaurus has added a "subst only" code path for generating the list of parameters from a template to the Russian version of Module:Check for unknown parameters (see the generate function in ru:Модуль:Check for unknown parameters). I added this to Module:Check for unknown parameters/sandbox, which seems fine since it's an entirely different code path. but, then I started wondering if there is any significant overhead from having this rarely used code path in the module? would it be better to put it in "Module:Check for unknown parameters/generate" or is there no substantial difference in terms of overhead? thank you. Frietjes (talk) 12:47, 27 September 2018 (UTC)
- Beyond the amount of time and resources required to read the extra 844 bytes that you added to the module, I would be surprised if there were any noticeable execution time difference between a 1000 iterations of the live module vs the sandbox module. That is an experiment that you can try; use the parser profiling data for comparison.
- —Trappist the monk (talk) 13:34, 27 September 2018 (UTC)
Overload Template:Bicolor (Commons)[edit]
Can someone please convert c:Template:Bicolor into a module? PS: I mean this would be a perfect reason for conversion. The idea of optimizing is also to omit ifexists with an existing color table. → User: Perhelion 11:15, 5 October 2018 (UTC)
- This is being discussed at c:Template talk:Bicolor. No good method. Johnuniq (talk) 00:42, 6 October 2018 (UTC)
- @Johnuniq what do you mean? The discussion comes from here...
Done → User: Perhelion 18:05, 10 October 2018 (UTC)
- I suspect that John meant that all of the solutions available suffer from some issue, such as expensive calls or size of rendered text, that makes them less than ideal in his (and in my) opinion. We have a solution of sorts, but I'm not 100% satisfied with it. Cheers --RexxS (talk) 18:43, 10 October 2018 (UTC)
Pages where template include size is exceeded[edit]
to remove Émerson Leão from Category:Pages where template include size is exceeded I created {{navboxes top}} and {{navboxes bottom}}. the implementation is definitely a hack, but could be improved by adding new functionality to Module:navbox. I don't think the problem is being caused by the tracking because {{navboxes/sandbox}} has no appended tracking and shows the same issue in preview. does anyone have any other ideas for addressing the problem, or is the top/bottom approach the only way? Frietjes (talk) 15:48, 11 October 2018 (UTC)
- Fix the root problem, which is Sports Navboxes in general? :) --Izno (talk) 16:50, 11 October 2018 (UTC)
- Frietjes may remember {{Football manager history}} which I refactored to use Module:Football manager history two years ago. Some preliminary discussion was here. I remember some other discussion was pretty indifferent about the module because quite a few participants felt that the enormous navboxes were way over the top and should be removed rather than fixed. The module drastically reduces the template expansion size because it processes everything once only. In the old system, nested template calls meant that each resulting line was counted three or four times because it was passed from template to template. Possibly the same approach would fix templates like {{Brazil squad 1970 FIFA World Cup}} which uses {{National squad}} which uses {{navbox}}. It might be straight forward based on the existing module, or looking at the details might show a bunch of work would be needed. Johnuniq (talk) 06:57, 12 October 2018 (UTC)
- Johnuniq, good suggestion. that fixed the problem for United States men's national soccer team, but did not fix Émerson Leão and Belgium national football team. unless there is another one that can be reduced in size, I am considering refactoring Template:Navboxes to use
{{#invoke:navboxes|top}}and{{#invoke:navboxes|bottom}}. the hack in Module:navboxes could be improved, but this would fix the problem for those two articles (and probably many others). Frietjes (talk) 15:06, 12 October 2018 (UTC)
- Johnuniq, good suggestion. that fixed the problem for United States men's national soccer team, but did not fix Émerson Leão and Belgium national football team. unless there is another one that can be reduced in size, I am considering refactoring Template:Navboxes to use
Module:Infobox[edit]
I'm trying to understand Module:Infobox and see if the code there allows another infobox module to send it values and for it to return the required sub-infobox, but since it lacks in documentation, I can't seem to figure this out (it seems me that it doesn't support what I want). What I'm looking for is something similar to what fr.wiki has with fr:Module: Infobox. If anyone can help me figure this out, would really appreciate this. --Gonnym (talk) 13:04, 23 October 2018 (UTC)
- Are you talking about embedding one infobox inside another?
- —Trappist the monk (talk) 13:12, 23 October 2018 (UTC)
- No. What I'm trying to do (which is available in the french version) is to create a very small infobox module (in terms of code) which only lists the parameters it gets from a user (fr:Module:Infobox/Tapis persan), which then sends it to the main module (Module:Infobox), which it is responsible for actually building it. Basically eliminating all the code currently in the infobox templates. --Gonnym (talk) 13:19, 23 October 2018 (UTC)
- As we currently have far more active editors familiar with template syntax than with Lua code, is it a good idea at present to shift so much of the development and maintenance of infoboxes onto a much smaller group? --RexxS (talk) 13:59, 23 October 2018 (UTC)
- That is neither my call nor my intention, but I also don't believe that not testing better options just because not enough people can add to it, is correct either. Also, the french example I've linked to seems much easier to code than any infobox I've seen, including the need to keep that awful numbering system which forces you to change so many lines, if you need to add a new row somewhere at the top. --Gonnym (talk) 14:13, 23 October 2018 (UTC)
- You may find User:Frietjes/infoboxgap.js useful in dealing with that awful numbering system. --RexxS (talk) 14:39, 23 October 2018 (UTC)
- That is neither my call nor my intention, but I also don't believe that not testing better options just because not enough people can add to it, is correct either. Also, the french example I've linked to seems much easier to code than any infobox I've seen, including the need to keep that awful numbering system which forces you to change so many lines, if you need to add a new row somewhere at the top. --Gonnym (talk) 14:13, 23 October 2018 (UTC)
- As we currently have far more active editors familiar with template syntax than with Lua code, is it a good idea at present to shift so much of the development and maintenance of infoboxes onto a much smaller group? --RexxS (talk) 13:59, 23 October 2018 (UTC)
- No. What I'm trying to do (which is available in the french version) is to create a very small infobox module (in terms of code) which only lists the parameters it gets from a user (fr:Module:Infobox/Tapis persan), which then sends it to the main module (Module:Infobox), which it is responsible for actually building it. Basically eliminating all the code currently in the infobox templates. --Gonnym (talk) 13:19, 23 October 2018 (UTC)
- @Gonnym: As far as I'm aware the module is currently inaccessible from other Lua modules (the p.infobox function only accepts values from a frame object), although Mr. Stradivarius might be able to say otherwise. You might want to fiddle a bit with the p.infobox function in a sandbox to see how it'll let you input data from another module.
- Parts of enwiki also have a weird thing for discouraging any more Lua modules than absolutely necessary because most editors can only read wikicode and therefore can't debug modules, although I do think the frwiki approach would have benefits for some templates like {{Singles}} (which already uses its own Lua module). Jc86035 (talk) 15:21, 24 October 2018 (UTC)
- @Jc86035: I don't believe it will let me, but no harm in playing a bit with it. Also, I don't understand how anyone can read this code Template:Infobox album (the part before the actual start of the infobox code) and even more think that it's easier to read than Lua. --Gonnym (talk) 18:10, 24 October 2018 (UTC)
- @Gonnym: My fault, because I wrote that part of the template. Most of the reason it's so complicated is because I was trying to replace and format about seven different templates' parameters by allowing their replacement through template substitution (example) and for some reason I thought it would be a good idea to do the formatting with parser functions and Module:String. If you take out the part between
|prev_title=and|$flags=override(the part that formats the parameters) then it starts to look a little more like it was written by a normal sensible person. Jc86035 (talk) 18:18, 24 October 2018 (UTC)
- @Gonnym: My fault, because I wrote that part of the template. Most of the reason it's so complicated is because I was trying to replace and format about seven different templates' parameters by allowing their replacement through template substitution (example) and for some reason I thought it would be a good idea to do the formatting with parser functions and Module:String. If you take out the part between
- @Jc86035: I don't believe it will let me, but no harm in playing a bit with it. Also, I don't understand how anyone can read this code Template:Infobox album (the part before the actual start of the infobox code) and even more think that it's easier to read than Lua. --Gonnym (talk) 18:10, 24 October 2018 (UTC)
It's generally not too difficult to make Scribunto functions available to other modules. If you want to make p.somefunc(frame) available in a simple form, you can check what is used from the frame object, say frame.args.param1 and frame.args.param2, then amend the function definition be to something like function p._somefunc(param1, param2), and use param1 and param2 in place of frame.args.param1 and frame.args.param2 within the function. Finally write
function p.somefunct(frame)
return p._somefunc(frame.args.param1, frame.args.param2)
end
to recreate the function that uses the frame object for use with #invoke. The _somefunc(param1, param2) will be available from require("Modulename")
There are alternative ways, for example passing a single table of parameters instead of each one individually (useful when there are lots of parameters), but the general principle is the same. --RexxS (talk) 22:05, 24 October 2018 (UTC)
- Yes, that will work with a bit of moving around the meat of that function into the _function, but from what I can tell from the code, the infobox is eventually still waiting for values in the form of how an infobox template keeps them, and not in an easy to code FR style. --Gonnym (talk) 22:19, 24 October 2018 (UTC)
[edit]
can someone help me debug Module:Navbox with collapsible groups which is being called through Template:Navbox with collapsible groups/sandbox? in particular, see Template:Navbox with collapsible groups/testcases. for debugging, I have appended the values of the 'sargs' which are used to build the subgroups, and I appended the values of 'targs' which is passed through Navbox._navbox to build the final result. the values for the sargs and the targs look great, but the actual navbox output has the academics group repeated 4 times :( I have never seen this pathology before. thank you! Frietjes (talk) 16:27, 24 October 2018 (UTC)
- update, this edit appears to fix the problem. so, going through the template interface for the child boxes, instead of going through the module interface. I think it would be better to go through the module interface, and I have no idea why that doesn't work. Frietjes (talk) 21:05, 24 October 2018 (UTC)
- I started looking at this but then I saw you were still working on it. Please post again if there is something specific I could look at. Johnuniq (talk) 04:15, 25 October 2018 (UTC)
- Johnuniq, I found the problem in Module:Navbox,
listnumswas being initialized globally, but not emptied at the top of_navbox(), so each time you call the_navbox()it just appends more lists tolistnums. it looks like this fixes the problem. I don't see any other entry points into the module, other thanp.navbox(frame)andp._navbox(navboxArgs)so it looks like it is safe to initialize listnums at the top ofp._navbox(navboxArgs)instead. Frietjes (talk) 13:20, 25 October 2018 (UTC)
- Johnuniq, I found the problem in Module:Navbox,
- I started looking at this but then I saw you were still working on it. Please post again if there is something specific I could look at. Johnuniq (talk) 04:15, 25 October 2018 (UTC)
teach Module:Graph some new tricks[edit]
background (long story - safe to skip): back in 2013, i created Module:Chart, to display bar and pie charts.
my motivation was mainly to make adding charts easier: the various charting templates that existed were limited (e.g., pie chart had max of 6 slices), none support "stacked" bar charts, and more importantly, they all used cumbersome (IMO) and inconvenient way of passing parameters: instead of, e.g., delimited list of numbers for each series, you had to pass a separate parameter for each data point, with different convention for each template. (there's a whole slew of other charts, using the "timeline" extension - those are even more difficult to use, and produce ugly charts, IMO).
(irrelevant, but interesting tidbit): this module uses an arcane and esoteric feature of html to display pie charts (which i copied from the brilliant template that already existed), exploiting the "border" element, giving it width and colors, and using the fact that 2 sides of html "border" are connected with a "bevel": by separately controlling the width of each side, you control the angle of the bevel, then you color one of the sides with he desired color, leave the other transparent, repeat for each segment of the pie, stacked on top of each other, do it separately for each of the 4 quarters of the axis system, and finish it all by covering the whole jumble with a circle, having transparent interior and white exterior. bizarre to the point perversion, and at the same time brilliant. the most amazing thing about it is the fact that it actually works...
- relevant part
anywhoo, several years later, the "graph" extension was introduced (mw:Extension:Graph), and some time later, User:Mps created Module:Graph (maybe elsewhere (dewiki?), and imported to enwiki - not sure). some time after that, Template:Graph:Chart was created. at this point, my 2013 "chart" module became obsolete, but people are still using it.
so here is (finally) my actual request: there are some legit requests on Module talk:Chart, to which i usually respond "you should use the new stuff". the latest such request, asked for horizontal bar chart, which neither module supports. i have no doubt the "graph" extension can easily do it, but unfortunately, Module:Graph does not provide horizontal bar charts. can someone pick the challenge, and teach this module to draw horizontal bar charts? and, maybe, while you are at it, also teach it to do scatter chart?
peace - קיפודנחש (aka kipod) (talk) 16:55, 25 October 2018 (UTC)
Module error on Syrian Civil War map[edit]
I've noted what seems to be a strange bug on the module maps at Talk:Cities and towns during the Syrian Civil War#Some sort of module error causing extra marks. If someone who has more experience with module programming and such could take a look, that'd be great. (This was originally posted on VPT, but someone pointed out in an unrelated section that this is usually where Module questions are asked.) Thanks, ansh666 21:22, 4 November 2018 (UTC)
- The above was posted at 00:45, 6 November 2018 and it looks as if the issue has been resolved according to the latest at the above talk link. Johnuniq (talk) 02:43, 6 November 2018 (UTC)
How do you look up which pages are directly calling given module?[edit]
I am looking for ways of tracking which pages directly call some module, in case I am altering the module interface. For example I have some Module:X intended to be accessed through Template:X and I would like to check if any other templates, modules or other pages call it. Special:WhatLinksHere with namespace filter is great but it is swamped by 'indirect calls through template. One can compare Special:WhatLinksHere for Module:X and Template:X and look for the differences, but that also mostly has pages which are there for unexplained reason. I only want to find pages with "{{#invoke:X|Y" so maybe I should write SQL query to look for that in page text? Or is there an easier way? --Jarekt (talk) 17:39, 7 November 2018 (UTC)
- Enter
insource:"invoke:X"in the search box. Click "Everything" to find results in all namespaces. PrimeHunter (talk) 17:52, 7 November 2018 (UTC) - (edit conflict) @Jarekt: If I go to Special:Search, then pick the namespaces and search for something like
insource:/invoke:\s*WikidataIB/, I can find the pages that invoke WikidataIB. You'll probably be able to adapt that for what you need. Cheers --RexxS (talk) 18:04, 7 November 2018 (UTC)insource:/.../is an expensive regex search which shouldn't be used alone per mw:Help:CirrusSearch#Insource. A normalinsource:search works fine here unless the module name often occurs after the word "invoke" in normal English text. PrimeHunter (talk) 18:16, 7 November 2018 (UTC)- As you don't know whether there are space characters between "invoke:" and the module name, your search will miss those. You need a regex to find all of them in one search. As usual, the documentation on mediawiki is a long way from realistic, and these sort of simple searches execute rapidly without problems.
- If you feel you have to use a search domain to use the regex on, then something like
insource:"WikidataIB" insource:/invoke:\s*WikidataIB/will do the job almost instantly. --RexxS (talk) 19:11, 7 November 2018 (UTC)- I prefer to limit it to "hastemplate:"Module:X" insource:/invoke:\s*X/". --Izno (talk) 19:13, 7 November 2018 (UTC)
insource:"invoke:X"also finds cases with spaces and it's simple. PrimeHunter (talk) 00:21, 8 November 2018 (UTC)- You're absolutely right and I was wrong: your search works. The colon character is treated as greyspace, so of course it will also match
invoke X, etc. But as you say, that's almost certainly not going to be a common expression in prose (unless you write a module called "BRD"). Cheers --RexxS (talk) 01:40, 8 November 2018 (UTC)
- You're absolutely right and I was wrong: your search works. The colon character is treated as greyspace, so of course it will also match
Thanks all for your help! --Jarekt (talk) 19:27, 7 November 2018 (UTC)
Knowing if being called from a disambiguation page[edit]
If a template/module needs to know if it is being invoked from a disambiguation page (without user input), is searching the page for the {{Disambiguation}} template (and redirects) the way to go, or is there another way? --Gonnym (talk) 23:54, 7 November 2018 (UTC)
- It's pretty ugly, but searching the page content is all that's possible, I think. That's what I did at c:Module:Countries in function
getRedirectTarget. It seems to be pretty fast. It was pointed out to me that I missed a few infrequently used redirects/templates but I thought targeting the main ones was good enough. Johnuniq (talk) 00:09, 8 November 2018 (UTC) -
- Doesn't
mw.title.getCurrentTitle().isRedirectgive you that answer? - —Trappist the monk (talk) 13:05, 8 November 2018 (UTC)
- Tested it out and no. It makes sense as redirect is not the same as disambiguation I guess. --Gonnym (talk) 13:33, 8 November 2018 (UTC)
- Doh! brain fart. nevermind.
- —Trappist the monk (talk) 14:06, 8 November 2018 (UTC)
- Tested it out and no. It makes sense as redirect is not the same as disambiguation I guess. --Gonnym (talk) 13:33, 8 November 2018 (UTC)
- Doesn't
How can one track module dependencies[edit]
I am wandering is there some way of tracking module dependencies. Let me give an example, on commons we have c:Module:Fallback which according to Special:MostTranscludedPages is used on 44M pages, including many other modules like my c:Module:Artwork or RexxS' c:Module:WikidataIB. c:Module:Fallback implements mostly retired language fallback mechanism and should not be part of many of other Modules, so I am curious how those dependencies sneak in. Is there some tool or approach to track it down? --Jarekt (talk) 21:40, 8 November 2018 (UTC)
- You might try this kind of search in the module namespace:
insource:/require *\( *["']module:fallback["']/i→ [1]
- —Trappist the monk (talk) 12:32, 9 November 2018 (UTC)
- @Jarekt: Following up from PrimeHunter's tip above, searching for
insource:"require module fallback"finds them plus a couple of extras likemodule:fallback/sandbox. There are few enough of those to manually pick the ones that interest you. --RexxS (talk) 13:37, 9 November 2018 (UTC)- c:Module:Fallback is used by couple abandon and unused modules and by subtemplates of c:Module:Wikidata (used on 2M pages), so 44M uses is a mistery as I can not find templates that use it either. --Jarekt (talk) 03:58, 18 November 2018 (UTC)
- @Jarekt: Following up from PrimeHunter's tip above, searching for
Validating date parameter is in a Template:Start date[edit]
I have a template which the documentation asks for the date parameter to be in a {{Start date}} template. The template code is in the template namespace and is not a module. I'm trying to add a tracking cat to it in the situations where the date is not in that format. I've tried using {{Str sub find}} and also invoking String.find directly, but can't get this to work. This fails either because of the "|" character, which I can escape in the static target value with {{!}}, but I'm not sure how to handle the user-entered value; or it fails because of the template itself. Alternatively, if there is a better option, I'm open to that as well.
Example code:
{{#if: {{str sub find|1={{start date|1993|02|24}}|2={{start date|}} }} | Substring is found | Substring is not found }}-> Substring is not found --Gonnym (talk) 10:34, 12 November 2018 (UTC)
- I don't know if this would help (I have not investigated your issue), but {{extract}} can parse dates. Problem: It checks the date for validity and people often make mistakes such as 31 April so the result might cause clutter.
{{extract|show=format}}→ error{{extract|2001|2|28|show=format}}→ dmy{{extract|Feb 28, 2001|show=format}}→ mdy{{extract|2001|2|29|show=format}}→ error
- Johnuniq (talk) 22:10, 12 November 2018 (UTC)
- This might work, but I'm running into issues with it:
- {{start date|1993|02|24}} → February 24, 1993
- {{extract|1993|02|24|show=mdy}} → February 24, 1993
- {{extract|{{start date|1993|02|24}}|show=mdy}} → Error: Need valid date
Any idea?This might be because {{Start date}} "also includes duplicate, machine-readable date (or date-time) in the ISO date format (which is hidden by CSS), for use inside other templates (or table rows) which emit microformats". --Gonnym (talk) 12:18, 13 November 2018 (UTC)- Also, I'm not sure this would really solve my issue, as it will accept correctly formatted dates, but not those using the template, which is a requirement. --Gonnym (talk) 12:22, 13 November 2018 (UTC)
- Your problem rests on the fact that the parser will expand the template {{Start date}} before passing its value to your template. Perhaps something like this will be usable:
{{Posnq | {{start date|2018|November|30}} | bday dtstart published updated }}→ 75{{Posnq | 30 November 2018 | bday dtstart published updated }}→{{Posnq | {{start date|2018|November|31}} | bday dtstart published updated }}→ 75{{Posnq | 31 November 2018 | bday dtstart published updated }}→
- That accepts invalid dates as well, but still discriminates between having a template that has those microformats and one that doesn't. Obviously, you pass {{{date|}}} as the first parameter. --RexxS (talk) 14:24, 13 November 2018 (UTC)
- Just to help check: Let's say you were looking for the parameter
|airdate=in Template:Infobox television episode. You could search all articles on:insource:"Infobox television episode" insource:"airdate"to find 9,240 occurrences; then on:insource:"Infobox television episode" insource:"airdate" insource:/| *airdate *= *\{\{[Ss]tart date/to find 3,775 that have the {{start date}} template; and on:insource:"Infobox television episode" insource:"airdate" insource:/| *airdate *= *[^{ ]/to find 5,674 that don't have a template.insource:"Infobox television episode" insource:"airdate" insource:/| *airdate *= *[1-9A-Za-z]/shows 5,648 articles. --RexxS (talk) 16:14, 13 November 2018 (UTC)
- I always like to point out that insource:"name of template" is more fragile compared to hastemplate:"Infobox television episode", which catches all transclusions (some 120 through pass-through templates in this case). (I think I did that recently with you--just a friendly reminder.) It's also less expensive for the search in the event you have multiple templates with a single core template (as with the citation module for example). (I think it's marginally less expensive than an insource search even without regex but I could be wrong about that.) --Izno (talk) 17:18, 13 November 2018 (UTC)
- Your problem rests on the fact that the parser will expand the template {{Start date}} before passing its value to your template. Perhaps something like this will be usable:
@RexxS: - I've used your code and it works and I've also found another template that does it. However, {{posnq}} will fail if any text is placed before {{Start date}} (which technically is good, but not the way I'd like to catch "abnormal" additions, as that will include other cases) so hard-codding the result to "75" is a bit fragile here.
- {{str find0}}:
{{#ifexpr: {{str find0| {{start date|1993|02|24}} | dtstart }} != -1 | Substring is found | Substring is not found }}→ Substring is found - {{str find0}}:
{{#ifexpr: {{str find0| First released: {{start date|1993|02|24}} | dtstart }} != -1 | Substring is found | Substring is not found }}→ Substring is found - {{posnq}} ok:
{{#ifexpr: {{Posnq| {{start date|1993|02|24}} | bday dtstart published updated }} = 75 | Substring is found | Substring is not found }}→ Substring is found - {{posnq}} fail:
{{#ifexpr: {{Posnq| First released: {{start date|1993|02|24}} | bday dtstart published updated }} = 75 | Substring is found | Substring is not found }}→ Substring is not found
I'm pretty sure if the template was in lua, this whole process would have been easier and cleaner. --Gonnym (talk) 10:29, 14 November 2018 (UTC)
- @Gonnym: Template:Posnq is designed to return nothing if no match is found, so you only need to use an #if to test (since #if treats nothing as false and anything else as true):
{{#if: {{Posnq | {{start date|1993|02|24}} | bday dtstart published updated }} | | [[:Category:Parameter not using Start date template]] }}→{{#if: {{Posnq | 24 February 1993 | bday dtstart published updated }} | | [[:Category:Parameter not using Start date template]] }}→ Category:Parameter not using Start date template
- All you need to do is add:
{{#if: {{Posnq | {{{airdate|}}} | bday dtstart published updated }} | | [[Category:Parameter not using Start date template]] }}
- to the template in its tracking category section. --RexxS (talk) 14:40, 14 November 2018 (UTC)
- @Gonnym: Template:Posnq is designed to return nothing if no match is found, so you only need to use an #if to test (since #if treats nothing as false and anything else as true):
Lua "Beta" template[edit]
What is the template to say in Lua documentation: "This module is beta status/quality"? (alpha, etc). -DePiep (talk) 12:35, 17 November 2018 (UTC)
- Found: {{Module rating}} - DePiep (talk) 12:41, 17 November 2018 (UTC)
Mystery script errors on Wikidata[edit]
Wikidata has 4K pages with d:Category:Pages_with_script_errors. Pages like d:Talk:Q100 where I can see the error details in html ( in <script> but not on the page itself. How do we debug such cases? --Jarekt (talk) 04:09, 18 November 2018 (UTC)
- That is a really weird one. The error (translated from the HTML source) is:
Lua error: bad argument #1 to 'getAllStatements' (string expected, got nil). in function "error" libraryUtil.lua:11: in function "checkType" mw.wikibase.lua:151: ? (tail call): ? Module:Wikidata:581: in function "getClaims" Module:Wikidata/utils:44: ? (tail call): ? mw.lua:511: ?
- Something is going wrong during the expansion of {{Item documentation}}. Interestingly, editing d:Talk:Q100 shows its contents is {{Item documentation}} and previewing the edit (without changing anything) shows d:Category:Pages with script errors at the bottom. However, replacing the contents with {{Item documentation|Q100}} and previewing shows there is no error category. Near the bottom of the preview page is "Lua logs" with some mumbo jumbo that I suspect is internal to mw.wikibase although I can't find it. Previewing {{Item documentation|Q5}} shows a much longer log corresponding to the longer tree of "parent classes". The "1>=10" stuff might be a log of a binary search? Or a sort? I don't have time to look more at the moment. If someone doesn't crack it soon, a developer might be needed. Johnuniq (talk) 06:44, 18 November 2018 (UTC)
- Hmm. I put a temporary test in d:Module:Wikidata (preview only) and confirmed that everything works at line 581 which is the fail point in the error above. That is,
entityandpropertyare always strings. That makes me think that a developer is needed. Johnuniq (talk) 06:55, 18 November 2018 (UTC) - @Jarekt: I think I fixed the problem with an edit at d:Template:Item documentation. Try refreshing or purging affected pages and the errors might go away. Johnuniq (talk) 10:10, 18 November 2018 (UTC)
- Johnuniq Thanks a lot for looking into it. I spent a while scrathing my head trying to figure it out. The number of pages in d:Category:Pages with script errors is now 448, down from 4k. So your elagant fix of the template worked. --Jarekt (talk) 02:54, 19 November 2018 (UTC)