Topic on Extension talk:Scribunto

Jump to navigation Jump to search
67.8.160.54 (talkcontribs)

I'm suddenly getting this error on every infobox call on any page.

Lua error in mw.html.lua at line 253: Invalid class given: The name must be either a string or a number.

Backtrace:

   (tail call): ?
   [C]: in function "error"
   mw.html.lua:253: in function "addClass"
   Module:Infobox:233: ?
   (tail call): ?
   mw.lua:567: ?
   (tail call): ?
   [C]: in function "xpcall"
   MWServer.lua:87: in function "handleCall"
   MWServer.lua:301: in function "dispatch"
   MWServer.lua:40: in function "execute"
   mw_main.lua:7: in main chunk
   [C]: ?

Can anyone help me out? I'm not super advanced with this sort of stuff.

Jackmcbarn (talkcontribs)

You need a newer version of Scribunto. For details, see bugzilla:72880.

90.2.9.113 (talkcontribs)

There's a bug in the mw.html.lua file (I've downloaded the last version with the "Download" link on the extension prestation page))

Wrong content: function HtmlBuilder.create( tagName, args ) if type( tagName ) ~= 'string' then error( "Tag name must be a string" ) end

if tagName ~= and not isValidTag( tagName ) then error( "Invalid tag name: " .. tagName ) end Correction: function HtmlBuilder.create( tagName, args ) if tagName ~= nil then if type( tagName ) ~= 'string' then error( "Tag name must be a string" ) end if tagName ~= and not isValidTag( tagName ) then error( "Invalid tag name: " .. tagName ) end end

137.147.57.173 (talkcontribs)

No, that's just an old version from before it allowed nil values. Download the latest version (master).

Reply to "Scribunto Script Error"