https://bugzilla.wikimedia.org/show_bug.cgi?id=47102

       Web browser: ---
            Bug ID: 47102
           Summary: unspecified globals
           Product: MediaWiki extensions
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: Unprioritized
         Component: Semantic MediaWiki
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected], [email protected]
    Classification: Unclassified
   Mobile Platform: ---

Please declare all globals used or created in this extension. When this
extension is included within a function rather than at file-scope, then globals
are not being created/referenced correctly. 

Here's what I added to my version 1.8 SemanticMnediawiki.php to make it work in
a wikifarm:

global $wgExtensionCredits, $wgExtensionFunctions, $wgHooks,
$wgExtensionMessagesFiles, $wgAutoloadClasses, 
    $wgSpecialPageGroups, $wgSpecialPages, $wgGroupPermissions,
$wgAvailableRights, $wgReservedUsernames,
    $wgResourceModules, $wgLogTypes, $wgLogNames, $wgLogHeaders, $wgLogActions,
$wgAPIModules, $useJQuery, 
    $wgAPIListModules, $wgVersion, $wgExtraNamespaces,
$wgNamespacesWithSubpages, $wgActions, $wgJobClasses, 
    $wgAjaxExportList, $wgEditPageFrameOptions, $wgLanguageCode,
$wgParserTestFiles, $wgDefaultUserOptions,
    $wgExtensionAssetsPath, $wgExtensionAssetsFullPath, $useJQuery,
$wgExtensionAliasesFiles
    ;


Here is what I added to version 1.8 SMW_Settings.php:

global $smwgScriptPath, $smwgScriptUrl;
global $wgExtensionAssetsPath, $wgExtensionAssetsUrl;
global $smwgIP, $smwgDefaultStore, $smwgSparqlDatabase,
$smwgSparqlQueryEndpoint,
    $smwgSparqlUpdateEndpoint, $smwgSparqlDataEndpoint,
$smwgSparqlDefaultGraph,
    $smwgHistoricTypeNamespace, $smwgNamespaceIndex, $smwgShowFactbox,
    $smwgShowFactboxEdit, $smwgToolboxBrowseLink, $smwgInlineErrors, 
    $smwgUseCategoryHierarchy, $smwgCategoriesAsInstances, $smwgLinksInValues,
    $smwgDefaultNumRecurringEvents, $smwgMaxNumRecurringEvents, 
    $smwgBrowseShowInverse, $smwgBrowseShowAll, $smwgSearchByPropertyFuzzy,
    $smwgTypePagingLimit, $smwgConceptPagingLimit, $smwgPropertyPagingLimit,
    $smwgMaxPropertyValues, $smwgQEnabled, $smwgQMaxLimit,
$smwgIgnoreQueryErrors,
    $smwgQSubcategoryDepth, $smwgQSubpropertyDepth, $smwgQEqualitySupport,
    $smwgQSortingSupport, $smwgQRandSortingSupport, $smwgQDefaultNamespaces,
    $smwgQComparators, $smwStrictComparators, $smwgQMaxSize, $smwgQMaxDepth,
    $smwgQDefaultLimit, $smwgQMaxInlineLimit, $smwgQPrintoutLimit,
$smwgQDefaultLinking,
     $smwgQConceptCaching, $smwgQConceptMaxSize, $smwgQConceptMaxDepth, 
    $smwgQConceptFeatures, $smwgQConceptCacheLifetime, $smwgResultFormats, 
    $smwgResultAliases, $smwgQuerySources, $smwgPDefaultType, $smwgRSSEnabled,
    $smwgRSSWithPages, $smwgAllowRecursiveExport, $smwgExportBacklinks,
    $smwgNamespace, $smwgMaxNonExpNumber, $smwgEnableUpdateJobs,
    $smwgNamespacesWithSemanticLinks, $smwgPageSpecialProperties, 
    $smwgDeclarationProperties, $smwgTranslate, $smwgRAPPath, 
    $smwgAdminRefreshStore, $smwgAutocompleteInSpecialAsk,
$smwgAutoRefreshSubject, $smwgQFeatures
    ; 

To 1.8 SMW_Resources.php I've added:
global $wgResourceModules;

There may be other places because I'm getting unexpected results from queries.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to