Last modified: 2013-10-16 05:49:01 UTC
If you create an on-wiki tour MediaWiki:Guidedtour-tour-mytour.js but the tourSpec object you pass to gt.defineTour contains name: 'My Tour', then GuidedTour fails with TypeError: definedTours[tourName] is undefined http://localhost/wiki/extensions/GuidedTour/modules/ext.guidedTour.lib.js Line 921 This happens because the name must exactly match the tour name from the page title. 1. DRY, don't make tour author supply it in this case (pass the expected tour name to the callback) 2. If you do supply it and it doesn't match, defineTour() should warn 'Optional \'tourSpec.name\' "My Tour" doesn't match on-wiki tour name "mytour"'.
I don't think there's a clean way to determine which file is calling defineTour. There's no way I know to pass a tour-specific dependency object (e.g. an object that knew which tour was supposed to call it) to a tour script Closing as WONTFIX for now, but reopen if you have an approach for implementing it.