Commit graph

88 commits

Author SHA1 Message Date
Translation updater bot fab97f7845 Localisation updates from http://translatewiki.net.
Change-Id: Iad343ae19ed6329eae4fe640cc94b99708d56e70
2012-08-11 19:23:20 +00:00
Translation updater bot 9b06b8203f Localisation updates from http://translatewiki.net.
Change-Id: Icbcce1922ac4faece618d22fa68284e66eb56b15
2012-08-11 00:04:14 +00:00
Translation updater bot 2b93b663e5 Localisation updates from http://translatewiki.net.
Change-Id: I1e7ea1c8fa681bf55146b0929bc0d5b164d806a9
2012-08-10 19:23:59 +00:00
Translation updater bot 4e675441eb Localisation updates from http://translatewiki.net.
Change-Id: I89b70cb314b7763c8bd43982e4f90ac5578d0534
2012-08-09 19:32:23 +00:00
Translation updater bot a1fe28ea22 Localisation updates from http://translatewiki.net.
Change-Id: I90999e173f0ba8b3b8c1979f7e9b18f405d515a0
2012-08-08 19:19:44 +00:00
Amir E. Aharoni 7f3444a3d1 Rephrase scribunto-ignore-errors
The message should be more self-explanatory now.
(I guessed what it is supposed to mean according to
the qqq documentation.)

Change-Id: I2021ffb1a3165e01d93c4c34fdbf39080d18eb2c
2012-08-08 12:18:24 +03:00
Amir E. Aharoni b8fb66dbda Rephrased two messages to make them clearer
Change-Id: Ia649c67c9b2cce51cc9e794da4d679008a4c8667
2012-08-08 12:15:56 +03:00
Translation updater bot 25541e8a2a Localisation updates from http://translatewiki.net.
Change-Id: If2304da28c6ca8d8d88adb55cfccc730f6cdc0e4
2012-08-07 20:10:33 +00:00
Translation updater bot 822a5bb1e8 Localisation updates from http://translatewiki.net.
Change-Id: I3b36d22117b572a24990098011ca7b75173b7c96
2012-08-06 19:28:38 +00:00
Translation updater bot b1e45f2c90 Localisation updates from http://translatewiki.net.
Change-Id: I9382222f5a6799c3c16926563f126a19c39d9ae1
2012-08-05 19:30:37 +00:00
Translation updater bot 2c4cac2ea8 Localisation updates from http://translatewiki.net.
Change-Id: I80b64c4a2f14300a604602d23c01f6645a40e816
2012-08-03 16:20:34 +00:00
Translation updater bot d63b6fbf30 Localisation updates from http://translatewiki.net.
Change-Id: I364490317b464cd87491f47d582105c99f278b63
2012-08-01 20:09:07 +00:00
Translation updater bot 4e91fc6808 Localisation updates from http://translatewiki.net.
Change-Id: Ic319b22a2b8421019c905a0807217551f956341a
2012-07-23 13:44:54 +00:00
Tim Starling b5c36bad59 Debug console module
* Added a debug console to the edit page, allowing unsaved modules to be
  tested.
* Removed the "preview" button from the edit page.
* Only show the "ignore code errors" checkbox on module edit pages, not
  all edit pages.
* Added Lua function mw.log() for sending messages to the debug log.

Change-Id: Ia51f439e573a1deb5b83f94ddd1a86792d5569c1
2012-07-14 14:35:55 +10:00
Translation updater bot 16e9eba133 Localisation updates from http://translatewiki.net.
Change-Id: I8fe56aa5b3c7825b20c4e33e2874c543f101124d
2012-07-11 20:00:33 +00:00
Translation updater bot fb8b86931c Localisation updates from http://translatewiki.net.
Change-Id: I7cdd8c5430ef08faa82a689d08e618f81462ef79
2012-07-08 19:23:09 +00:00
Translation updater bot 751ea278ff Localisation updates from http://translatewiki.net.
Change-Id: I1f7b8dd6267b5afddf8b31955838a4bf208a8901
2012-07-06 21:20:43 +00:00
Translation updater bot c248cccf5c Localisation updates from http://translatewiki.net.
Change-Id: I63e22a36016c7436c886c52776242a2ab935f9db
2012-07-05 19:46:15 +00:00
Translation updater bot d86dcb0b70 Localisation updates from http://translatewiki.net.
Change-Id: I103eabfb4d3e45f50573f0088208861697a4f31d
2012-07-04 20:09:43 +00:00
Translation updater bot dfa09541e5 Localisation updates from http://translatewiki.net.
Change-Id: I579f7efb14104f4d5bb37a7b6aff67b22babae9d
2012-07-03 20:57:37 +00:00
Tim Starling be8f6ca34d Allow users to ignore parse errors
Allow users to save a module with a parse error in it, by checking an
"ignore error" box. This was a requested feature in Berlin, there was a
desire to be able to save incomplete drafts of modules. I tested the
effect of #invoking a module with a parse error in it, it shows a normal
script error.

Change-Id: If2978a226ac50150ebeb7837e8dd370a669db771
2012-07-03 13:02:03 +10:00
Translation updater bot c161d29775 Localisation updates from http://translatewiki.net.
Change-Id: Ia5f61acba06fa80990010972c02e7b3201fe3615
2012-07-02 22:15:05 +00:00
Translation updater bot 9080ece112 Localisation updates from http://translatewiki.net.
Change-Id: I5ffed16964243ae072dc609e305e2f1bf5389e70
2012-07-01 14:14:36 +00:00
Translation updater bot 35df9011f5 Localisation updates from http://translatewiki.net.
Change-Id: I869017bb695c52f6f16f984905372832c3200716
2012-06-28 19:49:07 +00:00
Translation updater bot 825f7937e3 Localisation updates from http://translatewiki.net.
Change-Id: I64c06ba75a61a835ee4874b69836d980800bd21f
2012-06-25 20:18:25 +00:00
Translation updater bot 47091cecdb $COMMITMSG
Change-Id: I13c67d45b89d5ef291dcf4d0203a8898e1434704
2012-06-23 20:14:39 +00:00
Translation updater bot f845c6b62e Localisation updates from http://translatewiki.net.
Change-Id: Ia66a84181cd2f033a53a130249655f6a4f47d182
2012-06-21 20:26:01 +00:00
Translation updater bot 751d517ace Localisation updates from http://translatewiki.net.
Change-Id: If439bc218cffd8082cee790ef588ea40122a6dcd
2012-06-20 20:26:59 +00:00
Translation updater bot 10028eb8ba Localisation updates from http://translatewiki.net.
Change-Id: I3a323120699e8128a2d6903267e1589261745a33
2012-06-19 19:29:49 +00:00
Siebrand Mazeland d97b59395a Update punctuation and casing for error messages.
Change-Id: I97f7732010ebfebcf494ac9e308275b34dbb9609
2012-06-19 16:49:49 +02:00
Translation updater bot 3fd6deea93 Localisation updates from http://translatewiki.net.
Change-Id: I4bae79625c97fd7ac55e9ea7b1f6acdabc2a6494
2012-06-17 20:33:18 +00:00
Translation updater bot f66392bdde Localisation updates from http://translatewiki.net.
Change-Id: I689c625516880fe23738a046e74a930888e68503
2012-06-15 22:06:10 +00:00
Tim Starling 35cc7c4630 Added CPU usage to limit report
Also changed scribunto-lua-in-function-at to not say "anonymous" since
it also applies to functions which are not anonymous as declared, only
anonymous as called.

Change-Id: Ib99cc6d12fbb40a295e1fda35ac48bcf097fdb66
2012-04-30 16:37:41 +10:00
Victor Vasiliev f311f8bc96 Minor code cleanup.
* Remove an unused message.
* Remove an unused skin reference which caused notices.

Change-Id: I5d051f3a04da089e1789fd785a80c91b5be9a340
2012-04-29 18:26:04 +04:00
Tim Starling da06273ede Nicer errors with backtraces etc.
* Added error backtrace collection to MWServer:handleCall()
* When there is an error on parse, show a short and simple inline error
  message to the user, which when clicked, expands to a full error with
  HTML-formatted backtrace.
* When an error is encountered during module validation, have the code
  editor jump directly to the line. Requires r115011.
* Expose the code location of most errors to Scribunto, by parsing the
  standard error message format.
* During module validation, abbreviate the error location if the error
  is in the same module.
* Do not execute the module during validation, just parse it. Execution
  does not really work without an active parse operation in progress.
  It already caused a fatal error if you called require() from the main
  chunk, and problems would have become more visible as more
  parser-related APIs were added.
* LuaSandbox does not yet provide backtraces, but this is planned.

Change-Id: Id9f6564a41b310792b3fe3ebb527cbf8f8771bd1
2012-04-23 21:58:30 +10:00
tstarling cebe775ee8 Added more Lua environment features
Package library:

* Added a simulation of the Lua 5.1 package library.
* Removed mw.import(), replaced it with a package loader. Packages can be
  retrieved from the wiki, using require('Module:Foo'), or from files
  distributed with Scribunto, using require('foo'). The "Module:" prefix allows
  for source compatibility with existing Lua code.
* Added a couple of libraries from LuaForge: luabit and stringtools.
* Made fetchModuleFromParser() return null on error instead of throwing an
  exception, to more easily support the desired behaviour of the package loader,
  which needs to return null on error.
* Renamed mw.setupEnvironment() to mw.setup() since it is setting up things
  other than the environment now.
* In MWServer:handleRegisterLibrary(), remove the feature which interprets dots
  in library names, since LuaSandbox doesn't support this.

Improved module isolation and related refactoring:

* Expose restricted versions of getfenv() and setfenv() to user Lua code.
  Requires luasandbox r114952.
* Don't cache the export list returned by module execution for later function
  calls. This breaks isolation of #invoke calls, since the local variables are
  persistent.
* Removed ScribuntoFunctionBase and its children, since it doesn't really have
  a purpose if it can't cache anything. Instead, invoke functions using a module
  method called invoke().
* Removed Module::initialize(), replaced it with a validate() function. This is
  a more elegant interface and works better with the new module caching scheme.
* Use a Status object for the return value of Engine::validate() instead of an
  array. Use the formatting facilities of the Status class.

Other:

* Removed "too many returns" error, doesn't fit in with Lua conventions.
* Use the standalone engine by default, so that the extension will work without
  configuration for more people.
* Added an accessor for $engine->interpreter
* Fix mw.clone() to correctly clone metatables
* If the standalone interpreter exits due to an error, there are some contexts
  where the initial error will be caught and ignored, and the user will see the
  error from checkValid() instead. In this case, rethrow the original error for
  a more informative message.
* Load mw.lua into the initial standalone environment, to reduce code
  duplication between mw.lua and MWServer.lua.
* Fixed a bug in Scribunto_LuaStandaloneInterpreter::handleCall() for functions
  that return no results.
* Fixed a bug in encodeLuaVar() for strings with "\r". Added test case.
* In MWServer.lua, don't call error() for internal errors, instead just print
  the error and exit. This avoids a protocol violation when an error is
  encountered from within handleCall().
* Added lots of documentation. Lua doc comments are in LuaDoc format.

Change-Id: Ie2fd572c362bedf02f45d3fa5352a5280e034740
2012-04-18 13:46:18 +10:00
tstarling 54cedd69b8 Introduced standalone interpreter, implemented module isolation
* Introduced a Lua implementation based on shelling out to a standard Lua binary.
* Bundled several Lua binaries for common platforms. I haven't added a 32-bit Linux binary yet, but that will come.
* Refactored the existing Lua class, bringing out functionality common to all Lua implementations into a set of common base classes.
* Moved the bulk of the implementation-specific functionality into a set of "interpreter" classes.
* Renamed LuaSandboxEngine to Scribunto_LuaSandboxEngine
* Don't create an engine object unconditionally when the ParserLimitReport hook is called.
* Implemented isolation of module global variable namespaces. This means that separate {{#invoke}} calls can't pass data to each other -- this was a desired feature in planning since it allows more flexibility in wikitext parser design. Isolation for mw.import() means that modules cannot accidentally create global variables which affect other modules -- exports are solely via the return value.

Change-Id: I3fa35651fe5b1fbfd85adeadc220b1ea31cd6f0b
2012-04-13 20:45:26 +10:00
Tim Starling a1e4c450cb File moves for extension rename, and removed unused directory 2012-04-06 05:06:27 +00:00
Renamed from Scripting.i18n.php (Browse further)