Page MenuHomeMiraheze

Enable tabular.JsonConfig
Closed, ResolvedPublic

Description

Hello. In several wikis (for example), the Spanish Wikipedia Extract template is being used. The template through modules, makes a "call" to the page Data:I18n/Module:Excerpt.tab that is hosted on Wikimedia Commons. And because there is no configuration, the following error appears constantly: Lua error in Module:TNT on line 159: Missing JsonConfig extension; Cannot load https://commons.wikimedia.org/wiki/Data:I18n/Module:Excerpt.tab.

I'm not sure how I can fix this and in what way. Especially the first configuration.

Configuration

$wgJsonConfigModels['Tabular.JsonConfig'] = 'JsonConfig\JCTabularContent';
$wgJsonConfigs['Tabular.JsonConfig'] = array(
	'namespace' => 486, // === NS_DATA, but the constant is not defined yet
	'nsName' => 'Data',
	'isLocal' => false,
	'pattern' => '/.\.tab$/'
);

$wgJsonConfigs['Tabular.JsonConfig']['store'] = true;

$wgJsonConfigs['Tabular.JsonConfig']['remote'] = 'https://commons.wikimedia.org/w/api.php';

Event Timeline

Unknown Object (User) added a comment.Oct 2 2020, 00:50

Did you enable the JSONConfig extension in Special:ManageWiki/extensions?

I receive the same error:

Lua error in Module:TNT on line 159: Missing JsonConfig extension; Cannot load https://commons.wikimedia.org/wiki/Data:I18n/Module:Excerpt.tab.

in: https://tuscriaturas.miraheze.org/wiki/Plantilla:Extracto
But i have already the JsonConfig Extension, the Module:TNT and other associated extensions and pages, as anyone can see here: https://tuscriaturas.miraheze.org/wiki/Especial:Versi%C3%B3n Version
and: https://tuscriaturas.miraheze.org/wiki/Especial:Todas?from=&to=&namespace=828 Special:AllPages Module.
About the:

Data:I18n/Module:Excerpt.tab

, when i tried to export/import that from wikimedia commons, i received this message in my import page:

import has failed: The content model 'Tabular.JsonConfig' is not registered on this wiki. See https://www.mediawiki.org/wiki/Content_handlers to find out which extensions handle this content model.

But Content handlers does not have a single coincidence to the word "tabular" when using CTRL + F.

In T6214#122377, @Universal_Omega wrote:

Did you enable the JSONConfig extension in Special:ManageWiki/extensions?

I thought that was clear. The extension is enabled but needs the above configuration to really work.

This comment was removed by Hispano76.

Notably, this creates some hard-to-debug errors when naively importing templates from WP/WM.org.

Unknown Object (User) closed this task as Resolved.Nov 2 2020, 13:47
Unknown Object (User) claimed this task.